Quantcast
Channel: Configuration & Scripting
Viewing all articles
Browse latest Browse all 780

PowerShell Error: Cannot write configuration file

$
0
0

Im getting the below error when trying to use the Set-WebConfiguration cmdlet at a file level. It seems to work fine on the site level, please help. 

Error: Cannot write configuration file

+ CategoryInfo : NotSpecified: (:) [Set-WebConfiguration], DirectoryNotFoundException
+ FullyQualifiedErrorId : System.IO.DirectoryNotFoundException,Microsoft.IIs.PowerShell.Provider.SetConfigurationCommand

Set-WebConfiguration system.webServer/httpRedirect "IIS:\Sites\Default web site" -location index.html -Value @{enabled="true";destination="http://google.com";exactDestination="true";childOnly="false";httpResponseStatus="Permanent"} -verbose




Viewing all articles
Browse latest Browse all 780

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>