在Windows Server 2003 IIS 6.0上运行但不在具有IIS 7.0的Windows 2008 R2 Server上运行的MVC 3.0站点 [英] MVC 3.0 site running on windows server 2003 IIS 6.0 but not running on windows 2008 R2 Server which has IIS 7.0

查看:78
本文介绍了在Windows Server 2003 IIS 6.0上运行但不在具有IIS 7.0的Windows 2008 R2 Server上运行的MVC 3.0站点的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我的网站是通过MVC 3.0框架后端Oracle 11g开发的.当我将该网站上传到具有IIS 6.0和32位的Windows Server 2003上时,该网站运行良好.

但是,当我在Windows Server 2008 R2上上传该站点时,它具有IIS 7.0和64位,但未运行.我手动将应用程序池配置为32位.

直到我遇到相同的错误:"HTTP错误500.0-内部服务器错误.

由于发生内部服务器错误,因此无法显示该页面.

任何人都可以帮助我非常紧急的事情.
提前谢谢.

Shafik

Hi All,

My site is developped by MVC 3.0 framework back end Oracle 11g is running.when i uploaded that site on windows server 2003 which has IIS 6.0 and 32 bit, the site running good.

But when i upload that site on windows server 2008 R2 whis has IIS 7.0 and 64 bit but its not running. I manuaaly configured the application pool 32 bit true.

stil i am getting the same error : "HTTP Error 500.0 - Internal Server Error.

The page cannot be displayed because an internal server error has occurred".

Can any body help me its very urgent.
Thanks in advance.

Shafik

推荐答案

您将需要做更多的挖掘工作,因为500错误是一个通用的东西坏了"错误,所以我们不能学习任何有用的东西.但是,我可以帮助您朝正确的方向开始.首先,检查确保服务器上已安装MVC3.除非您要bin部署MVC3(可能),否则需要将其安装在IIS服务器上(它不是标准配置).在执行此操作时,请验证您的应用程序池是否正在使用.NET 4.0(MVC3必需).如果确实进行任何更改,请确保重新启动IIS服务器并重新加载应用程序池.

如果检查这些内容仍不能解决问题,请简单开始:将index.htm文件放在您的网站目录中,以确保可以加载某些内容.如果这不起作用,则说明您的IIS配置混乱.接下来,创建一个新的MVC3应用程序并将其部署到您的目录(暂时将生产文件移出-您要使用相同的目录,以确保可以正确比较它们).在新的MVC3应用程序中,请勿连接任何数据源.只需使用从应用程序本身加载的一小部分伪数据进行设置即可.足以完成典型的MVC工作"-列出数据,编辑一个数据项等.这仅表明MVC3正常工作.将其部署到您的目录.如果不起作用,则说明是MVC3.如果它可以正常工作,则说明您的问题出在应用程序本身.查看是否仍然可以从新服务器访问数据库服务器(也许防火墙正在阻止它,等等.)此外,查看是否缺少原始应用程序可以访问的任何文件夹或路径(可能是javascript文件,css文件等)

如果所有操作均失败,请尝试在MVC应用程序上安装Elmah(使用NuGet查找并安装).那应该向您显示任何未处理的异常.您可能还需要检查IIS日志文件以跟踪其他潜在问题.
You are going to need to do some more digging, since a 500 error is a generic "something is broken" error, so we can''t learn anything very useful from it. However, I can get you started in the right direction. First, check to be sure MVC3 is installed on the server. Unless you are bin deploying MVC3 (which is possible), you need to install it on the IIS server (it doesn''t come standard). While you are doing that, verify that your application pool is using .NET 4.0 (required for MVC3). If you do make any changes, make sure you restart the IIS server and reload the application pool.

If checking these doesn''t fix your issue, start simple: put an index.htm file in your website directory to be sure you can load something. If that doesn''t work, your IIS configuration is messed up. Next, create a new MVC3 application and deploy it to your directory (move your production files out temporarily - you want to use the same directory so you can be sure that you compare things properly). In your new MVC3 application, don''t hook up any data source. Just get it set up with a small set of dummy data loaded from the application itself. Just enough to do typical MVC "stuff" - list data, edit one data item, etc. This will just demonstrate that MVC3 is working properly. Deploy it to your directory. If it doesn''t work, you know MVC3 is the issue. If it does work, you know your issue is with your application itself. Look to see if you still have access to your database server from the new server (maybe the firewall is blocking it, etc.) Also, look to see if you are missing any folders or paths that the original application had access to (maybe javascript files, css files, etc.)

If all of that fails, try installing Elmah (use NuGet to find it and install it) on your MVC application. That should show you any unhandled exceptions. You may also need to check the IIS log files to track down other potential issues.


这篇关于在Windows Server 2003 IIS 6.0上运行但不在具有IIS 7.0的Windows 2008 R2 Server上运行的MVC 3.0站点的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