Microsoft IIS 6.0Administrator's Consultant

The Windows Registry stores configuration settings for the operating system, the server hardware, and all installed applications. The registry is essential to the proper operation of the operating system. You should make changes to the registry only when you know how these changes will affect the system.

Working with the Registry

Registry settings are stored as keys and values. These keys and values are placed under a specific root key. The root key controls when and how other keys and values are used. The root keys are:

Under the root keys, you’ll find the main keys that control various facets of the system, user, and application environments. These keys are organized into a tree structure in which folders represent keys. Settings that control the IIS Admin Service are stored under the following registry path:

HKEY_LOCAL_MACHINE \SYSTEM \CurrentControlSet \Services \InetInfo \Parameters

Here, the key is Parameters. The values associated with this or any other keys have three components: a value name, a value type, and an actual value. Numeric values are often expressed in hexadecimal format. Hexadecimal values use the prefix 0x, such as 0x19 for the decimal value 25. In the following example the ListenBackLog value has a type of REG_DWORD and a value of 0x19:

ListenBackLog : REG_DWORD : 0x19

REG_DWORD is one of several possible value types. The complete list of value types follows:

The main tool that you’ll use to work with the Windows Registry is the Registry Editor (Regedt32.exe). You can start the Registry Editor by clicking Start and then selecting Run. Then type REGEDT32 in the Open field and click OK.

If you’re an experienced administrator, you might want to use a Windows script to manage the registry. With scripts you can create, update, and delete registry settings. Here is a Microsoft Visual Basic, Scripting Edition (VBScript) script example that updates the ListenBackLog value:

'Initialize variables and objects Dim PathPath = "HKLM\SYSTEM\CurrentControlSet\Services\Inetinfo\Parameter\ "Set ws = WScript.CreateObject("WScript.Shell") 'Read and display key value val = ws.RegRead(Path & "ListenBackLog") WScript.Echo "Orginal ListenBackLog value: " & val 'Write new key value and then display new value retVal = ws.RegWrite(Path & "ListenBackLog", 50,"REG_DWORD") val = ws.RegRead(Path & "ListenBackLog") WScript.Echo "Updated ListenBackLog value: " & val

Controlling IIS Through the Registry

Settings that control IIS are stored in the registry under:

HKEY_LOCAL_MACHINE\SYSTEM \CurrentControlSet \Services \Inetinfo \Parameters

With the changes to the IIS architecture for application pools and queues, many of the previously used registry keys aren’t created automatically. You can still create these keys, however, if you’d like to use them.

The key values you might want to work with are the following:

Controlling the Indexing Service Through the Registry

Settings that control the Indexing Service are stored in the registry under:

HKEY_LOCAL_MACHINE \SYSTEM \CurrentControlSet \Control \ContentIndex

You’ll find a detailed discussion of related settings and keys in the section entitled “Indexing Service Essentials” in Chapter 12, “Administering the Indexing Service.”

Settings for the World Wide Web Publishing, File Transfer Protocol (FTP), and Simple Mail Transfer Protocol (SMTP) Services are stored in separate registry keys. The path to these keys is:

HKEY_LOCAL_MACHINE \SYSTEM \CurrentControlSet \Services \ServiceName \Parameters

ServiceName is the name of the service you want to work with. Services you might work with are:

Although most of the keys under this path are used only by IIS, you might want to set the AllowGuestAccess key value. This key value determines whether Guest logons are allowed for Internet services. By default, Guest logons are permitted, but you can disable this feature by creating the key and setting its value to 0.

For the World Wide Web Publishing Service, you might also want to work with the following key values:

Controlling Secure Sockets Layer Through the Registry

Settings that control Secure Sockets Layer (SSL) are stored in the registry under

HKEY_LOCAL_MACHINE \SYSTEM \CurrentControlSet \Control \SecurityProviders \SCHANNEL

After you’ve started the Registry Editor and accessed this location, the key values you might want to work with are:

Категории