PDA

View Full Version : Apache --> dns


Gentoo Bob
9th October 2007, 04:38 PM
I have FC7 installed here at work. I've got it joined to the domain (can see it in AD).

I'm running Apache for our groups little webserver. I created a little site just for us.


I can get to the webpage by doing a http://ip address but I can't get to it by http://hostname

I have /etc/sysconfig/network as HOSTNAME= hostname.domain.com

I have /etc/httpd/conf/httpd.conf as ServerName hostname.domain.com

I havent edited the /etc/hosts file cause I really dont need to.

I've disabled the firewall in FC7. Also, I cannot ping it by the hostname, just IP.

What am I doing wrong?

Plankton
10th October 2007, 12:53 AM
The host name needs to get resolved either by looking in your /etc/hosts or via DNS. Is your host listed in a name server? You can check what DNS (name servers) your system is using by doing "cat /etc/resolv.conf" Try adding your host to your /etc/hosts and see what happens.

blittle
10th October 2007, 12:58 AM

put an entry in your windows DNS your hosts that reference those servers will resolve the name correctly.

run this command on your client

nslookup
> server
an IP address will be returned, you need to make an entry on that server.

(if you're talking about from a client perspective)

from the server's perspective, type the command hostname on the command line, that's what it will resolve as the name for the assigned ip address.