a couple questions about virtual hosts in Apache

Scott sberry at northlc.com
Fri Aug 10 19:57:37 UTC 2007


Hi Tim,

Another question.  So is this where I would for example put 
bugzilla.pilotalk.com or is this only where any thing relating to 
www.pilotalk.com goes?

ServerAlias alternatives that will be accepted, even if you rewrite them
(as your rewrite rule did below).




--- Original Message ----- 
From: "Tim" <ignored_mailbox at yahoo.com.au>
To: "For users of Fedora" <fedora-list at redhat.com>
Sent: Friday, August 10, 2007 12:37 PM
Subject: Re: a couple questions about virtual hosts in Apache


> On Fri, 2007-08-10 at 11:45 -0500, Scott wrote:
>> I still seem to have the same problem where index.php is not coming up
>> properly.  by this I mean I cannot see it at all.
>
> A 404 error?
>
>> Here is what my virtual host looks like for this.
>> NameVirtualHost *:80
>>
>> <VirtualHost *:80>
>> ServerName pilotalk.com
>
> Servername for what you want the address to be.
>
> e.g. ServerName www.pilotalk.com
>
>> ServerAlias pilotalk.com
>
> ServerAlias alternatives that will be accepted, even if you rewrite them
> (as your rewrite rule did below).
>
> If you only had one name, and no aliases, you'd remove the ServerAlias
> directive.
>
>> UseCanonicalName On
>> ServerAdmin webmaster at pilotalk.com
>> DocumentRoot /var/www/PilotalkBraillesoft.com
>
> File paths and names are case-sensitive on Linux, be sure that you've
> typed them correctly.
>
>> DirectoryIndex index.php
>> ErrorLog logs/PilotalkBraillesoft.com-error_log
>> CustomLog logs/PilotalkBraillesoft.com-access_log common
>> RewriteEngine On
>> RewriteCond %{HTTP_HOST} ^PILOTALK\COM$ [NC]
>
> There'd be a backslash followed by a dot before com, you've got no dot.
> The backslash is to escape the dot, so the match is for a dot being
> there.  Otherwise, the dot typed into the line would be part of a
> wildcard.  As it stands, that rewrite match wouldn't get applied.
>
>> RewriteRule (.*)$ http://www.pilotalk.com/$1 [R=301,L]
>> </VirtualHost>
>
> As Alan said, check your logs.  You've set up two, above, for this
> virtual host, check both your access and error logs.  Also, check the
> main logs for the rest of the server (i.e. if this virtual host didn't
> accept the request, the default might have, and they'll be logged
> there).  Both will be inside:  /var/log/httpd/
>
> -- 
> [tim at bigblack ~]$ uname -ipr
> 2.6.22.1-41.fc7 i686 i386
>
> Using FC 4, 5, 6 & 7, plus CentOS 5.  Today, it's FC7.
>
> Don't send private replies to my address, the mailbox is ignored.
> I read messages from the public lists.
>
>
>
> -- 
> fedora-list mailing list
> fedora-list at redhat.com
> To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
>
>
>
> -- 
> No virus found in this incoming message.
> Checked by AVG Free Edition.
> Version: 7.5.476 / Virus Database: 269.11.11/944 - Release Date: 8/9/2007 
> 2:44 PM
>
> 




More information about the users mailing list