2011-06-16 29 views
0

我正在尋找關於如何在IIS 7.5,ASP.Net 3.5中使用Rick Strahl's JavaScriptResourceHandler來解決奇怪的500錯誤的建議。在IIS 7.5下使用Westwind.Globalization.JavaScriptResourceHandler疑難解答怪異500錯誤

它在一臺機器上工作,但不在另一臺機器上。這兩臺機器都是Windows Server 2008 R2。

下面是一個示例響應,它在一臺機器上失敗,而在另一臺機器上失敗。

HTTP/1.1 500 Internal Server Error 
Content-Type: text/html 
Server: Microsoft-IIS/7.5 
X-Powered-By: ASP.NET 
Date: Thu, 16 Jun 2011 17:43:45 GMT 
Content-Length: 1208 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml"> 
<head> 
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/> 
<title>500 - Internal server error.</title> 
<style type="text/css"> 
<!-- 
body{margin:0;font-size:.7em;font-family:Verdana, Arial, Helvetica, sans-serif;background:#EEEEEE;} 
fieldset{padding:0 15px 10px 15px;} 
h1{font-size:2.4em;margin:0;color:#FFF;} 
h2{font-size:1.7em;margin:0;color:#CC0000;} 
h3{font-size:1.2em;margin:10px 0 0 0;color:#000000;} 
#header{width:96%;margin:0 0 0 0;padding:6px 2% 6px 2%;font-family:"trebuchet MS", Verdana, sans-serif;color:#FFF; 
background-color:#555555;} 
#content{margin:0 0 0 2%;position:relative;} 
.content-container{background:#FFF;width:96%;margin-top:8px;padding:10px;position:relative;} 
--> 
</style> 
</head> 
<body> 
<div id="header"><h1>Server Error</h1></div> 
<div id="content"> 
<div class="content-container"><fieldset> 
    <h2>500 - Internal server error.</h2> 
    <h3>There is a problem with the resource you are looking for, and it cannot be displayed.</h3> 
</fieldset></div> 
</div> 
</body> 
</html> 

完全沒有幫助。看看IIS日誌文件,我發現它特別返回了500.21 - 模塊未被識別

我很困惑,爲什麼它可以在一個盒子上工作,而不是另一個。

添加備註:我只是區分了兩臺機器的web根目錄。除環境特定差異外(即SSLRedirects在一個而不是另一箇中啓用,高速緩存持續時間長於另一個等等),它們是相同的。

回答

0

這兩臺機器之間的區別證明是從Integrated(正常工作的機器)和Classic(不工作的機器)設置的應用程序池之間的區別。

將應用程序池從Classic設置爲Integrated似乎已解決該問題。