Configuring Properties Changing Master Properties Using Property Inheritance Modifying Properties for IIS Objects Configuring an FTP Site Assigning Web Site Operators **************
Trang 1Contents
Overview 1
Creating Custom Error Messages 16
Lab A: Creating and Configuring
Review 30
Module 2: Configuring Web and FTP Sites
Trang 2to represent any real individual, company, product, or event, unless otherwise noted Complying with all applicable copyright laws is the responsibility of the user No part of this document may
be reproduced or transmitted in any form or by any means, electronic or mechanical, for any purpose, without the express written permission of Microsoft Corporation If, however, your only means of access is electronic, permission to print one copy is hereby granted
Microsoft may have patents, patent applications, trademarks, copyrights, or other intellectual property rights covering subject matter in this document Except as expressly provided in any written license agreement from Microsoft, the furnishing of this document does not give you any license to these patents, trademarks, copyrights, or other intellectual property
2001 Microsoft Corporation All rights reserved
Microsoft, Active Directory, ActiveX, BackOffice, FrontPage, MS-DOS, Outlook, PowerPoint, SQL Server, Visual Basic, Visual InterDev, Visual SourceSafe, Visual Studio, Windows, Win32, Windows Media, and Windows NT are either registered trademarks or trademarks of Microsoft Corporation in the U.S.A and/or other countries
Other product and company names mentioned herein may be the trademarks of their respective owners
Trang 3Instructor Notes
This module provides students with the knowledge and skills to create and configure Microsoft® Internet Information Services (IIS) 5.0 Web and File Transfer Protocol (FTP) sites The module consists of lecture, class discussion, and hands-on labs
After completing this module, students will be able to:
Configure and modify the master properties
Create and configure additional Web and FTP sites
Create virtual directories
Redirect requests to another directory or program
Create custom error messages
Materials and Preparation
This section provides the materials and preparation tasks that you need to teach this module
Required Materials
To teach this module, you need the Microsoft PowerPoint® file 2295A_02.ppt
Preparation Tasks
To prepare for this module, you should:
Read all of the materials for this module
Complete the lab
Presentation:
30 Minutes
Lab:
45 Minutes
Trang 4Instructor Setup for a Lab
This section provides setup instructions that are required to prepare the instructor computer or classroom configuration for a lab
Lab A: Creating and Configuring Additional Web and FTP Sites
To prepare for the lab
1 Read the module
2 Complete the labs from Module 1
Module Strategy
Use the following strategy to present this module:
Configuring Properties Explain how to configure and manage properties in general Specific properties that require extensive explanation, such as security properties, are covered in other modules Explain the relationship between master
properties and object properties, particularly how inheritance can be used to manage properties
Creating Additional Sites Discuss the methods for hosting multiple sites on a single server Mention that the host header method cannot be used for FTP sites
Creating Virtual Directories Explain how virtual directories can be used to create an extensive Web site without requiring that all content be stored on the Web server
Redirecting Requests Explain when it is useful to redirect requests Demonstrate the procedure
Creating Custom Error Messages Discuss the purpose of error messages Show the location of the IIS error messages and demonstrate how to edit them
Trang 5Customization Information
This section identifies the lab setup requirements for a module and the configuration changes that occur on student computers during the labs This information is provided to assist you in replicating or customizing Microsoft Official Curriculum (MOC) courseware
The lab in this module is also dependent on the classroom configuration that is specified in the Customization Information section at the
end of the “Classroom Setup Guide” for Course 2295A, Implementing and
Supporting Microsoft Internet Information Services 5.0
Lab Setup
The following list describes the setup requirements for the lab in this module
Setup Requirement 1
The lab in this module requires the FTP service To prepare student computers
to meet this requirement, perform one of the following actions:
• Complete Module 1, “Installing Internet Information Services 5.0,” in
Course 2295A, Implementing and Supporting Microsoft Internet
Information Services 5.0
– Or –
To install FTP
1 Open Control Panel
2 Double-click Add/Remove Programs
3 Click Add/Remove Windows Components
4 Click Internet Information Services (IIS), and then click Details
5 In the Internet Information Services (IIS) dialog box, select the File Transfer Protocol (FTP) Server check box, and then click OK
6 Click Next, follow the on-screen instructions, and then click Finish
Important
Trang 7Overview
Configuring Properties
Creating Additional Sites
Creating Virtual Directories
Redirecting Requests
Creating Custom Error Messages
***************************** ILLEGAL FOR NON - TRAINER USE ******************************
Each Web server contains a set of master properties that are applied to each Web site created on that Web server You can change the master properties so that your desired settings are used automatically whenever you create a Web site
You can create additional Web sites and virtual directories to form an efficient Web structure for your business needs To provide a more useful experience for clients who connect to your Web site, redirect requests as necessary and customize the error messages
After completing this module, you will be able to:
Configure and modify the master properties
Create and configure additional Web and File Transfer Protocol (FTP) sites
Create virtual directories
Redirect requests to another directory or program
Create custom error messages
In this module, you will learn
how to create and configure
Web and FTP sites
Trang 8Configuring Properties
Changing Master Properties
Using Property Inheritance
Modifying Properties for IIS Objects
Configuring an FTP Site
Assigning Web Site Operators
***************************** ILLEGAL FOR NON - TRAINER USE ******************************
When you install Microsoft® Internet Information Services (IIS) 5.0, default values are assigned to the properties for the Web server, the Web and FTP sites, and all the folders and files within those sites You can use these default settings, or you can change them to suit your Web publishing needs You may
be able to provide better performance and improved security by making adjustments to the default settings
You can set master properties that are inherited by all sites, or you can set properties on an object such as an individual site, folder, or file Properties set
on an object override the master properties
This module explains some general configuration properties For more detailed information about setting properties, see the following modules in
Course 2295A, Implementing and Supporting Microsoft Internet Information
Services 5.0
For more information on See
Setting security properties Module 5, “Implementing Security on a
You can change the default
properties for a Web site
Explain to students that
specific properties, such as
security settings and
performance settings, are
explained in other modules
Note
Trang 9Changing Master Properties
Master Properties
Default Web SiteHtmldocsDefault.htm
FTP Service WWW Service
Layout.cssGraphicsDefault FTP Site
***************************** ILLEGAL FOR NON - TRAINER USE ******************************
When you install IIS, your Web server is configured with default master properties Master properties apply to the Web and FTP sites on that server, and
to the folders and files within those sites When configuring your Web site, you can modify the master properties so that all the Web and FTP sites that you create inherit the appropriate settings
There are two sets of master properties: WWW service master properties, which apply to Web sites, and FTP service master properties, which apply to FTP sites The FTP service master properties are only available if you have installed the FTP service
To change the master properties:
1 Click Start, point to Programs, point to Administrative Tools, and then click Internet Services Manager
In Administrative Tools, the IIS console is called Internet Services Manager However, when you open the console, it is called Internet Information Services, also known as the IIS snap-in
2 In the IIS snap-in, right-click the Web server, and then click Properties
3 Under Master Properties, select WWW Service or FTP Service
4 Click Edit
5 Click Apply after you change a property
6 Click OK when you are finished
If you want information on a specific property or value, click Help on
the property sheet
Topic Objective
To explain the purpose of
master properties and how
to change them
Lead-in
When you install IIS, your
Web server is configured
with default master
properties
Delivery Tip
Demonstrate how to open
the WWW service and FTP
service master properties
Note
Trang 10Using Property Inheritance
Properties on Higher Levels Inherited by Lower Levels
A Property Change at Site, Directory, or File Level Overrides the Master Property
For that level
For any lower levels that you select
List Values are Treated as a Single Property
***************************** ILLEGAL FOR NON - TRAINER USE ******************************
Master properties are inherited by all the sites that you create, and by the directories and files within those sites You can change properties at the site and directory levels for FTP sites, and also at the file level for Web sites Settings
on lower levels inherit the values from higher levels For example, a file inherits properties set at the directory level
Properties that you change at the site, directory, or file level override the master property When you change a property for an individual site, directory, or file, you can select which lower level objects should inherit the new property value Some properties have a value that takes the form of a list For example, the value of the default document can be a list of documents IIS treats the entire list as a single property When you change a list property and select to apply the change to lower level objects, the entire list for the lower level object is
replaced by the new list; lists are not merged
Topic Objective
To explain how properties
are inherited by IIS objects
Trang 11Modifying Properties for IIS Objects
Default Web Site Properties
***************************** ILLEGAL FOR NON - TRAINER USE ******************************
Sites, directories, and files are all IIS objects that can have properties assigned
to them Each type of object is associated with those master properties that are applicable to that object type, and may also be associated with properties that are unique to that object type For example, content expiration is a master property that you can also set individually for a site, directory, or file In contrast, the home directory master property can only be set for a Web or FTP site
To set properties on an object:
1 In the IIS snap-in, right-click the site, directory, or file for which you want
to set properties, and then click Properties
2 Click Apply after you change a property
3 Click OK when you are finished
Changing the Home Directory
The local path for the home directory determines the location of the published content for a site By default, the home directory for the default Web site is C:\Inetpub\Wwwroot and the home directory for the default FTP site is C:\Inetpub\Ftproot
The home directory for the default Web site contains files with links to help files, administrative tools, and other resources It is considered a good security practice to locate the home directories of any additional Web sites that you create in a designated folder outside of the Wwwroot folder In addition, this folder should be located on a disk partition other than the one containing your system files This structure makes your Web sites easier to manage and provides extra security for them
Topic Objective
To explain how to change
properties for sites,
directories, and files
Lead-in
You can set properties on
sites, directories, and files
Trang 12To change the home directory:
1 In the IIS snap-in, right-click the Web or FTP site for which you want to
change the home directory, and then click Properties
2 On the Home Directory tab, specify the location for the home directory
You can select from the following options:
• A directory located on a hard disk on your computer
• A shared directory located on another computer
• A redirection to a Uniform Resource Locator (URL) (for Web sites only)
3 Click OK
Assigning a Default Document
The default document is the file sent by your Web server when it receives a
request for a URL that does not specify a file name You can use a default document as a home page to provide users with an introduction to your Web site and navigation assistance
When you open the Documents property page, Default.asp and Default.htm are
listed by default for Web sites However, IIS 5.0 does not provide these files You can either create default documents that use these file names or add other document names to the default documents list
To add a default document:
1 In the IIS snap-in, right-click the Web site to which you want to add a
default document, and then click Properties
2 On the Documents tab, ensure that the Enable Default Document check box is selected, and then click Add
3 In the Default Document Name box, type in the name of the document that you want to add, and then click OK
When you assign multiple default documents, the Web server searches for the default document in the order that the names appear on the list The server returns the first document it finds To change the search order, select a document in the list of default documents, and then click the arrows to move the selected document up or down accordingly
Trang 13Configuring an FTP Site
UNIX-style Listing
DOS-style Listing Welcome Message
***************************** ILLEGAL FOR NON - TRAINER USE ******************************
When you install IIS, a default FTP site is created Two properties you can configure that determine what a client will see when connecting to your FTP site are the directory listing style and the informational messages
Directory Listing Style
The directory listing style defines which format will be used when an FTP client sends a LIST operation: Microsoft MS-DOS® or UNIX The default directory listing style is MS-DOS
The MS-DOS directory listing style displays dates with a two-digit year by default The UNIX directory listing style displays dates with a four-digit year However, when the date of the file contains the current year, the year is not displayed The UNIX directory listing also displays file and folder permissions
To set the directory listing style of your FTP site:
1 In the IIS snap-in, right-click the FTP site for which you want to set the
directory listing style, and then click Properties
2 On the Home Directory tab, under Directory Listing Style, select either the UNIX or MS-DOS check box, and then click OK
Topic Objective
To explain how to configure
FTP-specific settings
Lead-in
For every FTP site, you
should configure the
directory listing style and
informational messages
Trang 14Informational Messages
IIS allows you to specify three types of messages for users visiting your FTP site: a welcome message, an exit message, and a maximum connections message The welcome message greets users to the FTP site when they first log
on The exit message displays when users log off the site The maximum connections message informs a potential user that your site has reached the maximum number of allowable connections
To set the FTP welcome, exit, or maximum connections message:
1 In the IIS snap-in, right-click the FTP site for which you want to set a
message, and then click Properties
2 On the Messages tab, type the welcome, exit, or maximum connections messages into the Welcome, Exit, and Maximum Connections boxes, respectively, and then click OK
Trang 15Assigning Web Site Operators
Administrator Account
All Web Sites Internet Information Services
Computer Hosting IIS
Web Site Operator Account
Web Site 1 Only
Web Site Operator Account
Web Site 2 Only
Web Site Operator Account
Web Site 3 Only
***************************** ILLEGAL FOR NON - TRAINER USE ******************************
Only Administrators can administer Web sites If you want to distribute administrative tasks to other users without giving them Administrator access, add them as Web site operators Web site operators are Windows user accounts that have limited administration privileges on a Web site Operators can administer properties that affect only their respective sites
Each operator can act as the site administrator for his or her particular Web site and can change or reconfigure the site as necessary For example, the operator can set Web site access permissions, enable logging, change the default document, set content expiration, and enable content ratings features
Web site operators do not have access to properties that affect IIS, the Windows server computer hosting IIS, or the network For example, operators are not permitted to change the identification of Web sites, configure the anonymous user name or password, throttle bandwidth, create virtual directories or change their paths, or change application isolation In addition, operators are unable to remotely browse the file system and therefore cannot set properties on
directories and files unless a Universal Naming Convention (UNC) path is used
Topic Objective
To explain how to add
operators to a Web site
Trang 16To add a Web site operator:
1 In the IIS snap-in, right-click the Web site to which you want to add an
operator, and then click Properties
2 On the Operators tab, under Web Site Operator, click Add
3 In the Select Users or Groups dialog box, in the Name list, click the user
or group that you want to add, click Add, and then click OK
To remove a Web site operator:
1 In the IIS snap-in, right-click the Web site from which you want to remove
an operator, and then click Properties
2 On the Operators tab, in the Operators box, select the user or group that you want to remove, and then click Remove
Trang 17Creating Additional Sites
Web Site 1
Web Site 2
Web Site 3
Append Port Numbers
Append Port Numbers Addresses Multiple IP
Multiple IP Addresses Host Headers
1051 192.168.8.255 http://production192.168.8.255 http://production 192.168.114.10http://production192.168.114.10http://production
***************************** ILLEGAL FOR NON - TRAINER USE ******************************
You can create multiple Web and FTP sites on a single computer Each site must have a unique identification
Identifying Multiple Sites
With IIS, you can identify your sites in one of three ways
You can assign one Internet Protocol (IP) address to many sites by using appended port numbers Clients must type in the URL or the IP address for the Web site, followed by a colon and the port number, to reach your site For example, a user would type http://london.nwtraders.msft:1596 or http://192.168.1.1:1596 where 1596 is the port number In addition, if your network or the client’s network uses a firewall
or proxy server, the firewall or proxy server must be configured to permit traffic through those port numbers
You can differentiate between multiple Web sites
by assigning to each site one or more unique IP addresses to which the site will respond You must add the host name and its corresponding IP address to the Domain Name Service (DNS) server that is authoritative for your domain
Topic Objective
To explain how to add sites
to an IIS server
Lead-in
You can host multiple Web
and FTP sites on an IIS
server
Use a single IP address with appended port numbers
Use multiple IP addresses
Trang 18You can differentiate between multiple sites that respond to the same IP address
by using host headers In this method, IIS examines the URL passed in the Hypertext Transfer Protocol (HTTP) header from the client to determine which site is being requested This method is not available for FTP sites or sites that use Secure Sockets Layer (SSL)
Only browsers compatible with the HTTP 1.1 protocol, such as Microsoft Internet Explorer version 3.0 and later and Netscape Navigator 2.0 and later, support host headers
You can combine the methods of identifying multiple Web sites For example, you can have two IP addresses on a server and 20 Web sites, with 10 host header sites on each IP address
Adding a New Site
You can add as many new sites to your computer as you need
To add a new site:
1 In the IIS snap-in, right-click the computer, click New, and then click Web Site or FTP Site
The Web Site Creation Wizard or FTP Site Creation Wizard starts
2 Follow the on-screen directions to assign identification information to your new site You must provide the port number and the home directory path If you are adding additional sites to a single IP address by using host headers, you must assign a host header name
In the IP address property, All Unassigned refers to IP addresses that are
assigned to a computer but not assigned to a specific site When a Web site
is configured to use all unassigned for an IP address, it uses all of the IP addresses that are not assigned to other sites
Assigning a Host Header Name
The host header name is the name that you want the Web site to respond to Users can connect to your site by typing the host header name in the address bar
of their browsers For example, to connect to www.xyz.com, type in www.xyz.com, not the computer name or xyz.com
Typically, you will create two host header entries for your site to make your Web site more accessible to customers, for example, one for xyz.com and one for www.xyz.com You can have a site respond to many names using this technique Ask your system administrator to add the new site name mapping for your static IP address to the DNS server
To assign a host header name:
1 In the IIS snap-in, right-click the Web site to which you want to add a host
header name, and then click Properties
2 On the Web Site tab, click Advanced
3 On the Advanced Multiple Web Site Configuration dialog box, under Multiple identities for this Web site, click Add to assign a host header
name, IP address, and port for a Web site
Use a single static IP address with host header names (Web sites only)
Note
Delivery Tip
Demonstrate how to add a
host header to a Web site
Trang 19Creating Virtual Directories
C:\Sales C:\Sales\Quotes
\\Server2\Customers
\\Server2\PR C:\Sales\Orders
Sales Customers Orders PR Quotes
Virtual directories
http://sales http://sales/quotes http://sales/orders http://sales/customers http://sales/pr
Physical Location Virtual Location
***************************** ILLEGAL FOR NON - TRAINER USE ******************************
A virtual directory is a directory that points to another directory on either your
computer or another computer When you want to publish content that does not reside in your home directory, use a virtual directory You can also use virtual directories to organize your site content and to specify different URLs for different parts of your site
A virtual directory has an alias, a name that Web browsers use to access that directory Aliases provide benefits for you and for your users An alias is usually shorter than the path name of the directory, so it is more convenient for users to type An alias is also more secure; users do not know where your files are physically located Finally, aliases make it easier for you to move
directories in your site Rather than changing the URL for the directory, you change the mapping between the alias and the physical location of the directory
To create a virtual directory:
1 In the IIS snap-in, right-click the Web or FTP site to which you want to add
a virtual directory
2 Point to New, and then click Virtual Directory
3 Use the Virtual Directory Creation Wizard to assign an alias, specify the path, and set permissions
To delete a virtual directory, right-click the virtual directory that you want to
delete, and then click Delete Deleting a virtual directory does not delete the
corresponding physical directory or files
Topic Objective
To explain how to create
virtual directories in a site
Lead-in
You can publish content that
does not reside in your
home directory by using
virtual directories
Delivery Tip
Point out the difference
between the icons for
directories and virtual
directories