How to remove and reinstall IIS 5.0, 5.1 and 6.0

Article translations Article translations
Article ID: 325889 - View products that this article applies to.
This article was previously published under Q325889
Expand all | Collapse all

On This Page

SUMMARY

This step-by-step article describes how to remove and reinstall Internet Information Services (IIS) versions 5.0, 5.1, and 6.0.


Back up the IIS configuration

If you already have IIS 5.0 (which is included with Microsoft Windows 2000), IIS 5.1 (which is included with Microsoft Windows XP Professional), or IIS 6.0 (which is included with Microsoft Windows Server 2003) installed and configured, you may want to back up that configuration before you remove and reinstall IIS so that you do not have to rebuild all your Web sites from scratch if you want to restore the configuration.

To back up your IIS configuration, follow these steps:

Note This backup method restores only your IIS settings, not your content files. This backup method does not work if you reinstall your operating system. Backup files cannot be used to restore an IIS configuration on other computers that are running Windows 2000.
  1. Click Start, point to Programs, click Administrative Tools, and then click Internet Services Manager.
  2. Expand Server Name.
  3. For IIS 5.0:

    Click Action, and then click Backup/Restore Configuration.

    For IIS 5.1 and IIS 6.0:

    Click Action, click All Tasks, and then click Backup/Restore Configuration.
  4. Click Create backup, name your backup file, and then click OK.

    Note If you are using Windows XP or Windows Server 2003, you can also click to select Encrypt backup with Password, and then provide and confirm a password.

    Note The default location of the backup is the %SystemRoot%\system32\inetsrv\MetaBack folder. By default, C:\Winnt is the %SystemRoot% folder in Windows 2000 and C:\Windows is the %SystemRoot% folder in Windows XP Professional. If you want to save your backup file to another location, you can copy the file from this default location to another location. Keep a copy in the default location to allow for an easy restoration.
  5. Click Close.
  6. Use your regular backup program software to back up your content files for your Web sites.

Remove IIS 5.0

To remove IIS 5.0, IIS follow these steps:
  1. Locate the Iis5.log file. Rename it to IIS5_old.log.
  2. Click Start, click Run, type cmd, and then click OK.
  3. At the command prompt, type net stop iisadmin /y.
  4. Stop all services that depend on IIS services. To determine what services depend on IIS services, follow these steps:

    Note This IIS services are the IIS Admin Service, the World Wide Publishing Service, the Simple Mail Transport Server, the FTP Publishing Service, and the NNTP Publishing Service.
    1. Click Start, click Run, type Services.msc, and then click OK.
    2. Right-click the service that you want, and then click Properties.
    3. On the Dependencies tab, note the services listed in the The following system components depend on this service window.
  5. In Task Manager, verify that Inetinfo.exe is not running. Also confirm that no processes that depend on IIS are running.
  6. Click Start, click Run, type Appwiz.cpl, and then click OK.
  7. In Control Panel, double-click Add/Remove Programs.
  8. In the Add/Remove Programs window, click Add/Remove Windows Components.
  9. In the Components box of the Windows Components Wizard, click to clear the Internet Information Services (IIS) check box.
  10. In the Windows Components Wizard, click Next.
  11. When the Windows Components Wizard completes the installation, click Finish.
  12. Restart the computer.
  13. Click Start, click Run, type Lusrmgr.msc, and then click OK.
  14. In the Local Users and Groups windows, verify that the IWAM_computername and IUSR_computername account have been deleted.

    Note In the account names, computername is the name of the computer.
  15. Verify that the Inetsrv folder has been deleted. By default, the Inetsrv folder is located in the %Windir%\System32 folder.

    Note You may be unable to delete the Inetsrv folder or its contents because of Windows File Protection.

Remove IIS 5.1 or IIS 6.0

