How do you change the allowDefinition section attribute using appcmd in IIS 7?

后端 未结 3 529
囚心锁ツ
囚心锁ツ 2021-01-11 11:02

Is it possible to use appcmd to change the value of allowDefinition? Specifically I\'m try to enable changes to the httpCompression module at the application level.

3条回答
  •  时光说笑
    2021-01-11 11:29

    Try using %windir%\system32\inetsrv\appcmd unlock config -section:*sectionName*. See http://blog.donnfelker.com/2007/03/26/iis-7-this-configuration-section-cannot-be-used-at-this-path/

    I actually came across a need to do just that after posting this answer.

    %systemroot%\System32\inetsrv\appcmd.exe unlock config /section:system.WebServer/[rest of the path to config section you need to edit]
    

提交回复
热议问题