我在运行 PHP-applications 的 IIS7 中遇到启动错误(500)。

将 system.webServer/httpErrors 设置为详细解释了问题:

Module  IIS Web Core
Notification    BeginRequest
Handler Not yet determined
Error Code  0x80070005
Config Error    Cannot read configuration file due to insufficient permissions
Config File \\?\C:\opt\php\public\web.config

将 web.config 添加到公共目录没有帮助,事实上它变得更糟,没有文件,只是启动错误,文件持久性错误。

iusr 有权使用 dir 和 file,尝试使用 webconfig 中的虚拟内容。

服务器上没有.NET/.ASP - 只有 PHP。感谢任何有关简单修复的提示。