httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lee" <...@unassemble.co.uk>
Subject Re: Virtual Host Directives
Date Thu, 25 Jul 2002 09:08:19 GMT
What you are referring to is called Name-Based Virtual Hosting.  All the information you need
to get this working is in the apache documentation.  As you have not specified what version
of apache you are using I cannot be more specific but try looking at either:

http://httpd.apache.org/docs/vhosts/index.html for Apache 1.3 or
http://httpd.apache.org/docs-2.0/vhosts/ for Apache 2.

Another point.   Are you sure that it is an Apache problem, rather than DNS or your hosts
file.  If you try "ping abc.com" does it resolve to the correct IP.  I am assuming that abc.com
is not your true domain so obviously replace that domain in the ping command with the right
host.   Also try telnetting on port 80 to that host and see if it allows you to connect or
not.

As far as to answer you actual question.  Marcus has answered this for you.  By naming the
host that you wish to use for virtual hosting (NameVirtualHost directive) and using a ServerName
directive in each virtual host, you are specifying all the required information.

Regards

Lee
  ----- Original Message ----- 
  From: Vincent Kruger 
  To: users@httpd.apache.org 
  Sent: Thursday, July 25, 2002 9:30 AM
  Subject: Re: Virtual Host Directives


  Is there now way in which i can specify say the ip plus the hostmane.
  Coz i'm going to have more than one hostname on that specific IP addie.
    ----- Original Message ----- 
    From: Albrecht Marcus 
    To: 'users@httpd.apache.org' 
    Sent: Thursday, July 25, 2002 10:25 AM
    Subject: AW: Virtual Host Directives


    Hi,

    you have to use the IP from the NameVirtualHost:

    <VirtualHost 66.8.58.134:80>
      ServerAdmin hostmaster@abc.com
      DocumentRoot /home/nomza/abc
      ServerName abc.com
      ErrorLog /home/nomza/abc/error.log
      CustomLog /home/nomza/abcl/access.log common
    </VirtualHost>

    Marcus

      -----Ursprüngliche Nachricht-----
      Von: Vincent Kruger [mailto:alienator@spils.com]
      Gesendet: Donnerstag, 25. Juli 2002 10:02
      An: Apache MailingList
      Betreff: Virtual Host Directives


      Hi.

      I've setup on my server this.

      include /usr/local/conf/aliases.inc
      include /usr/local/conf/directories.inc
      include /usr/local/conf/virtualhosts.inc
      include /home/nomza/apache.virtualhosts.inc
      NameVirtualHost 66.8.58.134

      Now I've place in the file /home/nomza/apache.virtualhosts.inc this.

      <VirtualHost abc.com:80>
        ServerAdmin hostmaster@abc.com
        DocumentRoot /home/nomza/abc
        ServerName abc.com
        ErrorLog /home/nomza/abc/error.log
        CustomLog /home/nomza/abcl/access.log common
      </VirtualHost>

      What is wrong?
      When ever i call abc.com it can't find the server.

      Regards
      Vincent Kruger
      alienator@spils.com

    ---------------------------------------------------------------------------- 

    Diese E-Mail ist vertraulich und kann darüber hinaus persönliche Inhalte haben. Bitte
löschen Sie die E-Mail und benachrichtigen Sie uns sofort, wenn Sie nicht der bestimmungsgemäße
Empfänger sind. Die SYCOR AG willigt in keine Verträge oder vertragliche Verpflichtungen
ein oder übermittelt rechtsverbindliche Angebote, die in Form von E-Mail versandt werden,
sofern dies nicht ausdrücklich in schriftlicher Form zwischen den Parteien vereinbart wurde.


    This e-mail is confidential and may contain personal and/or priviledged material. Please
delete this e-mail and inform us immediately in case you are not the directed recipient. SYCOR
AG does not agree with contracts or contract obligations. Neither do we transmit legally binding
offers by e-mail unless this has been expressly agreed upon between the parties and documented
in written form.


Mime
View raw message