You are not logged in.

#1 2011-06-07 09:16:52

archnemesis
Member
Registered: 2009-11-27
Posts: 53

internet not working - hostnames not being resolved

I just finished reinstalling archlinux, and although the internet was working during installation, after rebooting it isnt. I am using a static configuration, no dhcp, the same as i used during installation. the route command shows my router's address as the default gateway, my host ip is set on interface eth0, and the DNS adresses are in the /etc/resolve.conf. Ping works with my routers address and my ISP's DNS address, but not with a hostname like google.com. It seems that the hostnames aren't being resolved. Have I forgotten to do something?

Offline

#2 2011-06-07 10:30:34

Kilzool
Member
From: Ireland
Registered: 2010-08-04
Posts: 232

Re: internet not working - hostnames not being resolved

in /etc/rc.conf make sure you have 'network' in the daemons.

in /etc/rc.conf  I have:

#Static IP example
eth0="eth0 192.168.1.101 netmask 255.255.255.0 broadcast 192.168.1.255"
#eth0="dhcp"
INTERFACES=(eth0)

gateway="default gw 192.168.1.1"
ROUTES=(gateway)

in /etc/resolv.conf I added:
nameserver 192.168.1.1




If you make any changes, you need to:  # sudo /etc/rc.d/network stop      # sudo /etc/rc.d/network start


Hope this helps.

Offline

#3 2011-06-07 14:04:05

archnemesis
Member
Registered: 2009-11-27
Posts: 53

Re: internet not working - hostnames not being resolved

Thanks. I think the problem was that I didn't have "nameserver" in front of the ip address in the resolve.conf file.

Offline

#4 2011-06-09 00:45:57

Kilzool
Member
From: Ireland
Registered: 2010-08-04
Posts: 232

Re: internet not working - hostnames not being resolved

archnemesis wrote:

Thanks. I think the problem was that I didn't have "nameserver" in front of the ip address in the resolve.conf file.

Yes, that would do it.. as it is needs that.  DHCPD provides that, but if you use STATIC, as you did, you manually add it.

Glad you got it working.

Now, I bet after this last patch you might have an issue, we'll see.
The one where it makes alot of changes to rc.conf  smile

Offline

Board footer

Powered by FluxBB