Lesson 1 HTTP Defined
Lesson 2 WWW Properties
Lesson 3 Virtual Directories
Lesson 4 Virtual Servers
Review
About This Chapter
This chapter describes the basic functionality of Hypertext Transport
Protocol (HTTP) 1.1 as it relates to the Microsoft Internet Information
Server (IIS) 4.0 World Wide Web (WWW) service. It introduces you to the
three different types of property sheets within Internet Information
Server and how to access them in order to configure your Web sites. This
chapter also describes virtual directories and servers, explaining the
various methods by which you can add virtual directories and servers to
Internet Information Server.
Before You Begin
To complete the lessons in this chapter, you must have installed
Internet Information Server as described in Chapter 2, "Installing
Microsoft Internet Information Server."
Lesson 1: HTTP Defined
Hypertext Transfer Protocol (HTTP) is the most frequently used protocol
on the Internet today. This lesson describes the fundamentals of HTTP.
After this lesson, you will be able to:
- Define HTTP and describe its basic functionality as it relates to
the WWW Service.
Estimated lesson time: 5 minutes
HTTP is the protocol that led to the development of the Web. It is a
generic, stateless, object-oriented protocol that grew out of a need for a
universal protocol to simplify the way users access information on the
Internet. HTTP is a client/server protocol located in the Application
layer of the Internet protocol stack.
By extending its request methods, or commands, you can use HTTP for
many different functions, including name servers and distributed object
management systems. Because HTTP categorizes or types data, systems can be
built independently of the data being transferred.
HTTP is constantly being improved. The World Wide Web Consortium (W3C)
was founded in 1994 to develop common standards for the Web. You can find
more information about the W3C at:
General discussions about HTTP and the applications that use HTTP take
place on the following mailing list:
Summary
HTTP is a client/server protocol that was developed to simplify the way
users access information on the Internet. It is a generic, stateless,
object-oriented protocol that led to the Web. Because HTTP is constantly
changing, the W3C was created to develop standards for the Web.
Lesson 2: WWW Properties
Each Web site that you create on your computer has its own set of
property sheets. The general settings, or properties, for a site are
displayed in these property sheets and stored in the metabase. In this
lesson, you learn about the different types of property sheets.
This lesson describes these different property sheets and demonstrates
how to access them in order to set the general properties for a site or
file within a site on your computer.
After this lesson, you will be able to:
- List and describe the three types of WWW property sheets and their
relationship to one another.
- Locate the WWW property sheets and use them to configure the WWW
Service.
- List and describe the functions of the property sheets associated
with the WWW Service.
Estimated lesson time: 70 minutes
During installation, Internet Information Server assigns default values
to the various properties on the different property sheets. You can
publish documents on your site without changing these default settings,
and you can easily customize the settings as well.
Each Web site that you create and each file within each Web site has an
individual set of property sheets that you can edit in order to customize
configuration on a file-by-file or site-by-site basis. You can also edit
the default property settings so that all subsequent sites or files are
created with your custom configuration.
Types of WWW Property Sheets
There are three different types, or classes, of property sheets within
Internet Information Server: the Master, Default, and
File property sheets. You can customize configuration of all three
types of property sheets, but where you make your changes affects the
range of influence the changes have on subsequent sites or files created.
It may be helpful to think of the different types of property sheets in
terms of a hierarchy with Master property sheets at the top of the
hierarchy and File property sheets at the bottom. Master
property sheets determine the properties of the virtual Web sites you
create, which in turn determine the properties of the files created within
each Web site.
Master
Master property sheets determine the default properties of every
virtual Web site created with this installation of Internet Information
Server. During installation, Internet Information Server applies certain
default properties to the Master property sheets. Every virtual
site you create inherits these settings. If you change the settings on the
Master property sheets, subsequent virtual sites inherit the new
settings, but previously created virtual sites do not.
Default
The installation process creates a default Web site with its own
default properties. Every file you create within the default Web site
inherits these settings.
File
Files created in a virtual directory inherit the virtual directory's
property sheet settings, whereas files created in the default Web site
inherit the settings of the Default Web Site Properties dialog box.
After a file is created, the property sheets can be configured on the file
level.
WWW Property Sheets
The WWW Service can be configured using a set of nine different
property sheets:
- Web Site
- Operators
- Performance
- ISAPI Filters
- Home Directory
- Documents
- Directory Security
- HTTP Headers
- Custom Errors
You can change the settings on these property sheets as needed at any
time.
All WWW property sheets can be accessed using the Internet Service
Manager (ISM) snap-in for Microsoft Management Console (MMC).
To access the WWW property sheets
- Click the Start button, point to Programs, point to
Windows NT 4.0 Option Pack, point to Microsoft
Internet Information Server, and then click
Internet Service Manager.
- In the left pane, double-click the Internet Information Server node.
- In the left pane, double-click the computername node.
- Right-click Default Web Site, and then click
Properties.
The Default Web Site Properties dialog
box appears with tabs for each property sheet.
Web Site
You can use the Web Site property sheet to set the Web site
identification, specify the number of connections allowed, and enable or
disable logging for a Web site.
The Web Site Identification field allows you to choose a
description for your Web site using the following settings:
- Description. This dialog box lists the name you choose for
your Web site and appears in the tree view of the Internet Service
Manager.
- IP Address. This dialog box lists the Internet Protocol (IP)
address associated with your Web site.
- TCP Port. This dialog box determines the port where each
service runs. The default is port 80.
- SSL Port. This dialog box determines the port used by Secure
Sockets Layer (SSL) transmissions.
- Advanced. This button opens the Advanced Multiple Web Site
Configuration dialog box where you can specify additional identities
for your Web site.
The Connections field allows you to set the number of
simultaneous connections to the server using the following settings:
- Unlimited. Select this option to allow an unlimited number of
simultaneous connections to the server.
- Limited To. Select this option to limit the number of
simultaneous connections to the server to the number entered in the
associated text box.
- Connection Timeout. Use this property to set the length of
time in seconds before the server disconnects an inactive user.
Select the Enable Logging option to activate your Web site's
logging features. These can record details about user activity and create
logs in your choice of format.
Click the Properties button to open the Microsoft Logging
Properties dialog box. This dialog box allows you to choose how often
to create new logs, to specify the file folder for the log, and to select
additional extended properties for logging.
Operators
You can use the Operators property sheet to control which
Microsoft Windows NT User Accounts have administrative privileges for your
Web site.
To add a Windows NT User Account to the current list of accounts that
have administrative privileges, click the Add button. To remove a
Windows NT User Account from this list, select the account in the
Operators box, and then click Remove.
Performance
You can use the settings on the Performance property sheet to
fine-tune your Web site's performance.
Adjust the Performance Tuning setting to the number of daily
connections you anticipate for your site. If you set the number slightly
higher than the actual number of connections, connections are made faster
and server performance is improved. However, if you set it too much higher
than the actual number of connection attempts, server memory is wasted and
overall server performance is reduced.
The Enable Bandwidth Throttling option allows you to limit the
bandwidth used by this Web site. For this Web site only—even if it is
greater than the value set at the computer level—the bandwidth value
entered here overrides the value set at the computer level.
Select the HTTP Keep-Alives Enabled box to allow a client to
maintain an open connection with your server. This means that the client
connection does not have to be reopened with each new request. Keep-Alives
are enabled by default.
ISAPI Filters
The ISAPI Filters property sheet contains options for Internet
Server Application Programming Interface (ISAPI) filters. You can use
ISAPI to run remote applications. Requesting a Uniform Resource Locator
(URL) that is mapped to a filter activates these applications. You can use
these settings to map file name extensions to the correct filter on the
Web server.
The table on this property sheet lists the status (Loaded, Unloaded, or
Disabled), name, and the priority rating set inside the dynamic-link
library (DLL), which is High, Medium, or Low, of each filter. You can
modify filter mappings with the Add, Remove, and Edit
buttons. You can use the Enable and Disable buttons to
modify a filter's status. Select a filter and then click the up or down
arrow button to change the order in which the server runs the ISAPI
filters.
Home Directory
You can use the Home Directory property sheet to change your Web
site's home folder and modify its properties.
The home folder is the central location for the files published in your
Web site. Installation of the WWW Service creates a default home folder
named Wwwroot. You can use the buttons at the top of this property sheet
to change the location of the current Web site's home folder to one of the
following:
- A folder located on the same computer
- A share located on another computer
- A redirection to a URL
If you change the home folder, type the precise path to the new folder,
share, or destination URL in the Local Path box, or use the
Browse button to locate the folder path.
Access Permissions properties are applicable when your home
folder is a local folder or a network share. The following check boxes
determine the type of access the folder allows:
- Read. Read access permission enables Web clients to
read or download files stored in either the home folder or a virtual
directory. You learn more about virtual directories later in this
chapter.
- Write. Write access permission enables Web clients to
upload files to the enabled folder on your server, or to change the
content of a write-enabled file. However, Web clients can only perform
Write-access procedures with a browser that supports the PUT feature of
the HTTP 1.1 protocol standard.
The following Content Control properties are applicable when
your home folder is a local folder or a network share:
- Log access. Log access allows you to record visits to
this folder in a log file.
- Directory browsing allowed. By selecting this check box you
allow the server to compile a hypertext listing of the files and
subfolders within this folder. This listing is generated automatically
and sent to the user whenever a browser request does not include a
specific file name or when the server cannot find one of the specified
default documents in the folder. For more information, see the
discussion of the Documents property sheet later in this lesson.
This listing allows the user to navigate through the folder structure.
- Index this directory. Selecting this check box instructs
Microsoft Index Server to include this folder in the full-text index of
your Web site.
- FrontPage Web. Select this check box to create a Microsoft
FrontPage Web site for this folder. FrontPage allows you to manage your
Web site, as well as create the site content.
Within the WWW Service, an application is defined as all of the folders
and files contained within a folder. The application begins at a point
marked as an application starting point and runs until another application
starting point is reached. If you make your site's home folder an
application starting point, then every virtual directory and physical
folder within your site can participate in the application.
To dissociate this home folder from an application, click the
Remove button. You can make this folder an application starting
point (and thus create an application) by clicking the Create
button. Type the name of the application in the Name box, and the
name appears in the property sheets for any folder contained within the
application boundary.
- Run in separate memory space (isolated process). Select this
check box to run this application in a process separate from the Web
server process. Running an isolated application protects other
applications, including the Web server itself, from being affected if
this application becomes unavailable or stops responding.
- Permissions. Use this setting to control whether other
applications can be run in this folder. Select None if you do not
want to allow any programs or scripts to run in this folder. Selecting
Script enables a script engine to run in this folder without
having set Execute permissions. The Execute (including script)
setting allows any application to run in this folder, including script
engines and Windows NT binaries (.dll and .exe files).
Click the Configuration button to set application-specific
properties. There are four application configuration property sheets:
- Application Mappings. Use this page to map file name
extensions to the applications that process those files.
- Active Server Pages (ASP). Use this page to set the options
that control how ASP scripts run.
- ASP Debugging. Use this page to set debugging options for ASP
scripts.
- Other. Use this page to set or change the CGI Script Timeout
value.
Documents
You can use the Documents property sheet to specify default
documents and attach default footers to your Web pages.
By selecting the Enable Default Documents check box, you can
show the user a default document when a browser request does not include a
specific Hypertext Markup Language (HTML) file name. Default documents can
be a folder's home page or an index page that provides links to the
documents in the folder. For more information, see the discussion of the
Home Directory property sheet earlier in this lesson. You can
specify more than one default document. To add a new default document,
click Add.
When prompted by a browser, the Web server searches the folder for
default documents, following the order in which the names appear in this
list. The server returns the first document it finds. To change the search
order, select a document, and then click the up or down arrow button.
Select the Enable Document Footer option to configure your Web
server to insert a footer automatically. Your footer must be a separate
file, but it should not be a complete HTML document. Your footer file
should include only the HTML tags necessary for formatting the appearance
and function of your footer content. For example, your footer file can
contain HTML formatting instructions for adding a logo image and
identifying text to your Web pages. You must provide the full path and
file name for you footer file.
Directory Security
You can use the Directory Security property sheet to configure
your Web server's user identification security features.
The Anonymous Access and Authentication Control option sets the
anonymous access and authentication control methods for access to the
server. Click Edit to select one or more authentication methods
from the following options:
- Allow Anonymous Access. Select this box to allow anonymous
users to log on to your Web server. When a user establishes an anonymous
connection, your server logs the user on with an anonymous or guest
account. In either case, the account used is a valid Windows NT user
account. Click Edit to specify which Windows NT User Account to
use for anonymous connections.
- Basic Authentication. Select this box to enable your Web
server's Basic Authentication method, where the password is sent in
clear text. By selecting this option, a user name and password are
required when the Allow Anonymous Access option is disabled, or
access to the server is controlled using Windows NT File System (NTFS)
access control lists.
- Windows NT Challenge/Response. Select this box to enable your
Web server's Windows NT Challenge/Response authentication methods. As
with Basic Authentication, a user name and password are required when
the Allow Anonymous Access option is disabled, or access to the
server is controlled using NTFS access control lists. Windows NT
Challenge/Response is supported by Microsoft Internet Explorer, version
2.0 or later.
For a discussion of authentication and password security issues, see
Chapter 9, "Adding Windows NT and Internet Information Server Security
Features."
The Secure Communications feature is available only for Windows
NT Server installations. This feature uses Key Manager to create a
certificate request. Click Key Manager to start the process of
receiving a SSL digital certificate for this resource.
Use the IP Address and Domain Name Restrictions properties to
grant or deny access to this resource using IP addresses or Internet
domain names. Click Edit to grant or deny access to specific
individuals or groups as follows:
- Granted Access. Click this button to grant access to all
computers by default. Click Add to list those computers that are
denied access.
- Denied Access. Click this button to deny access to all
computers by default. Click Add to list those computers that are
granted access.
HTTP Headers
You can use the HTTP Headers property sheet to set values
returned to the browser in the header of specific HTML pages.
Select the Enable Content Expiration check box to include
expiration information in the HTML page header. When you include a date in
time-sensitive material, such as special offers or event announcements,
the browser compares the current date to the expiration date and
determines whether to display a cached page or request an updated page
from the server.
You can send custom HTTP headers from your Web server to the client
browser. To send a header, click Add, and then type the name and
value of the header in the Add Custom HTTP Header dialog box. Click
Remove to stop sending the header.
You can embed descriptive labels in your Web page's HTTP headers using
the Content Rating feature. Some Web browsers, such as Microsoft
Internet Explorer version 3.0 or later, can detect these content labels in
order to help users identify potentially objectionable Web content. Click
Edit Ratings to set content ratings for this Web site, folder, or
file.
You can set which file types your Web service returns to browsers.
Clicking the File Types button allows you to configure Multipurpose
Internet Mail Extensions (MIME) mappings.
Custom Errors
The Custom Errors property sheet lists the messages returned to
the browser in the event of an HTTP error.
You can use either the default HTTP 1.1 errors or you can customize
these error messages with your own content. When error messages are
customized, the HTTP error code is still listed, as well as the output
type, which can be the default HTTP 1.1 error, a local absolute URL, or a
pointer to a file.
Practice
In this practice scenario, you use Internet Service Manager to take
your Web site offline without stopping the WWW Service. You then create a
custom error message, and replace the default error message with your
custom error message. Finally, you use Internet Service Manager to bring
your Web site online without restarting the WWW Service. You can use the
procedures in this practice if you need to inform visitors that your site
is offline due to maintenance.
In the first part of the practice, you take your default Web site
offline.
To take your default Web site offline
- Start Microsoft Management Console with the Internet Service Manager
snap-in.
- In the left pane, double-click the Internet Information Server
folder.
The Internet Information Server folder opens
displaying a computer icon.
- In the left pane, double-click the computer icon.
The computer tree expands displaying the
default sites.
- Right-click Default Web Site, and then click
Properties.
The Default Web Site Properties dialog
box appears displaying the Web Site tab.
- Click the Home Directory tab.
- Under Access Permissions, click Read.
The Read check box is cleared.
- Click OK.
The Inheritance Overrides dialog box
appears.
- Click Select All.
- Click OK.
You now test your Web site for the standard error message.
To test your Web site with Internet Explorer
- Open Internet Explorer.
- In the Address box, type your server name.
- Click OK.
The message
HTTP Error 403 Access Forbidden
403.2
Forbidden: Read Access Forbidden
appears with a paragraph describing the error
beneath it.
- Minimize Internet Explorer.
Next, you create a custom error message to replace the standard error
you viewed in the previous practice.
To create the custom error message by editing the existing message
- Open Notepad.
- On the File menu, click Open.
The File name box appears.
- Type c:\winnt\help\common\403-2.htm
- Click Open.
Notepad displays the HTML code for error 403.
The main error message text is in the middle of the screen. It begins
"This error canU" and is bounded by a paragraph beginning marker,
<p>, and a paragraph ending marker, </p>.
- Replace the error message text with: "Our site is closed for
repairs. Please try again later."
- On the File menu, click Save As.
- The Save As dialog box appears.
- Save the file in the C:\Winnt\Help\Common folder.
- In the File Name box, type err403.htm
- Click Save.
- Close Notepad.
In this practice, you install the custom error message on your Web
site.
Note This step is necessary because you are redirecting the Help
engine to a different file (Err403.htm) when encountering Error 403.2
rather than permanently replacing the standard file. This way, you can
easily direct the Help engine back to the standard message when you no
longer need the custom message.
If you had saved the custom message over the standard file, this step
would not be necessary.
To install the custom error message
- Start Internet Service Manager.
- Right-click Default Web Site, and then click
Properties.
The Default Web Site Properties dialog
box appears.
- Click the Custom Errors tab.
- Select the 403;2 HTTP error.
- Click Edit Properties.
The Error Mapping Properties dialog box
appears.
- In the Message Type box, select File.
- In the File box, type c:\winnt\help\common\err403.htm
- Click OK to return to the Default Web Site Properties
dialog box.
- Click OK.
The Inheritance Overrides dialog box
appears.
- Click Select All.
In the Child Nodes text box,
IISADMIN and IISHELP are selected.
- Click OK.
You now test your Web site for the custom error message.
To test your Web site with Internet Explorer
- Switch to Internet Explorer.
- Click Refresh.
The message
HTTP Error 403 Access Forbidden
403.2
Forbidden: Read Access Forbidden
appears with your new error text beneath
it.
- Close Internet Explorer.
To complete the practice, you bring your default Web site online.
To bring your default Web site online
- Switch to Internet Service Manager.
- Right-click Default Web Site, and then click
Properties.
The Default Web Site Properties dialog
box appears displaying the Web Site tab.
- Click the Home Directory tab.
- Under Access Permissions, click Read.
The Read check box is selected.
- Click OK.
- Close Microsoft Management Console.
You are prompted to save the changes to
Iis.mcs.
- Click No.
Microsoft Management Console closes without
saving your changes.
Summary
There are three different types, or classes, of property sheets within
Internet Information Server. They are the Master, Default,
and File property sheets. The property sheets in Internet
Information Server are organized within a hierarchy such that the settings
of the Master property sheets are passed on to the Default
property sheets, which are passed on to the File property sheets.
You can use WWW property sheets to configure the different areas of
your Web site, folder, or file. Each set of the WWW property sheets is
made up of the following nine component property sheets:
- Web Site
- Operators
- Performance
- ISAPI Filters
- Home Directory
- Documents
- Directory Security
- HTTP Headers
- Custom Errors
You can change the settings on these property sheets at any time as
needed.
Lesson 3: Virtual Directories
A virtual directory is a folder that is not physically contained within
the Internet Information Server service (WWW or File Transfer Protocol
[FTP]) home folder, but which appears as though it were to users who visit
your Web site. In this lesson, you learn about the different types of
virtual directories, how to create them, and how to administer them.
After this lesson, you will be able to:
- Describe the different aspects of a virtual directory.
- Create and administer a WWW Service virtual directory using the ISM
snap-in.
Estimated lesson time: 20 minutes
Virtual directories increase your flexibility when determining where to
store files on your server. By using virtual directories you can store
files where they are most easily updated or accessed. Virtual directories
also allow you to add storage capacity for your Web site without having to
shut down your server.
However, you may experience a drop in performance when accessing
folders contained on another computer's disk. This performance drop is due
to the transfer speed of data over a LAN.
Virtual directories can be established for both WWW and FTP Services
running on Internet Information Server. Virtual directories can be created
for folders located on:
- The same disk as the Wwwroot or Ftproot (home) directories.
- Another disk inside the local computer.
- Another computer's disk on the network. This computer must be
located within the same Windows NT Server domain as the Internet
Information Server computer.
Local Virtual Directory
You can create local virtual directories for folders stored on any disk
installed in the same computer as the disk running Internet Information
Server.
When configuring a local virtual directory, you must assign an alias to
the folder. This alias can be the folder's name or any other name that
identifies the site to the user. You must also be prepared to provide the
virtual directory's full path.
Remote Virtual Directory
You can use remote virtual directories for folders stored on disks
installed in other computers within the Internet Information Server
computer's domain.
As with local virtual directories, when configuring a remote virtual
directory, you are asked to assign an alias to the folder. You must also
supply the folder's universal naming convention (UNC) address. In order to
access the folder with a UNC, you have to enter a valid user name and
password. The user name and password you enter is automatically used by
visitors who access data contained within this virtual directory.
Caution Make sure that the user account you establish to allow
Internet access to a remote virtual directory provides only the minimum
permissions required to use the site. Do not use the administrator's
account to access virtual directories.
Virtual Directory Administration
You can create a virtual directory with any Internet Information Server
administration tool. Each tool uses a different user interface for
creating virtual directories.
The ISM snap-in for Microsoft Management Console uses the New Virtual
Directory wizard to lead you through the virtual directory creation
process. After you have established the virtual directory, you can use the
Virtual Directory property sheet to modify its configuration.
HTML-based Administration (HTMLA), the HTML-based ISM, uses a Web page
to lead you through the creation of the virtual directory. You can use
this administration tool to establish and modify virtual directories
remotely.
With Windows Scripting Host (WSH) you can create virtual directories
automatically using scripts.
Practice
In this practice, you set up a virtual directory. To set up a virtual
directory, you must use Microsoft Windows NT Explorer to create and share
the folder with the appropriate permissions. You then use ISM to create
the virtual directory.
To create a local virtual directory
- Create the C:\Inetpub\Vdir folder.
- Copy the Default.asp file from the C:\Inetpub\Wwwroot folder to the
C:\Inetpub\Vdir folder.
- Start Internet Service Manager.
- Right-click Default Web Site.
A context menu appears.
- Click New, and then click Virtual Directory.
The New Virtual Directory wizard
appears.
- Type MyVirSite as the alias to be used.
- Click Next.
- Type the path c:\inetpub\vdir and then click Next.
- Click Finish.
- Start Internet Explorer and then in the Address box,
type
http://computername/myvirsite
The Internet Information Server home page
appears.
- Switch to Internet Service Manager.
- In the left pane, select MyVirSite, and then press F2.
The ISM interface allows you to rename
MyVirSite.
- Rename MyVirSite to OldVirSite.
- Switch to Internet Explorer, and then click Refresh.
The HTTP/1.0 404 Object not found message
appears.
- In the Address box, type
computername/oldvirsite and then press ENTER.
The Internet Information Server home page
appears.
Virtual Directories and FrontPage
The Microsoft FrontPage Web authoring and management tool automatically
manages virtual directory use. When installed, FrontPage sets up virtual
directories for the folders containing executable FrontPage server
extensions. In addition, by marking folders as executable you permit them
to include such executable objects as:
- Active Server Pages (.asp)
- Internet database connector files (.idc)
- Common Gateway Interface (CGI) scripts (.exe)
- ISAPI extensions (.dll)
- Practical Extraction and Report Language (PERL) scripts (.pl)
Note Because it does not support noncontiguous content areas,
you cannot use virtual directories to merge noncontiguous content areas in
FrontPage.
Summary
A virtual directory is a folder that is not physically contained within
the Internet Information Server service (WWW or FTP) home folder. You can
create two types of virtual directories with Internet Information Server,
local and remote. A local virtual directory is located on a disk contained
within the same computer as the disk running Internet Information Server.
A remote virtual directory is located on a different computer located
within the same domain as the computer running Internet Information
Server. You can create virtual directories with any Internet Information
Server administration tool, and use Microsoft FrontPage to automatically
manage them.
Lesson 4: Virtual Servers
Multiple domain names can be hosted on a single computer running
Internet Information Server by using virtual servers. This lesson
describes virtual servers, their setup, and their administration.
After this lesson, you will be able to:
- Describe two methods of assigning an IP address to virtual servers
running on Internet Information Server.
- Create and administer a WWW Service virtual server.
Estimated lesson time: 15 minutes
With virtual servers you can host multiple Web and FTP sites on a
single computer running Internet Information Server, which means you do
not need to allocate one computer and software package for each site. You
simply need to obtain a unique IP address for each domain name assigned to
the server, and by using Host Headers you can use a single IP address for
multiple domain names. However, only WWW sites can use Host Headers.
Virtual servers also centralize administration and simplify server
software upgrades.
Hosting multiple virtual servers on the same computer may reduce
overall server performance, and virtual Web servers using Host Headers
require an HTTP version 1.1-compliant Web browser.
Host Headers
The Host Headers capability of HTTP 1.1 allows you to associate
multiple host names with a single IP address. Internet Information Server
uses Host Header information when building redirects to the different
virtual host names. To use Host Headers, you must provide a host
name-to-IP address resolution using either a domain name system (DNS)
server or HOSTS files. A HOSTS file provides name resolution for host
names to IP addresses.
Note Web browsers that are not HTTP 1.1-compliant can access
URLs with Host Headers. Internet Information Server provides non-compliant
browsers with a list of servers associated with a given IP address. When
the user selects a server, a cookie is placed on the user's disk to direct
all future access to the virtual server.
Virtual Server Administration
You can create a virtual server with any Internet Information Server
administration tool. Each tool uses a different user interface for
creating virtual servers.
The ISM snap-in for Microsoft Management Console uses the New Web Site
wizard or New FTP Site wizard to lead you through the virtual server
creation process. After you have established the virtual server, you can
use the Virtual Server property sheets to modify its configuration.
HTLMA uses a Web page to lead you through the creation of the virtual
server. You can use this administration tool to establish and modify
virtual servers remotely.
With WSH, you can create virtual servers automatically using scripts.
Practice
In this practice, you configure a virtual server by using Windows NT
Explorer to create and share the folder with the appropriate permissions.
You then use Internet Service Manager to create the virtual server. You
can use the optional loopback address to connect to your server to perform
these virtual server procedures.
Note The loopback IP address is 127.0.0.1. The loopback address
uses loopback drivers to reroute outgoing packets back to the source
computer. The loopback drivers allow the packets to bypass the network
adapter card completely and return directly to the computer that is
performing the action.
To add a WWW virtual server
- Start Windows NT Explorer.
- Create the C:\Inetpub\Vroot folder.
- Copy the contents of C:\Inetpub\Wwwroot to C:\Inetpub\Vroot.
- Start Internet Service Manager, and then right-click your
computer icon.
A context menu appears.
- Click New, and then click Web Site.
The New Web Site wizard appears.
- In the Description box, type copy of wwwroot
- Click Next.
- In the IP Address box, select your server's IP address or
your loopback address (127.0.0.1).
Leave the entry as 80 in the TCP Port this
Web Site should use (Default: 80) text box.
- Click Next.
- Type the path to C:\Inetpub\Vroot.
- Click Next.
Only the Read and Script boxes
should be selected.
- Click Finish.
- Right-click the Copy of WWWRoot Web site, and then click
Properties.
The Properties dialog box
appears.
- On the Web Site tab, click Advanced.
- Select your IP address.
- Click Add.
- In the IP Address box, select your IP address.
- In the TCP Port Of box, type 80
- In the Host Header Name box, type computernameA
For example, if your computer name is Server1,
the Host Header name for your virtual server is Server1A.
- Click OK.
- In the Advanced Multiple Web Site Configuration box, click
OK.
- Click OK to return to Internet Service Manager.
Note This new virtual server inherits its property sheet
settings from the WWW or FTP Services Master property sheets.
To start your new Web site
- Right-click Copy of WWWRoot.
A context menu appears.
- Click Start.
To test your virtual server
- Start Internet Explorer.
- In the Address box, type computernameA and then
press ENTER.
The Microsoft Internet Information Server home
page appears. This verifies that your virtual server is working using
host headers.
- Close Internet Explorer.
Summary
With virtual servers you can host multiple Web and FTP sites on a
single computer running Internet Information Server. The Host Headers
capability of HTTP 1.1 allows you to associate multiple host names with a
single IP address. You can use any Internet Information Server
administration tool to create virtual servers.
Review
The following questions are intended to reinforce key information
presented in this chapter. If you are unable to answer a question, review
the appropriate lesson, and then try the question again.
- You are interested in changing your Web site configurations
pertaining to connections—how many users are connecting, how many users
can connect, and how long you tolerate an idle connection before
dropping it. Where would you go to adjust these functions?
_________________________________________________________________
_________________________________________________________________
_________________________________________________________________
_________________________________________________________________
- You are working on the beta release of a new product and want to
allow the members of your team—and no one else—to access documentation
on the intranet. Which property sheet helps you to configure your Web
site in this way, and what are the steps you must take to configure your
site?
_________________________________________________________________
_________________________________________________________________
_________________________________________________________________
_________________________________________________________________
- You are concerned about users having Write privileges to your Web
site. Which property sheet contains this information? Would a user
require any special browser functionality in order to write to a Web
site?
_________________________________________________________________
_________________________________________________________________
_________________________________________________________________
_________________________________________________________________
- After installing Internet Information Server, you configure 10
virtual servers. To verify that the virtual servers are working, you
copy the Default.asp file from Inetpub\Wwwroot into the home folder of
each virtual server. When you test each of the virtual servers, none of
the images on the page are displayed. After troubleshooting, you
determine that all of the images are in virtual directories, and these
virtual directories are only accessible from the default Web site. How
do you make them accessible from all virtual servers?
_________________________________________________________________
_________________________________________________________________
_________________________________________________________________
- You are the administrator for an intranet at a small accounting firm
with 10 employees and 15 computers running Windows NT 4.0. After
installing Internet Information Server and configuring three virtual
servers, users complain they can only display the default WWW server.
What must you do so that the virtual servers are working?
_________________________________________________________________
_________________________________________________________________
- You are the administrator for an intranet at a large accounting firm
with 1000 employees and 1500 computers running Windows NT 4.0. After
installing Internet Information Server, creating three virtual servers,
and installing DNS, users complain they can only display the default WWW
server. What must you do so that the clients can display the pages on
the virtual servers?
_________________________________________________________________
_________________________________________________________________