Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Another Novice Question

Status
Not open for further replies.

Chewie71

MIS
Sep 4, 2001
89
US
Apache is installed at /var/I've installed the HORDE webmail package at /var/
Right now I can type ANYTHING.domain.net and it sends the browser to /var/ Where ANYTHING is just that...any word I choose. Specifically all I really care about is and mail.domain.net. I'd like mail.domain.net to point to or be redirected to horde so the webmail login shows up instead of the homepage.

I've tried adding a VirtualHost for mail.domain.net with DocumentRoot set to /var/ but I get...
Not Found
The requested URL /horde/login.php was not found on this server.

That file does exist though, and I can browse directly to mail.domain.net/horde and it will go right to the login page.

What am I doing wrong here?

Thanks for any help...
Matt
 
First of all, I just want to make sure you know if you use one vhost, you must use vhosts for all your domains and sub-domains. Your problem could be from using domain.net as the ServerName without the www. If this is the case, all sub-domains including match and you will have this problem. If this doesn't do the trick, here's a quick check list.

NameVirtualHost * (use name based addressing)

UseCanonicalName Off (some distros want this in each vhost)

Your vhost containers should look like the one below. Note that if you use this example, the logs directory must exist or apache won't start. I do it this way so each domain will have its own logs where the webmaster can access them. I also like to keep the vhost section at the bottom of httpd.conf for easier editing.

<VirtualHost *>

ServerAdmin webmaster@mydomain.com
DocumentRoot /var/ ServerName ErrorLog /var/ CustomLog /var/ combined

<Directory &quot;/var/
Options Indexes FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all

</Directory>

ScriptAlias /cgi-bin/ &quot;/var/
<Directory &quot;/var/
AllowOverride None
Options All +ExecCGI
Order allow,deny
Allow from all

</Directory>


</VirtualHost>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top