Arch Linux

Please read this before reporting a bug:

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!

FS#30235 - [dhcpcd][systemd] dhcpcd.service fails randomly

Attached to Project: Arch Linux
Opened by solsTiCe (zebul666) - Sunday, 10 June 2012, 12:30 GMT
Last edited by Dave Reisner (falconindy) - Saturday, 10 November 2012, 21:14 GMT
Task Type Bug Report
Category Upstream Bugs
Status Closed
Assigned To Ronald van Haren (pressh)
Dave Reisner (falconindy)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 11
Private No


I was running an archlinux guest in virtualbox
and dhcpcd.service failed half of the time because dhcpcd.service was called sometimes before (sometimes after) the module was finished being loaded and the interface was not up. so dhcpcd failed randomly

I have found that adding
in the [Unit] section fixes the problem

I am a newbie systemd user
This task depends upon

Closed by  Dave Reisner (falconindy)
Saturday, 10 November 2012, 21:14 GMT
Reason for closing:  Fixed
Additional comments about closing:  testing/dhcpcd-5.6.2-2
Comment by Dave Reisner (falconindy) - Monday, 11 June 2012, 09:58 GMT
Does the attached unit work reliably?
Comment by solsTiCe (zebul666) - Monday, 11 June 2012, 10:48 GMT

Note: We're talking about a very specific setup so may be it's not worth the effort ?
Comment by Dave Reisner (falconindy) - Thursday, 14 June 2012, 02:18 GMT
What is this "very specific setup"?
Comment by solsTiCe (zebul666) - Thursday, 14 June 2012, 07:57 GMT
a vbox guest. but it is not that "very" specific after all.
It may be that it triggers that bug of initialisation order more easily that with real hardware ??
Comment by Dave Reisner (falconindy) - Thursday, 14 June 2012, 09:51 GMT
Have you loaded the modules explicitly in /etc/modules-load.d to confirm that this really is an issue of ordering?
Comment by solsTiCe (zebul666) - Thursday, 14 June 2012, 10:21 GMT
I discovered it was an ordering issue by looking at systemd log with journalctl.

And yes adding the driver module in a .conf file in /etc/modules-load.d/ fixes the problem
Comment by Maksim Yakovlev (lampslave) - Saturday, 11 August 2012, 23:34 GMT
I have the same issue.
dhcpcd reported (in log) "eth0 interface not found or invalid", but all OK, when dhcpcd for eth0 started manually.

What driver did you mean? VB provide Ethernet connection, custom drivers or modules are not needed.
Comment by solsTiCe (zebul666) - Monday, 13 August 2012, 08:46 GMT
vbox emulates an Intel PRO/1000 MT so adding the e1000 driver to /etc/modules.load/ helped. (the guest /etc/modules.load/)
Comment by Dave Reisner (falconindy) - Monday, 13 August 2012, 13:42 GMT
Switching projects, since this is now ownered by dhcpcd. Root cause is known by systemd upstream, but there's no ETA on when it'll be fixed.
Comment by Maksim Yakovlev (lampslave) - Friday, 17 August 2012, 21:45 GMT
Wow, adding e1000 is really working! Thanks a lot :)
Comment by Gerardo Exequiel Pozzi (djgera) - Saturday, 18 August 2012, 01:59 GMT
same here on qemu-kvm (virtio-pci) ;)
Comment by Dave Reisner (falconindy) - Saturday, 08 September 2012, 20:40 GMT Comment by CheolHan Yoon (mattengi) - Thursday, 20 September 2012, 13:55 GMT
I have same problem. Reboot couple of times, dhcpd@eth0 always failed.
Add 'e1000' to /etc/modules-load.d/e1000.conf, then problem solved.

virtualbox 4.2. arch 64 installed.
Comment by Mark Grimes (mgrimes) - Monday, 15 October 2012, 16:19 GMT
I had the same issue on real hardware. Adding the forcedeth driver to modules.d seems to have fixed it. (This has made the transition to systemd very troublesome.)
Comment by Dave Reisner (falconindy) - Monday, 15 October 2012, 16:32 GMT
Please relegate your +1s to the vote button. There's a patch proposed upstream to fix this -- see the upstream bug report.
Comment by Dave Reisner (falconindy) - Saturday, 20 October 2012, 16:36 GMT
I merged the proposed patch, so this can be fixed after the 195 release.
Comment by Christopher Reimer (CReimer) - Wednesday, 07 November 2012, 22:45 GMT
Even with systemd 195 it doesn't work properly.
Comment by Dave Reisner (falconindy) - Wednesday, 07 November 2012, 22:50 GMT
No one ever said it would. systemd-195 contains the necessary fix to allow the dhcpcd service to be ordered properly.

There's a reason this isn't closed yet.
Comment by Christopher Reimer (CReimer) - Wednesday, 07 November 2012, 22:58 GMT
Ohh, sorry. I think I misunderstood your last comment.


I don't want to annoy anyone, but it works for me with two additional lines: