You are not logged in.
Pages: 1
Hello,
Since I updated my system my dhcpcd service is not working properly anymore.
The system unit blocks at boot time for a timeout of 1:30 minutes before I come to the login page.
When I'm logged in and I do
systemctl stop dhcpcd; systemctl start dhcpcd
it is also blocking for a long time.
Starting the dhcp daemon from the command line is working without blocking
dhcpcd --debug
Gives me the following output:
dhcpcd-9.0.2 starting
executing `/usr/lib/dhcpcd/dhcpcd-run-hooks' CHROOT
spawned privileged actioneer on PID 10509
spawned network proxy on PID 10510
udev: starting
dev: loaded udev
chrooting to `/var/lib/dhcpcd'
enp0: executing `/usr/lib/dhcpcd/dhcpcd-run-hooks' PREINIT
enp0: executing `/usr/lib/dhcpcd/dhcpcd-run-hooks' CARRIER
DUID 00:01:00:01:26:66:40:7c:70:4d:7b:2e:22:89
enp0: IAID 7b:2e:22:89
enp0: delaying IPv6 router solicitation for 0.1 seconds
enp0: delaying IPv4 for 0.7 seconds
enp0: soliciting an IPv6 router
enp0: sending Router Solicitation
enp0: reading lease `/var/lib/dhcpcd/enp0.lease'
enp0: rebinding lease of 192.168.0.63
enp0: ARP announcing 192.168.0.63 (1 of 2), next in 2.0 seconds
enp0: sending REQUEST (xid 0x3ed41de7), next in 4.5 seconds
enp0: acknowledged 192.168.0.63 from 192.168.0.1
enp0: leased 192.168.0.63 for 604800 seconds
enp0: renew in 302400 seconds, rebind in 529200 seconds
enp0: writing lease `/var/lib/dhcpcd/enp0.lease'
enp0: adding IP address 192.168.0.63/24 broadcast 192.168.0.255
enp0: adding route to 192.168.0.0/24
enp0: adding default route via 192.168.0.1
enp0: ARP announcing 192.168.0.63 (1 of 2), next in 2.0 seconds
enp0: executing `/usr/lib/dhcpcd/dhcpcd-run-hooks' REBOOT
forked to background, child pid 10508
As you can see the IP address will be assigned and I can access the internet.
But I don't know why my dhcpcd service is blocking now?
I already tried passing -4 to the process because my router does not know IPv6 but without success.
Whats wrong? Can you please help me?
Last edited by spiri (2020-05-31 17:42:52)
Offline
Multiple network manaing services?
find /etc/systemd -type l -exec test -f {} \; -print
Online
I disabled the dhcpcd service and I'm using systemd-networkd instead.
However I don't know how to do it with dhcpcd
$ find /etc/systemd -type l -exec test -f {} \; -print
/etc/systemd/system/getty.target.wants/setleds.service
/etc/systemd/system/getty.target.wants/getty@tty1.service
/etc/systemd/system/multi-user.target.wants/iptables.service
/etc/systemd/system/multi-user.target.wants/httpd.service
/etc/systemd/system/multi-user.target.wants/systemd-networkd.service
/etc/systemd/system/multi-user.target.wants/org.cups.cupsd.path
/etc/systemd/system/multi-user.target.wants/named.service
/etc/systemd/system/multi-user.target.wants/ip6tables.service
/etc/systemd/system/multi-user.target.wants/remote-fs.target
/etc/systemd/system/network-online.target.wants/systemd-networkd-wait-online.service
/etc/systemd/system/dbus-org.freedesktop.network1.service
/etc/systemd/system/sockets.target.wants/org.cups.cupsd.socket
/etc/systemd/system/sockets.target.wants/systemd-networkd.socket
/etc/systemd/user/default.target.wants/xdg-user-dirs-update.service
/etc/systemd/user/sockets.target.wants/gpg-agent-browser.socket
/etc/systemd/user/sockets.target.wants/pulseaudio.socket
/etc/systemd/user/sockets.target.wants/p11-kit-server.socket
/etc/systemd/user/sockets.target.wants/gpg-agent-extra.socket
/etc/systemd/user/sockets.target.wants/dirmngr.socket
/etc/systemd/user/sockets.target.wants/pipewire.socket
/etc/systemd/user/sockets.target.wants/gpg-agent.socket
/etc/systemd/user/sockets.target.wants/gpg-agent-ssh.socket
Last edited by spiri (2020-05-31 20:16:47)
Offline
Do what w/ dhcpcd?
If you're running systemd-networkd, don't try to run dhcpcd as well.
If you want to use dhcpcd, stop and disable systemd-network first.
If dhcpcd still fails, check the service status for error messages.
Online
@seth, I did this
# systemctl disable --now systemd-networkd
Removed /etc/systemd/system/multi-user.target.wants/systemd-networkd.service.
Removed /etc/systemd/system/network-online.target.wants/systemd-networkd-wait-online.service.
Removed /etc/systemd/system/dbus-org.freedesktop.network1.service.
Removed /etc/systemd/system/sockets.target.wants/systemd-networkd.socket.
Warning: Stopping systemd-networkd.service, but it can still be activated by:
systemd-networkd.socket
# systemctl enable --now dhcpcd
Created symlink /etc/systemd/system/multi-user.target.wants/dhcpcd.service → /etc/systemd/system/dhcpcd.service.
Job for dhcpcd.service failed because a timeout was exceeded.
See "systemctl status dhcpcd.service" and "journalctl -xe" for details.
# journalctl -xe
Jun 03 12:35:06 at-home dhcpcd[6961]: enp0: leased 192.168.0.63 for 604800 seconds
Jun 03 12:35:06 at-home dhcpcd[6961]: enp0: renew in 302400 seconds, rebind in 529200 seconds
Jun 03 12:35:06 at-home dhcpcd[6961]: enp0: writing lease `/var/lib/dhcpcd/enp0.lease'
Jun 03 12:35:06 at-home dhcpcd[6961]: enp0: adding IP address 192.168.0.63/24 broadcast 192.168.0.255
Jun 03 12:35:06 at-home dhcpcd[6961]: enp0: adding route to 192.168.0.0/24
Jun 03 12:35:06 at-home dhcpcd[6961]: enp0: adding default route via 192.168.0.1
Jun 03 12:35:06 at-home dhcpcd[6961]: enp0: ARP announcing 192.168.0.63 (1 of 2), next in 2.0 seconds
Jun 03 12:35:06 at-home dhcpcd[6961]: enp0: executing `/usr/lib/dhcpcd/dhcpcd-run-hooks' REBOOT
Jun 03 12:35:08 at-home dhcpcd[6961]: enp0: ARP announcing 192.168.0.63 (2 of 2)
Jun 03 12:35:09 at-home dhcpcd[6961]: enp0: sending Router Solicitation
Jun 03 12:35:12 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:13 at-home dhcpcd[6961]: enp0: sending Router Solicitation
Jun 03 12:35:17 at-home dhcpcd[6961]: enp0: sending Router Solicitation
Jun 03 12:35:17 at-home dhcpcd[6961]: enp0: no IPv6 Routers available
Jun 03 12:35:45 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:45 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:45 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:46 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:46 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:47 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:48 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:48 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:49 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:49 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:50 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:50 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:50 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:51 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:51 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:52 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:53 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:55 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:fb:f0:24:75:69:e9:70:08:00 SRC=192.168.0.57 DST=224.0.0.251 LEN=>
Jun 03 12:35:58 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:01:70:5a:9e:3d:af:43:08:00 SRC=192.168.0.1 DST=224.0.0.1 LEN=32 >
Jun 03 12:35:58 at-home kernel: [MULTICAST]: IN=enp0 OUT= MAC=01:00:5e:00:00:01:70:5a:9e:3d:af:43:08:00 SRC=192.168.0.1 DST=224.0.0.1 LEN=36
# systemctl status dhcpcd
● dhcpcd.service - dhcpcd on all interfaces
Loaded: loaded (/etc/systemd/system/dhcpcd.service; enabled; vendor preset: disabled)
Active: activating (start) since Wed 2020-06-03 12:41:55 CEST; 6s ago
Process: 7900 ExecStart=/usr/bin/dhcpcd -q -b -d (code=exited, status=0/SUCCESS)
Tasks: 4 (limit: 19026)
Memory: 3.5M
CGroup: /system.slice/dhcpcd.service
├─7910 dhcpcd: [master] [ip4] [ip6]
├─7911 dhcpcd: [privileged actioneer]
├─7912 dhcpcd: [network proxy]
└─7919 dhcpcd: [BPF ARP] enp0
Jun 03 12:41:56 at-home dhcpcd[7910]: enp0: leased 192.168.0.63 for 604800 seconds
Jun 03 12:41:56 at-home dhcpcd[7910]: enp0: renew in 302400 seconds, rebind in 529200 seconds
Jun 03 12:41:56 at-home dhcpcd[7910]: enp0: writing lease `/var/lib/dhcpcd/enp0.lease'
Jun 03 12:41:56 at-home dhcpcd[7910]: enp0: adding IP address 192.168.0.63/24 broadcast 192.168.0.255
Jun 03 12:41:56 at-home dhcpcd[7910]: enp0: adding route to 192.168.0.0/24
Jun 03 12:41:56 at-home dhcpcd[7910]: enp0: adding default route via 192.168.0.1
Jun 03 12:41:56 at-home dhcpcd[7910]: enp0: ARP announcing 192.168.0.63 (1 of 2), next in 2.0 seconds
Jun 03 12:41:56 at-home dhcpcd[7910]: enp0: executing `/usr/lib/dhcpcd/dhcpcd-run-hooks' REBOOT
Jun 03 12:41:58 at-home dhcpcd[7910]: enp0: ARP announcing 192.168.0.63 (2 of 2)
Jun 03 12:42:00 at-home dhcpcd[7910]: enp0: sending Router Solicitation
and this blocks on the command line, when I try to start the dhcpcd service.
There is no error code from dhcpcd. It's still running but a timeout gets reached.
Offline
The service status doesn't indicate any timeout, nor does the "-xe" call, but the outputs show at least 2 dhcpcd processes. Did you try to start it twice?
Also there're still systemd-networkd-wait-online.service and systemd-networkd.socket - disable them, ensure dhcpcd is still enabled (run the find command again) and reboot.
If you still get a delay, check the dhcpcd service status immediately (don't try to restart the service or run a second instance or any of that)
Online
The service status doesn't indicate any timeout, nor does the "-xe" call, but the outputs show at least 2 dhcpcd processes. Did you try to start it twice?
I don't think so, no. I just did
systemctl enable --now dhcpcd
then it's blocking for 1 mins 30 secs.
I concatenated the two outputs, i just get the blocking error.
Also there're still systemd-networkd-wait-online.service and systemd-networkd.socket - disable them, ensure dhcpcd is still enabled (run the find command again) and reboot.
If you still get a delay, check the dhcpcd service status immediately (don't try to restart the service or run a second instance or any of that)
Blocking:
# systemctl disable --now systemd-networkd
Removed /etc/systemd/system/multi-user.target.wants/systemd-networkd.service.
Removed /etc/systemd/system/network-online.target.wants/systemd-networkd-wait-online.service.
Removed /etc/systemd/system/dbus-org.freedesktop.network1.service.
Removed /etc/systemd/system/sockets.target.wants/systemd-networkd.socket.
# systemctl stop systemd-networkd-wait-online
# systemctl stop systemd-networkd.socket
# systemctl is-enabled dhcpcd
disabled
[root@~][root@bash+spiri(x3)@bash]# systemctl enable --now dhcpcd
Created symlink /etc/systemd/system/multi-user.target.wants/dhcpcd.service → /etc/systemd/system/dhcpcd.service.
EDIT: I never had a problem with this for years dhcpcd just started. This happens after I did pacman -Syu
Maybe a new installation of Arch will solve the problem? I want to avoid this.
EDIT2: dhcpcd is working i get an ip address but its blocking on the command line when I start the service.
The process never returns as a unit file but it does invoking dhcpcd on the command line.
This is my unit file:
[Unit]
Description=dhcpcd on all interfaces
Wants=network.target
Before=network.target
[Service]
Type=forking
PIDFile=/run/dhcpcd.pid
ExecStart=/usr/bin/dhcpcd -q -b
ExecStop=/usr/bin/dhcpcd -x
Restart=always
RestartSec=1
[Install]
WantedBy=multi-user.target
Last edited by spiri (2020-06-03 14:32:31)
Offline
*push*
Offline
*push*
Offline
I did a fresh install of Arch Linux, now dhcpcd is working for me.
Offline
Pages: 1