Administering an ISP Installation |
Adsutil.vbs, an administration utility installed with Windows 2000 Server and IIS 5.0, runs on VBScript in conjunction with ADSI. Use Adsutil.vbs together with Cscript.exe, which is installed with WSH, in order to manipulate the IIS 5.0 configuration.
You can execute an administration script by typing the appropriate syntax on the command line. The following example shows the current settings for the root of the default Web site:
cscript.exe inetpub\adminscripts\adsutil.vbs enum w3svc/1/root
To execute any other script on the command line, type:
Cscript.exe path\ScriptName
Instead of typing the syntax on the command line, you can type it in a batch (.bat) file, and execute your scripts from there. If you execute the same script repeatedly, putting it into a batch file will save you from having to retype the script every time you want to run it.
If you’ve added the path to the Inetpub\AdminScripts directory, you don’t have to type the full path to Cscript.exe. For information about editing your path, see the Windows 2000 Server online documentation.
Note If you have registered Cscript.exe as your default scripting host, you don’t have to type Cscript.exe in front of the scripts to execute them. (To learn how to register Cscript.exe, see the first two steps in the next section.)