You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by O-One <ol...@yahoo.com> on 2004/12/09 17:26:05 UTC
[users@httpd] NameVirtualHost Help Needed
Hello all,
I am about to implement VirtualHost on my server and
was wondering if someone could just help me look at
the following entry to tell me if there is any syntax
or punctuation missing or if I am okay.
I am also using a weblog for my webserver - Geeklog
OS - Windows Server Enterprise 2003
#
# Use name-based virtual hosting.
#
NameVirtualHost 192.168.2.150:80
#
# VirtualHost example:
# Almost any Apache directive may go into a
VirtualHost container.
# The first VirtualHost section is used for requests
without a known
# server name.
#
<VirtualHost 192.168.2.150:80>
ServerAdmin ola@dostech.gov.ng
DocumentRoot C:/Program Files/Apache
Group/Apache2/dostech/public_html
ServerName www.dostech.gov.ng
ServerAlias dostech.gov.ng *.dostech.gov.ng
ErrorLog logs/www.dostech.gov.ng-error_log
CustomLog logs/www.dostech.gov.ng-access_log
common
</VirtualHost>
<VirtualHost 192.168.2.150:80>
ServerAdmin ola@atb.com
DocumentRoot C:/Program Files/Apache
Group/Apache2/atb/public_html
ServerName www.atb.com
ServerAlias atb.com *.atb.com
ErrorLog logs/www.atb.com-error_log
CustomLog logs/www.atb.com-access_log common
</VirtualHost>
<VirtualHost 192.168.2.150:80>
ServerAdmin ola_one@yahoo.com
DocumentRoot C:/Program Files/Apache
Group/Apache2/tim/public_html
ServerName www.tim.com
ServerAlias tim.com *.tim.com
ErrorLog logs/www.tim.com-error_log
CustomLog logs/www.tim.com-access_log common
</VirtualHost>
Thank you
Ola
__________________________________
Do you Yahoo!?
All your favorites on one personal page � Try My Yahoo!
http://my.yahoo.com
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] NameVirtualHost Help Needed
Posted by Norman Peelman <np...@cfl.rr.com>.
----- Original Message -----
From: "O-One" <ol...@yahoo.com>
To: "Apache" <us...@httpd.apache.org>
Sent: Thursday, December 09, 2004 11:26 AM
Subject: [users@httpd] NameVirtualHost Help Needed
> Hello all,
>
> I am about to implement VirtualHost on my server and
> was wondering if someone could just help me look at
> the following entry to tell me if there is any syntax
> or punctuation missing or if I am okay.
>
> I am also using a weblog for my webserver - Geeklog
>
> OS - Windows Server Enterprise 2003
>
>
>
> #
> # Use name-based virtual hosting.
> #
> NameVirtualHost 192.168.2.150:80
>
> #
> # VirtualHost example:
> # Almost any Apache directive may go into a
> VirtualHost container.
> # The first VirtualHost section is used for requests
> without a known
> # server name.
> #
> <VirtualHost 192.168.2.150:80>
> ServerAdmin ola@dostech.gov.ng
> DocumentRoot C:/Program Files/Apache
> Group/Apache2/dostech/public_html
> ServerName www.dostech.gov.ng
> ServerAlias dostech.gov.ng *.dostech.gov.ng
> ErrorLog logs/www.dostech.gov.ng-error_log
> CustomLog logs/www.dostech.gov.ng-access_log
> common
> </VirtualHost>
>
> <VirtualHost 192.168.2.150:80>
> ServerAdmin ola@atb.com
> DocumentRoot C:/Program Files/Apache
> Group/Apache2/atb/public_html
> ServerName www.atb.com
> ServerAlias atb.com *.atb.com
> ErrorLog logs/www.atb.com-error_log
> CustomLog logs/www.atb.com-access_log common
> </VirtualHost>
>
> <VirtualHost 192.168.2.150:80>
> ServerAdmin ola_one@yahoo.com
> DocumentRoot C:/Program Files/Apache
> Group/Apache2/tim/public_html
> ServerName www.tim.com
> ServerAlias tim.com *.tim.com
> ErrorLog logs/www.tim.com-error_log
> CustomLog logs/www.tim.com-access_log common
> </VirtualHost>
>
>
> Thank you
>
> Ola
>
Ola,
You can do this instead:
<VirtualHost *>
...
</VirtualHost>
...if all you virtual hosts ip's and ports are the same. This way if the ip
changes you don't have to touch the config. * matches whatever the system is
using.
Norm
Avatar hosting at www.easyavatar.com
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] NameVirtualHost Help Needed
Posted by "Ivan Barrera A." <Br...@Ivn.cl>.
before asking someone to look the config, tell us if this config works
or not. If not, paste part of the logs.
To me, it seems ok, although i preffer using quotes in the path (in windows)
O-One wrote:
> Hello all,
>
> I am about to implement VirtualHost on my server and
> was wondering if someone could just help me look at
> the following entry to tell me if there is any syntax
> or punctuation missing or if I am okay.
>
> I am also using a weblog for my webserver - Geeklog
>
> OS - Windows Server Enterprise 2003
>
>
>
> #
> # Use name-based virtual hosting.
> #
> NameVirtualHost 192.168.2.150:80
>
> #
> # VirtualHost example:
> # Almost any Apache directive may go into a
> VirtualHost container.
> # The first VirtualHost section is used for requests
> without a known
> # server name.
> #
> <VirtualHost 192.168.2.150:80>
> ServerAdmin ola@dostech.gov.ng
> DocumentRoot C:/Program Files/Apache
> Group/Apache2/dostech/public_html
> ServerName www.dostech.gov.ng
> ServerAlias dostech.gov.ng *.dostech.gov.ng
> ErrorLog logs/www.dostech.gov.ng-error_log
> CustomLog logs/www.dostech.gov.ng-access_log
> common
> </VirtualHost>
>
> <VirtualHost 192.168.2.150:80>
> ServerAdmin ola@atb.com
> DocumentRoot C:/Program Files/Apache
> Group/Apache2/atb/public_html
> ServerName www.atb.com
> ServerAlias atb.com *.atb.com
> ErrorLog logs/www.atb.com-error_log
> CustomLog logs/www.atb.com-access_log common
> </VirtualHost>
>
> <VirtualHost 192.168.2.150:80>
> ServerAdmin ola_one@yahoo.com
> DocumentRoot C:/Program Files/Apache
> Group/Apache2/tim/public_html
> ServerName www.tim.com
> ServerAlias tim.com *.tim.com
> ErrorLog logs/www.tim.com-error_log
> CustomLog logs/www.tim.com-access_log common
> </VirtualHost>
>
>
> Thank you
>
> Ola
>
>
>
> __________________________________
> Do you Yahoo!?
> All your favorites on one personal page – Try My Yahoo!
> http://my.yahoo.com
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org