You are not logged in.

#1 2012-10-11 22:08:52

From: UK
Registered: 2012-10-11
Posts: 32

systemd: when using ifplugd is dhcpcd still required as daemon?

I have been trying to optimise my systemd boot process and several items towards the top of my 'systemd-analyze blame' list are dhcpcd and ifplugd@eth0.service.

I figure that I should have ifplugd running as a daemon, then when it detects a plug-in event it should trigger/load the dhcpcd daemon.
Is this right? -- should I remove dhcpcd from my boot up daemons?

How would I go about setting this up?

My full 'blame' list is as follows:

11933ms dhcpcd@eth0.service
  4833ms laptop-mode-tools.service
  3773ms shorewall.service
  3736ms shorewall6.service
  3242ms console-kit-daemon.service
  1714ms avahi-daemon.service
  1596ms systemd-logind.service
  1266ms console-kit-log-system-start.service
  1162ms ifplugd@eth0.service
   363ms systemd-udev-trigger.service
   358ms systemd-remount-fs.service
   336ms systemd-tmpfiles-setup.service
   329ms systemd-udevd.service
   313ms systemd-vconsole-setup.service
   299ms dev-hugepages.mount
   278ms dev-mqueue.mount
   273ms sys-kernel-debug.mount
   267ms udisks2.service
   228ms openntpd.service
   162ms rc-local.service
   143ms systemd-user-sessions.service
   129ms systemd-sysctl.service
   125ms boot.mount
   104ms upower.service
    49ms home.mount
    17ms var.mount
     6ms usr-local.mount
     4ms proc-sys-fs-binfmt_misc.mount
     2ms tmp.mount

Any tips for improving upon this current config will be greatly appreciated.

What would Gordon Freeman do?


#2 2012-10-12 18:45:03

Registered: 2011-12-24
Posts: 187

Re: systemd: when using ifplugd is dhcpcd still required as daemon?

Try getting rid of the service and see if you still get wired connection?


#3 2012-11-26 18:08:13

From: UK
Registered: 2012-10-11
Posts: 32

Re: systemd: when using ifplugd is dhcpcd still required as daemon?

@Hspasta -- umm....if I disable the dhcpcd service then then I wont get any connection wired or otherwise (given that I have not manually configured a static-ip for my network adaptor)
-- If I understand correctly I still need dhcpcd in order to get an IP lease from the DHCP server running on my router, yes?

Basically what's happening at the moment is if my network cable is unplugged when I boot up my system (which it is when I'm not using the internet) then dhcpcd is still loaded via Systemd (which it should because I have it 'enabled' as a service). However this is slowing things down because the system has to wait for this service to time out and basically give-up looking for a DHCP server / line lease before continuing.

Unfortunately this also means that if I then want to use the internet and I plug my network cable in (after the system has already booted up) I still don't get a connection until/unless I do...

$ sudo systemctl reload-or-restart dhcpcd@eth0.service

...or reboot the computer! Neither of which very desirable!

So if anyone does know how I can get IfPlugd to 'trigger' some kind of connection script (be it via a static-ip, IfUp/Down config or dhcpcd) that would be much appreciated!

-- If anything I've done or said is glaringly stupid please don't bash the n00b -- Much help == Many thanks!

What would Gordon Freeman do?


Board footer

Powered by FluxBB