You are not logged in.
I'm working on a home network consisting of four machines; 2 XP Desktops, 1 AL Server and 1 AL Desktop. I'm finally trying to implement static IPs on both AL machines. Since my Linksys BEFSR41 doesn't appear to allow static DHCP leases I have tried to assign static IPs using DHCP and editing rc.conf as defined by the Arch Linux Wiki: Configuring Network. Despite trying various methods I can't ping outside my LAN. I can ping my gateway, the aforementioned router, and other machines on the network. /etc/rc.d/network restart runs without incident.
Current Setup Using DHCP IP on AL Server
/etc/conf.d/dhcpcd
DHCPCD_ARGS="-q -s 192.168.1.200"Also of note is the fact that the DHCP address range is 192.168.1.100 to 192.168.1.149. The IP address I'm currently using (I have tried a number of different values) is outside this range.
/etc/rc.conf
eth0="dhcp"
INTERFACES=(eth0)
gateway="default gw 192.168.1.1"
ROUTES=(!gateway)Although I have tried setting up a static IP w/out DHCP, I'm still unclear about the role of the DNS servers in /etc/resolv.conf.
I really appreciate any help you can provide. The solution may be obvious, but I can't seem to find it.
Last edited by filam (2010-07-26 20:32:03)
Offline
gateway="default gw 192.168.1.1"
<wild guess>
Try your router's IP instead.
Offline
looks like you cannot access anything outside your LAN so it is a gateway problem ![]()
delete the ! sign before gateway in the last line otherwise the gateway you specified is ignored
dns servers resolve hostnames and/or FQDN names, see the wiki ( or wikipedia )
Last edited by scar (2010-07-26 20:01:31)
“The future has already arrived. It's just not evenly distributed yet.”
― William Gibson
Offline
karol, that is my router's IP and the gateway defined by route -n.
scar, the Wiki entry has it disabled. Removing the ! causes /etc/rc.d/network restart to FAIL with the following error: SIOCDELRT: No such process.
Thank you very much for the input.
EDIT: In addition to the above error I noticed that after enabling the Gateway in rc.conf I can now ping external IP addresses (ex. 8.8.8.8), but not domain names (ex. google.com). Perhaps a DNS issue? My reslov.conf is currently empty, perhaps that is an issue?
Last edited by filam (2010-07-26 20:14:59)
Offline
From the man page:
Here is an example which configures a static address, routes and dns.
dhcpcd -S ip_address=192.168.0.10/24 \
-S routers=192.168.0.1 \
-S domain_name_servers=192.168.0.1 \
eth0
You're using '-s' (small letter) or it's a typo?
Offline
From the man page:
Here is an example which configures a static address, routes and dns.
dhcpcd -S ip_address=192.168.0.10/24 \
-S routers=192.168.0.1 \
-S domain_name_servers=192.168.0.1 \
eth0You're using '-s' (small letter) or it's a typo?
Interesting, because the Wiki entry has a lower case s. Let me check...
EDIT: Also I might note that the machine isn't having a problem assigning the IP, so I would assume this is not an issue, but let me check.
EDIT: After enabling the gateway in rc.conf and changing the flag to -S I now get the following error when running /etc/rc.d/network restart:
dhcpcd[1732]: static assignment requiredI can ping 8.8.8.8, but not google.com as I mentioned before.
Last edited by filam (2010-07-26 20:21:48)
Offline
Have you tried using the static IP as described by the wiki:
eth0="eth0 192.168.100.2 netmask 255.255.255.0 broadcast 192.168.100.255"
INTERFACES=(eth0)
gateway="default gw 192.168.100.1"
ROUTES=(gateway)?
Offline
[Solved]
I had tried that method earlier. I believe what happened was that while trying multiple methods I mixed up the configuration. No surprise there. The last part was the addition of DNS servers to resolv.conf, which I copied from another machine.
Thank you very much karol and also scar. I really appreciate the help. Hopefully I'll be able to sort out my desktop now!
Offline
Glad you got it working.
Just one more thing: does it make any difference whether it's '-S' or '-s'?
Offline
I got it working using the second method in the Wiki, without DHCP. Trying to use DHCP with the -S flag returns an error when restarting the network, which -s does not. After using the -s or the -S flag I can't ping anything outside the network. This is with the gateway disabled in rc.conf as the Wiki shows. When I enable it by removing the !, I can ping 8.8.8.8 but not google. Not a definitive conclusion as I'm probably doing something else wrong. ![]()
EDIT: So, I do believe the lower case flag is correct, I'm still surprised that adding nameservers to resolv.conf fixes the problem, but restarting the network will cause that information to be deleted, hence I can't access domains.
Last edited by filam (2010-07-26 20:49:31)
Offline
if you can ping ip addresses but not FQDN names, the problem lies in the name resolution - check out your DNS servers in:
/etc/resolv.conf
( put something in, like
nameserver 194.2.0.20
- this is a free one )
“The future has already arrived. It's just not evenly distributed yet.”
― William Gibson
Offline
if you can ping ip addresses but not FQDN names, the problem lies in the name resolution - check out your DNS servers in:
/etc/resolv.conf
( put something in, like
nameserver 194.2.0.20
- this is a free one )
I already made that change and flagged this thread solved. Thanks for the input anyway, I really appreciate it.
Offline
> restarting the network will cause that information to be deleted
# Generated by dhcpcd from eth0
# /etc/resolv.conf.head can replace this line
nameserver 192.168.1.1
# /etc/resolv.conf.tail can replace this lineIf I'm reading that right, you create a file named ' /etc/resolv.conf.head' and put the nameservers you want there.
Offline
You can also add "nohook resolv.conf" to /etc/dhcpcd.conf to stop it overwriting /etc/resolv.conf.
Offline