Virtual hosting enables you to configure your filer to host several IP addresses using only one physical interface. Virtual hosting is useful if, for example, an Internet provider wants to host several Web sites but has only one physical interface.
When virtual hosting is enabled, an HTTP server uses the IP address pointed to by an incoming HTTP request to find the directory that contains the HTTP pages belonging to the virtual host.
To enable virtual hosting, you
For more information about the vh interface, see the Data ONTAP command reference information for ifconfig.
You set up virtual hosting by putting subdirectory and host or address entries in the /etc/httpd.hostprefixes file. Data ONTAP redirects HTTP requests to the subdirectory and host or address listed in the /etc/httpd.hostprefixes file.
To set up virtual hosting, complete the following steps.
Assume that you added the following entry in the /etc/httpd.hostprefixes file:
/customer 192.225.37.102
/customer www.customer.com
If the HTTP server receives an HTTP request destined for one of its virtual host IP addresses, 192.225.37.102, the IP address is used to select the virtual host root directory, the /customer directory, from the /etc/httpd.hostprefixes file. An HTTP request with an HTTP 1.1 Host: header specifying www.customer.com is directed to the /customer directory. In either case, the requestor cannot get a file outside the /customer directory.
You must map virtual host addresses to the vh interface to support virtual hosting. To map virtual host addresses to the vh interface, complete the following step.
Copyright © 1994-2003, Network Appliance, Inc. All rights
reserved.
Part No. 210-00473
File: http16.htm
Last updated: 11/25/03 18:02:58