为什么我的IIS 7拒不来提供CSS或JS的当我改变“启用32位应用程序”设置为False [英] Why is my IIS 7 refusing to serve up css or js when I change 'Enable 32-Bit Applications' to False
问题描述
我有一个非常简单的Web应用程序(asp.net MVC3,.NET 4中,使用IIS没有Visual Studio的嵌入式服务器,64位Windows 7)。当我更改应用程序池的设置为我的应用程序,并设置启用32位应用程序为False,我的应用程序的视图显示出来,但没有静态内容(内容/的site.css或脚本/ myScript.js)所示向上。相反,我得到的状态code 500对这些请求。
I have a very simple web application (asp.net MVC3, .net 4, using IIS not Visual Studio's embedded server, 64-bit Windows 7). When I change the settings in the application pool for my application and set 'Enable 32-Bit Applications' to False, my application's view shows up, but none of the static content (Content/Site.css or Scripts/myScript.js) shows up. Instead, I get status code 500 on those requests.
HTTP错误500.0 - 内部服务器错误
无法显示页面,因为发生内部服务器错误。
HTTP Error 500.0 - Internal Server Error The page cannot be displayed because an internal server error has occurred.
我改变了这个值的原因是,我试图使用64位Oracle.DataAccess.dll,如果我有这个值设置为True它会导致应用程序池在WOW64模式下运行,并尝试与格式错误加载DLL。
The reason I'm changing this value is that I'm trying to use the 64-bit Oracle.DataAccess.dll and if I have this value set to True it causes the application pool to run in WOW64 mode and it tries to load the dll with the wrong format.
我在网上搜索了一阵,找不到这个非常信息。我试着权限上的文件播放,我试着运行aspnet_regiis的各种标志。我的想法。为什么在64位模式下运行时不会IIS服务了这一静态内容?
I've searched online for a while and can't find very much info about this. I've tried playing with permissions on the files, I've tried running aspnet_regiis with all kinds of flags. I'm out of ideas. Why won't IIS serve up this static content when running in 64bit mode?
推荐答案
这很可能是你的IIS安装,一个32位唯一的模块是由安装不小心其中$ P $从64运行pvents整个Web应用程序位模块。这是这样的500错误的一个常见原因。
It is very likely that on your IIS setup, a 32 bit only module is installed by you accidentally which prevents the whole web application from running in 64 bit module. That's a common cause of such 500 errors.
失败请求跟踪应该能够告诉你更多的信息,它是一个模块,
Failed request tracing should be able to show you more information on which module it is,
<一个href=\"http://www.iis.net/learn/troubleshoot/using-failed-request-tracing/troubleshooting-failed-requests-using-tracing-in-iis\" rel=\"nofollow\">http://www.iis.net/learn/troubleshoot/using-failed-request-tracing/troubleshooting-failed-requests-using-tracing-in-iis
这篇关于为什么我的IIS 7拒不来提供CSS或JS的当我改变“启用32位应用程序”设置为False的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!