我有一些IIS问题,我无法再运行我的网站了。重新安装IIS并删除applicationhost.config
后,我设法修复了它。现在我可以从Visual Studio启动该网站,但如果我浏览它,我得到:
未找到
HTTP错误404.找不到请求的资源。
我也没有在日志中看到任何请求。为什么会发生这种情况?我该如何解决?
applicationhost.config看起来像这样;
<site name="arnvanhoutte" id="2">
<application path="/" applicationPool="Clr4IntegratedAppPool">
<virtualDirectory path="/" physicalPath="E:\OneDrive\Apps\Web\arnvanhoutte\arnvanhoutte" />
</application>
<bindings>
<binding protocol="http" bindingInformation="*:52250:localhost" />
<binding protocol="https" bindingInformation="*:44397:localhost" />
</bindings>
</site>
<siteDefaults>
<logFile logFormat="W3C" directory="%IIS_USER_HOME%\Logs" />
<traceFailedRequestsLogging directory="%IIS_USER_HOME%\TraceLogFiles" enabled="true" maxLogFileSizeKB="1024" />
</siteDefaults>
<applicationDefaults applicationPool="Clr4IntegratedAppPool" />
<virtualDirectoryDefaults allowSubDirConfig="true" />
这是我运行iisexpress.exe /config:"applicationhost.config" /site:"arnvanhoutte" /apppool:"Clr4IntegratedAppPool" /trace:error
Starting IIS Express ...
Initializing the W3 Server Started CTC = 2060781
W3 Server initializing WinSock. CTC = 2060796
W3 Server WinSock initialized. CTC = 2060796
W3 Server ThreadPool initialized (ipm has signalled). CTC = 2060796
Start listenerChannel http:0
Successfully registered URL "http://localhost:52250/" for site "arnvanhoutte" application "/"
Successfully registered URL "https://localhost:44397/" for site "arnvanhoutte" application "/"
Registration completed for site "arnvanhoutte"
AppPool 'Clr4IntegratedAppPool' initialized
InitComplete event signalled
IIS Express is running.
Enter 'Q' to stop IIS Express
答案 0 :(得分:0)
我设法通过将我的用户添加到IIS_IUSRS组
来修复它