[nzlug] Apache Restarting Problems

Steve Holdoway steve at greengecko.co.nz
Wed Mar 19 14:05:00 NZST 2008


On Wed, 19 Mar 2008 14:55:30 +1300
Rob <bubaphex at gmail.com> wrote:

> great ! thanks this works.
> 
> I ran into another problem, my virtual hosts dont work now that i've
> restarted it. my domain points to the ip address of the server but it only
> shows the root directory no the the individual vh dir. This looks rite to me
> but is it ?
> 
> ### Section 3: Virtual Hosts
> 
> 
> NameVirtualHost my.uber.ip.address:80
> 
> 
> # my 1st VH
> <VirtualHost my.uber.ip.address:80>
>     ServerAdmin me at mydomain.co.nz
>     DocumentRoot /var/www/html/mydir1/
>     ServerName mydomain1.co.nz
>     ServerAlias www.mydomain1.co.nz
>     ErrorLog /var/www/apachelogs/error/1my_error_log.txt
> </VirtualHost>
> 
> # My 2nd VH
> <VirtualHost my.uber.ip.address:80>
>     ServerAdmin me at mydomain.co.nz
>     DocumentRoot /var/www/html/mydir2/
>     ServerName mydomain2.co.nz
>     ServerAlias www.mydomain2.co.nz
>     ErrorLog /var/www/apachelogs/error/2my_error_log.txt
> </VirtualHost>
> 
> # My 3rd VH
> <VirtualHost my.uber.ip.address:80>
>     ServerAdmin me at mydomain.co.nz
>     DocumentRoot /var/www/html/mydir3/
>     ServerName mydomain3.co.nz
>     ServerAlias wwww.mydomain3.co.nz
>     ErrorLog /var/www/apachelogs/error/3my_error_log.txt
> </VirtualHost>

I always use 
  <VirtualHost my.virtual.host.name:80>
instead of the 
  <VirtualHost my.uber.ip.address:80>
as it's an instant check that the ip addresses are being resolved. The definitions look ok - are there any pointers either on the console or in /var/www/apachelogs/error/1my_error_log.txt??

Steve.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://www.linux.net.nz/pipermail/nzlug/attachments/20080319/793a9951/attachment-0001.pgp


More information about the NZLUG mailing list