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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Resolve without www prefix

Status
Not open for further replies.

sarm

Programmer
Aug 13, 2001
77
US
Hi,
I can get my domain only using I would like to get my domain also without the What do I need to add? I have rh7.1 thank you.

//FROM HTTPD
# Virtual host domain.com
<VirtualHost x.x.x.x>
DocumentRoot /home/domain/www/
ServerAdmin me@domain.com
ServerName </VirtualHost>


//ZONE FILE
$TTL 86400
@ IN SOA ns1.domain.com. hostmaster.domain.com. (
20010915; Serial
10800 ; Refresh after 3 hrs
3600 ; Retry after 1 hr
604800; Expire after 1 week
86400 ) ; Minimum ttl 1 day
IN NS ns1.domain.com.
IN A x.x.x.x
www IN A x.x.x.x
ftp IN A x.x.x.x
mail IN A x.x.x.x
IN MX 5 mail.domain.com.
 
i'm not so much into the dns records, but to configure apache to act on domain.com just add
&quot;ServerAlias domain.com&quot;
in the virtualhost section for your server
hope that helps, it's working for me

 
Hi,
I added -serveralias but didn't help, thanks anyway.
Must need to do something with the dns entry as well.

<VirtualHost x.x.x.x>
DocumentRoot /home/domain/www/
ServerAdmin me@domain.com
ServerName ServerAlias domain.com
</VirtualHost>
 
Hi!

I am trying to set up a Mandrake 8.1 plus Apache (of course ;-)....

The fully qualificated domain name is but I don't know how to set up the name of the PC

If I set up my domain name as mydomain.net, then my linux box simple name must be
Thanks... Arlequín
arlequin@montevideo.com.uy
 
Hi,



Piti is right with ServerAlias but the syntax is wrong - you need something like this :



<VirtualHost x.x.x.x>

UseCanonicalname off

ServerName
ServerAlias mylovelydomain.com *.mylovelydomain.com

DocumentRoot /var/
</VirtualHost>



With this setup any name that you point at your IP address (e.g. abc.mylovelydomain.com) will be redirected to the virtual host, including just mylovelydomain.com . You must get those addresses to resolve via dns, however.



Regards
 
Ok, I have changed to whats shown below but still doesn't resolve to domain.com
I suspect I need to change my dns info but what do I change or add. If I try to add a line like
domain.com. IN A x.x.x.x I get out of zone data in error log.

<VirtualHost x.x.x.x>
DocumentRoot /home/domain/www/
ServerAdmin me@domain.com
ServerName ServerAlias domain.com *.mydomain.com
</VirtualHost>



$TTL 86400
@ IN SOA ns1.domain.com. hostmaster.domain.com. (
20010915; Serial
10800 ; Refresh after 3 hrs
3600 ; Retry after 1 hr
604800; Expire after 1 week
86400 ) ; Minimum ttl 1 day
IN NS ns1.domain.com.
IN A x.x.x.x
www IN A x.x.x.x
ftp IN A x.x.x.x

thanks
 
Hi,

You just need a line added like :

domain.com.     IN    A     x.x.x.x

(Note the period after the .com - that prevents the domain name being added to the end - like your ns1.domain.com. entry )

Regards

 
Hi ifincham,

If I try to add line like you suggest above I check
/var/log/messages I see the new entry with
ignoring-out-of-zone-data.

Not sure what exactly this means though. Nothing I add seems to work.

Thanks for your help though
 
Still no success.

Does anyone have this going under rh7.1 ???


//currently

<VirtualHost x.x.x.x>
UseCanonicalName off
DocumentRoot /home/domain/www/
ServerAdmin me@domain.com
ServerName ServerAlias domain.com
</VirtualHost>


//ZONE FILE
$TTL 86400
@ IN SOA ns1.domain.com. hostmaster.domain.com. (
20010915; Serial
10800 ; Refresh after 3 hrs
3600 ; Retry after 1 hr
604800; Expire after 1 week
86400 ) ; Minimum ttl 1 day
IN NS ns1.domain.com.
IN A x.x.x.x
www IN A x.x.x.x
ftp IN A x.x.x.x
mail IN A x.x.x.x
IN MX 5 mail.domain.com.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top