Host Directive

Top - Docs - General - Server - Resource - Access - FAQ - Tutorials

Purpose

This directive allows you to customize the server to respond to different Domain Name Server entries (CNAMEs) in different ways. You do not need a second IP address to use this directive, but only browsers that support the HEAD method will be able to use this form of multihome support. HTTPd will use the default configuration for all other browsers.


Syntax

<Host servername errorlevel>
...
</Host>
Where the valid components of the directive are the same as those for the VirtualHost directive.

Note that the Host directive only works when the connecting browser supports the HEAD method. The server will use the default configuration for all other browsers.


Virtual Host

You cannot use Host directives within Host directives or within VirtualHost directives. You may use as many Host directives as you like, up to the limits of your server's memory and operating system.

Examples

<Host www.uiuc.net>
ServerName www.uiuc.net
ServerAdmin blong@uiuc.net
DocumentRoot /www
</Host>

[Back] Return to Configuration File Overview
NCSA HTTPd Development Team / httpd@ncsa.uiuc.edu / 10-02-95