M $ Internet Information Server (IIS) is a web server used by many friends. Almost all website hosts using Windows OS use it to build Web sites to provide ASP dynamic page services.
Friends who use it may encounter this situation, that is, one day IIS suddenly cannot access ASP pages but only HTML pages. when accessing ASP pages, the HTTP Error is reported, which is annoying. Today, I finally found a solution on the Internet and fixed it as I tried it.
Error cause:
In fact, this error is caused by IIS synchronizing the IIS process startup account IWAM _ $ name (the name is generally the OS NetBIOS Name) in some cases. The default start account of IIS is IWAM _ $ name. The password of this account is believed to be of little concern to those who have used IIS, because it is synchronized by the system itself, however, there are too many bad things in Windows. The synchronization may sometimes fail due to errors, causing the IWAM _ $ name account to be used outside the Internet information service process.
Program Authentication fails. The ASP page cannot be accessed because there is no support for the relevant parsing process, and an HTTP 500 error occurs.
Solution:
By default, the c: \ Inetpub \ adminscripts directory contains an adsutil. vbs file. This is a script file that is provided by IIS to modify the IIS configuration. The function cannot be underestimated. The following functions are used:
Get IUSR account password
Cscript.exe adsutil. vbs get w3svc/anonymoususerpass
Get IWAM account password
Cscript.exe adsutil. vbs get w3svc/wamuserpass
Set IUSR account password
Cscript.exe adsutil. vbs set w3svc/anonymoususerpass "password"
Set IWAM account password
Cscript.exe adsutil. vbs set w3svc/wamuserpass "password"
Note: if the value of issecureproperty in adsutil. vbs is true, a star password is returned. If the value is false, a plaintext password is displayed. It can be changed manually.
the specific step is to set the password in the User Manager, and then use the script to set the IIS Password for synchronization. You can also use a script to obtain the password and then set it to the user. Manual synchronization can be implemented to restore ASP page access.
automatic synchronization Script:
net user IWAM _ % userdomain % Network
cscript.exe C: \ Inetpub \ adminscripts \ adsutil. vbs set w3svc/wamuserpass "network"
@ if % errorlevel % equ 0 echo. & Echo. & echo the password of IWAM _ % userdomain % is successfully synchronized in the IIS configuration database! & Echo.
@cscript.exe c: \ Inetpub \ adminscripts \ synciwam. vbs-v
@ if % errorlevel % equ 0 echo. & Echo. & Echo La la user IWAM _ % userdomain % password synchronized successfully in Microsoft Transaction Server or component service! & Echo.
@ CMD/k