To remove IIS 5.1 or IIS 6.0, follow these steps:
  1. Locate the Iis5.log file. Rename it to IIS5_old.log.
  2. Click Start, click Run, type cmd, and then click OK.
  3. At the command prompt, type net stop iisadmin /y.
  4. Stop all services that depend on IIS services. To determine what services depend on IIS services, follow these steps:

    Note This IIS services are the IIS Admin Service, the World Wide Publishing Service, the Simple Mail Transport Server, the FTP Publishing Service, and the NNTP Publishing Service.
    1. Click Start, click Run, type Services.msc, and then click OK.
    2. Right-click the service that you want, and then click Properties.
    3. On the Dependencies tab, note the services listed in the The following system components depend on this service window.
  5. In Task Manager, verify that Inetinfo.exe is not running. Also confirm that no processes that depend on IIS are running.
  6. Click Start, click Run, type Appwiz.cpl, and then click OK.
  7. In Control Panel, double-click Add/Remove Programs.
  8. In the Add/Remove Programs window, click Add/Remove Windows Components.
  9. In the Components box of the Windows Components Wizard, double-click Application Server.
  10. Click to clear the Internet Information Services (IIS) check box, and then click OK.
  11. In the Windows Components Wizard, click Next.
  12. When the Windows Components Wizard completes the installation, click Finish.
  13. Restart the computer.
  14. Click Start, click Run, type Lusrmgr.msc, and then click OK.
  15. In the Local Users and Groups windows, verify that the IWAM_computername and IUSR_computername account have been deleted.

    Note In the account names, computername is the name of the computer.
  16. Verify that the Inetsrv folder has been deleted. By default, the Inetsrv folder is located in the %Windir%\System32 folder.

    Note You may be unable to delete the Inetsrv folder or its contents because of Windows File Protection.

Install IIS

To install IIS, follow these steps:
  1. Click Start, click Run, type Appwiz.cpl, and then click OK.
  2. In the Add/Remove Programs window, click Add/Remove Windows Components.
  3. In the Components box of the Windows Components Wizard, click to select the Internet Information Services (IIS) check box.
  4. In the Windows Components Wizard, click Next.
  5. When the Windows Components Wizard completes the installation, click Finish.

Restore the IIS configuration

The steps to restore a configuration differ depending on whether you removed and reinstalled IIS.

Note If you want to restore your IIS configuration and only an older copy or no copy of the metabase file exists, you must follow a different procedure. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
234429 How to manually restore the metabase when no proper backup exists or when the MMC does not start

Restore the IIS configuration after an IIS reinstallation

To restore your IIS configuration after you have removed and reinstalled IIS, follow these steps:
  1. Use your regular backup program software to restore your content files for your Web sites.
  2. Click Start, point to Programs, click Administrative Tools, and then click Internet Services Manager.
  3. Expand Server Name.
  4. For IIS 5.0:

    Click Action, and then click Backup/Restore Configuration.

    For IIS 5.1:

    Click Action, click All Tasks, and then click Backup/Restore Configuration.
  5. In the Configuration Backup Name dialog box, select the backup file that you created, and then click Restore.

    Note If you are using Windows XP and you selected Encrypt backup with Password, provide and confirm the password.
You may receive an error message that states that the restoration has failed, but part of your backed-up configuration is restored. To resolve this problem, follow these steps:

Note Leave the Configuration Backup Dialog box open.
  1. At a command prompt, type the following (where X is the letter of the drive on which IIS is installed), and then press ENTER:
    cscript.exe X:\InetPub\AdminScripts\Adsutil.vbs enum w3svc
    Note To use the Adsutil.vbs utility, you must have Windows Script Host installed.
  2. In the listed settings, locate the WamUserName value.
  3. In Control Panel, double-click Administrative Tools, and then double-click Computer Management. Click Local Users and Groups, and then click Users.
  4. Double-click the IWAM_computername user account. Type a password for this account, and then click OK.
  5. At a command prompt, type the following (where X is the letter of the drive on which IIS is installed), and then press ENTER:
    cscript.exe X:\InetPub\AdminScripts\Synciwam.vbs
  6. In the Configuration Backup Name dialog box, click to select the backup file that you created, and then click Restore. This fully restores your configuration.

    Note If you change the identity of your out-of-process applications, those applications revert to the previous IWAM user name.

Restore the IIS configuration without an IIS reinstallation

To restore your IIS configuration if you have not removed and reinstalled IIS, follow these steps:
  1. Click Start, point to Programs, click Administrative Tools, and then click Internet Services Manager.
  2. Expand Server Name.
  3. For IIS 5.0:

    Click Action, and then click Backup/Restore Configuration.

    For IIS 5.1:

    Click Action, select All Tasks, and then click Backup/Restore Configuration.
  4. In the Configuration Backup Name dialog box, select the backup file that you created, and then click Restore.

    Note If you are using Windows XP and you selected Encrypt backup with Password, provide and confirm the password.
  5. When you are prompted to restore your configuration settings, click Yes.

REFERENCES

For more information, click the following article number to view the article in the Microsoft Knowledge Base:
302573 How to back up and restore IIS

Properties

Article ID: 325889 - Last Review: December 3, 2007 - Revision: 3.4
APPLIES TO
  • Microsoft Internet Information Services 5.0
  • Microsoft Internet Information Services version 5.1
  • Microsoft Internet Information Services 6.0
Keywords: 
kbhowtomaster KB325889

Give Feedback

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com