IIS: Cannot Write Configuration File due to Insufficient Permissions

来源:互联网 发布:淘宝联盟如何身份认证 编辑:程序博客网 时间:2024/04/30 23:14

http://jwcooney.com/2014/05/22/iis-cannot-write-configuration-file-due-to-insufficient-permissions/

I was setting up an ASP.NET application in IIS 8 when this error message all of a sudden popped up:

Error: Cannot Write Configuration File due to Insufficient Permissions

I wasn’t sure what was going on at first… why was IIS saying it didn’t have the right level of permissions to write to a file? I couldn’t continue with the site setup since I was unable to change the default document settings in IIS or the.NET Authorization rules. The error would just keep showing.

I started trying to adjust all sorts of permissions before I realized: wait a second… could the ReadOnly setting be toggled on the Web.config file?

And that was exactly the problem. The Web.config file had been set to read-only. As soon as I clicked the read-only toggle off on this file, I was able to continue changing the settings that I needed to get the site up and running in IIS.

It would be nice if some of these Microsoft error messages could be more exact as to what problem is happening. This error had me wondering about permissions settings in the Web site folder/files, while the actual issue was a simple read-only setting on the Web.config file. If you ask me, Microsoft should just set this error as:

Error: Cannot Write to Configuration File due to Read-Only being set to true

There, isn’t that much clearer? The problem and the actual solution in one simple error message


0 0
原创粉丝点击