Udostępnij za pośrednictwem


Listing IIS Backup Configurations Using Iisback.vbs

Applies To: Windows Server 2003, Windows Server 2003 R2, Windows Server 2003 with SP1

You can use the command-line script iisback.vbs, which is stored in systemroot\System32, to list backup copies of the IIS configuration (metabase and schema) of a remote or local computer.

The /list operation lists only the backup copies that are stored in the default location, systemroot\System32\Inetsrv\MetaBack. If you move the backup copy files to a different directory, the backup copy does not appear in the list.

Iisback.vbs performs the same backup and restore operations that are available in IIS Manager. You can use either tool to view and manage backup copies.

Important

You must be a member of the Administrators group on the local computer to run scripts and executables. As a security best practice, log on to your computer by using an account that is not in the Administrators group, and then use the runas command to run your script or executable as an administrator. At a command prompt, type runas /profile /User:MyComputer</STRONG>Administrator cmd to open a command window with administrator rights and then type cscript.exe ScriptName (include the script's full path and any parameters).

This topic includes the following information:

  • Syntax: The order in which you type a command and any arguments and options that follow it.

  • Parameters: The values that are given to variables in the command.

  • Example: Sample code and an explanation of the results.

Syntax

iisback /list [/s Computer [/u [Domain\]User**/p** Password]]

Parameters

/s Computer

Runs the script on the specified remote computer. Type the computer name or IP address without backslashes. The default is the local computer.

/u [Domain\]User

Runs the script with the permissions of the specified user account. This account must be a member of the Administrators group on the remote computer. By default, the script runs with the permissions of the current user of the local computer.

/p Password

Specifies the password of the user account that is specified in the /u parameter.

Example

The following command lists the backup copies that are stored on the remote server, Svr16. It uses the /s parameter to specify the server name, the /u parameter to specify the user's Administrator account, and the /p parameter to specify the password for the Administrator account.

iisback /list /s Svr16 /u Domain06\User1 /p R34*9W@4b

In response, iisback displays all of the backup copies that are on the remote server, Svr16:

Backup Name Version # Date and Time

AsiaSvr 0 12/8/2001 9:18:25 PM

AsiaSvr 1 1/14/2001 9:02:33 PM

Svr01Bkp 11 1/3/2001 3:00:42 AM

Svr01Bkp 12 1/4/2001 3:00:12 AM

Svr01Bkp 13 1/5/2001 3:01:00 AM

Svr01Bkp 14 1/6/2001 3:00:00 AM

Svr01Bkp 15 1/9/2001 5:18:04 AM

Note

iisback /list uses Coordinated Universal Time (UTC) for date and time stamps. Also, without parameters, the iisback /list command lists all of the backup copies that are stored on the local computer.