You are not logged in.
Here is my /etc/rc.conf:
#
# /etc/rc.conf - Main Configuration for Arch Linux
#
# -----------------------------------------------------------------------
# LOCALIZATION
# -----------------------------------------------------------------------
#
# LOCALE: available languages can be listed with the 'locale -a' command
# HARDWARECLOCK: set to "UTC" or "localtime"
# USEDIRECTISA: use direct I/O requests instead of /dev/rtc for hwclock
# TIMEZONE: timezones are found in /usr/share/zoneinfo
# KEYMAP: keymaps are found in /usr/share/kbd/keymaps
# CONSOLEFONT: found in /usr/share/kbd/consolefonts (only needed for non-US)
# CONSOLEMAP: found in /usr/share/kbd/consoletrans
# USECOLOR: use ANSI color sequences in startup messages
#
LOCALE="en_US.utf8"
HARDWARECLOCK="UTC"
USEDIRECTISA="no"
TIMEZONE="US/Eastern"
KEYMAP="us"
CONSOLEFONT=
CONSOLEMAP=
USECOLOR="yes"
# -----------------------------------------------------------------------
# HARDWARE
# -----------------------------------------------------------------------
#
# MOD_AUTOLOAD: Allow autoloading of modules at boot and when needed
# MOD_BLACKLIST: Prevent udev from loading these modules
# MODULES: Modules to load at boot-up. Prefix with a ! to blacklist.
#
# NOTE: Use of 'MOD_BLACKLIST' is deprecated. Please use ! in the MODULES array.
#
MOD_AUTOLOAD="yes"
#MOD_BLACKLIST=() #deprecated
MODULES=(forcedeth b43 !bcm43xx snd-mixer-oss snd-pcm-oss snd-hwdep snd-page-alloc snd-pcm snd-timer snd snd-hda-intel soundcore !snd_pcsp !pcspkr)
# Scan for LVM volume groups at startup, required if you use LVM
USELVM="no"
# -----------------------------------------------------------------------
# NETWORKING
# -----------------------------------------------------------------------
#
# HOSTNAME: Hostname of machine. Should also be put in /etc/hosts
#
HOSTNAME="laptop"
# Use 'ifconfig -a' or 'ls /sys/class/net/' to see all available interfaces.
#
# Interfaces to start at boot-up (in this order)
# Declare each interface then list in INTERFACES
# - prefix an entry in INTERFACES with a ! to disable it
# - no hyphens in your interface names - Bash doesn't like it
#
# DHCP: Set your interface to "dhcp" (eth0="dhcp")
# Wireless: See network profiles below
#
eth0="dhcp"
INTERFACES=(eth0)
# Routes to start at boot-up (in this order)
# Declare each route then list in ROUTES
# - prefix an entry in ROUTES with a ! to disable it
#
gateway="default gw 192.168.0.1"
ROUTES=(!gateway)
# Enable these network profiles at boot-up. These are only useful
# if you happen to need multiple network configurations (ie, laptop users)
# - set to 'menu' to present a menu during boot-up (dialog package required)
# - prefix an entry with a ! to disable it
#
# Network profiles are found in /etc/network.d
#
# This now requires the netcfg package
#
#NETWORKS=(main)
# -----------------------------------------------------------------------
# DAEMONS
# -----------------------------------------------------------------------
#
# Daemons to start at boot-up (in this order)
# - prefix a daemon with a ! to disable it
# - prefix a daemon with a @ to start it up in the background
#
DAEMONS=(syslog-ng network @openntpd netfs hal crond gdm fam alsa)I was able to manually place the dhcpcd commands in /etc/rc.local. Why is this necessary, though?
Offline
yes, that fails.
Offline
Are you getting ab IP, but just not connecting to the internet? If so, comment out the following 2 lines in rc.conf:
gateway="default gw 192.168.0.1"
ROUTES=(!gateway)
-mS
Offline
My guess is that you have to remove the ! from the front of gateway in ROUTES=(!gateway)
That's what I used to have to do on my old desktop.
Also, be sure that 192.168.0.1 is actually your gateway. If you don't know you run dhcpcd then run route.
Last edited by Statix (2009-02-10 01:32:34)
Madly in love with Arch64, Openbox, DotA, and of course... penguins!
Happy to help if you're not a Help Vampire. Use your wonderful resources like ArchWiki, Google, and our wonderful search page.
Offline
Well, I'm at school now, so I get a random IP, is the only way to do this then, to add the dhcpcd to the /etc/rc.local
Offline
Yes I ran into this same issue. The only way that I was able to solve it was the bypass it using wicd. Since it is not a command line tool, it might not be a choice for some. How would you go about getting dhcpcd to work with the rc.local?
Last edited by MarcoRosso (2009-02-10 03:18:58)
Offline
You shouldn't have to add dhcpcd to /etc/rc.local for whatever reason it appears that the dhcpcd command is failing when being called from the rc.d script. I would highly suggest you figure out why this is happening.
Also you should not have to comment out anything as aglarod suggests. The ! in ROUTES=(!gateway) implies false/not. Which means that gateway would not be set. This is good, because when you run dhcp the gateway is suppose to be found automatically which appears to be happening.
You need to figure out why the network script is failing.
Some steps to get a better idea of what is going on:
killall dhcpcd
ifconfig eth0 down
/etc/rc.d/network start
look for any output given by any of the commands, test networking
Offline
The reason why it is happening is because it is timing out. Thats it for me. Since it says timeout after the status fail message. Unless i am wrong?
Offline
I had commented those lines out because the first time I loaded Arch my default gateway wasn't being set, even though I was using dhcp. I commented both of those lines and everything started working. It's possible I messed with something else, though.
-mS
Offline
The reason why it is happening is because it is timing out. Thats it for me. Since it says timeout after the status fail message. Unless i am wrong?
This is unlikely because the OP stated that adding dhcpcd eth0 in /etc/rc.local works. If it was timing out that solution would not work. Unless if the OP modified /etc/conf.d/dhcpcd and set a very low timeout limit, I doubt that is the problem here.
I had commented those lines out because the first time I loaded Arch my default gateway wasn't being set, even though I was using dhcp. I commented both of those lines and everything started working. It's possible I messed with something else, though.
-mS
I find that hard to believe. When you comment those lines out no gateway would be being set. You probably did not have ! before routes=(GATEWAY), which would then set an incorrect gateway, if you don't use 192.168.0.1.
@OP
/etc/rc.d/network should be calling dhcpcd to activate the networking on eth0. You haven't modified /etc/conf.d/wireless by some odd chance have you?
Offline
here is my /etc/conf.d/wireless
GNU nano 2.0.9 File: /etc/conf.d/wireless
#
# Settings for wireless cards
#
# For each wireless interface declared in INTERFACES (in rc.conf), declare
# a wlan_${IF} variable that contains the arguments to be passed to
# iwconfig(8). Then list the original interface name in the
# WLAN_INTERFACES array.
#
#wlan_eth0="eth0 mode managed essid default"
#WLAN_INTERFACES=(eth0)Offline
Alright, that rules out that you didn't modify /etc/conf.d/wireless
However can you run the following:
killall dhcpcd
ifconfig eth0 down
/etc/rc.d/network start
and post the output of those commands?
Offline
hm, all of a sudden it works. there's been major internet issues here at school..maybe it was just the ports not working correctly. everything seems fine now. thanks!
Offline
I have very similar issue.
When I run /etc/rc.d/network start, or restart, it fails because dhcpcd times out.
However, if I run: dhcpcd -q eth0 it receives an address (and pretty fast).
And this is exactly the same command rc.d/network script runs.
Somehow dhcpcd -q eth0 run by me works, while the same command run by rc.d/network script - fails.
Any ideas?
Offline