httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Boyle Owen" <>
Subject RE: [users@httpd] New to linux and apache - general question
Date Thu, 19 Aug 2004 08:55:23 GMT

> -----Original Message-----
> From: James []
> Sent: Mittwoch, 18. August 2004 23:54
> To:
> Subject: [users@httpd] New to linux and apache - general question
> HI all
> I've been listening to the posts and most of the questions are clever
> ones.
> Now mine is I feel noumb & doumb
> From a red hat(9) complete install everything
> I have set the machine to see 3 different ip addresses in the gnome
> network config file
> All the ip adresses work but only one "name" works when 
> veiwing it on my
> local network 
> I guess I need to look at DNS

If you just have one machine, there's no need for DNS - you just define
the hostname to IP mapping in /etc/hosts. Here's a how-to :

Basic Idea:

- apache listens to all active IPs on port 80 - so you don't really need
a "Listen" directive. But for explicitness, set it to "Listen 80".

- you link the VH container to the IP - for "any", put a *, eg:

<VirtualHost *>

- In Namebased virtualhosting, you define the VHs with the ServerName
which is the hostname of the machine, eg

ServerName mymachine

- Now your browser needs to convert "mymachine" to the IP (eg, so in /etc/hosts: mymachine

you can have many hosts on the same IP: mymachine myothermachine yetanothermachine

And you ahve different VHs for each one:

<VirtualHost *>
  ServerName mymachine

<VirtualHost *>
  ServerName myothermachine

<VirtualHost *>
  ServerName yetanothermachine

Owen Boyle
Disclaimer: Any disclaimer attached to this message may be ignored. 


> I've not set apache to virtual hosting - just as it came no changes
> What I'd like to  do is set up virtual hosting i.e  one ip address and
> multiple domains.
> I've looked at the "how to's" and the manuals and feel like 
> I'm running
> around in circles 
> Can someone point me in the right direction a sort of abc? - do I have
> to set up DNS if so what type at the moment it only needs to 
> work on my
> local network.
> Or do I just list different names in the host.conf file
> Sorry some of us are real doumb
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP 
> Server Project.
> See <URL:> for more info.
> To unsubscribe, e-mail:
>    "   from the digest:
> For additional commands, e-mail:
Diese E-mail ist eine private und persönliche Kommunikation. Sie hat
keinen Bezug zur Börsen- bzw. Geschäftstätigkeit der SWX Gruppe. This
e-mail is of a private and personal nature. It is not related to the
exchange or business activities of the SWX Group. Le présent e-mail est
un message privé et personnel, sans rapport avec l'activité boursière du
Groupe SWX.

This message is for the named person's use only. It may contain
confidential, proprietary or legally privileged information. No
confidentiality or privilege is waived or lost by any mistransmission.
If you receive this message in error, please notify the sender urgently
and then immediately delete the message and any copies of it from your
system. Please also immediately destroy any hardcopies of the message.
You must not, directly or indirectly, use, disclose, distribute, print,
or copy any part of this message if you are not the intended recipient.
The sender's company reserves the right to monitor all e-mail
communications through their networks. Any views expressed in this
message are those of the individual sender, except where the message
states otherwise and the sender is authorised to state them to be the
views of the sender's company. 

The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message