You are not logged in.
Pages: 1
dhcpcd fails to start on an old laptop I have. Looking at `journalctl -xe`:
May 27 16:47:09 archiso dhcpcd[586]: timed out
May 27 16:47:09 archiso dhcpcd[586]: timed out
May 27 16:47:09 archiso systemd[1]: dhcpcd@enp1s0.service: Control process exited, code=exited, status=1/FAILURE
-- Subject: Unit process exited
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- An ExecStart= process belonding to unit dhcpcd@enp1s0.service has exited.
--
-- The process' exit code is 'exited' and its exit status is 1.
May 27 16:47:09 archiso dhcpcd[586]: dhcpcd exited
May 27 16:47:09 archiso systemd[1]: dhcpcd@enp1s0.service: Failed with result 'exit-code'.
-- Subject: Unit failed
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- The unit dhcpcd@enp1s0.service has entered the 'failed' state with result 'exit-code'.
May 27 16:47:09 archiso systemd[1]: Failed to start dhcpcd on enp1s0.
-- Subject: A start job for unit dhcpcd@enp1s0.service has failed
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Offline
Are you able to configure a static ip for this machine? I had to do that with the specific combination of wifi card and the old router I had once.
There may be some benefit of debugging this, but the number of variables involved led me to believe that provided it wasn't happening to too many other people, I should work around it.
Architecture: pentium4, Testing repos: Yes, Hardware: EeePC 901+2GB RAM+OS half on the SD card.
Offline
Sorry, I haven't the faintest clue on doing that, have you got any sources or tutorials?
I've noticed that sometimes, if I plug out the ethernet cable and then plug it in again, and then restarted dhcpcd it would work for ~5 minutes before shutting off again.
Offline
Look in /etc/netctl/examples/wireless-wpa-static. Technically then you should log on to your router and stop it allocating the same IP over DHCP to something else on your network, but in practice if you use another part of your private subnet or give it a high enough 8-bit final number you can get away with it.
Architecture: pentium4, Testing repos: Yes, Hardware: EeePC 901+2GB RAM+OS half on the SD card.
Offline
But I'm working via ethernet, not wireless?
Offline
Then look at /etc/netctl/exampes/ethernet-static then. I assume you're using netctl for your networking needs, although it's possible I'm mistaken.
Edit: I'm not sure why that example gives two addresses. Maybe it's designed for when you've got on-board ethernet and a PCI ethernet card, although I'd kind of expect them to be presented as different interfaces. I'd try using it with just one address.
Last edited by levi (2019-05-28 22:04:39)
Architecture: pentium4, Testing repos: Yes, Hardware: EeePC 901+2GB RAM+OS half on the SD card.
Offline
Hi,
the example is just to show off: you can assign two addresses to the same nic - this is, what the example does. but yeah: just use one address there.
what I would do, is test the respective functionality without netctl:
try a static ip:
> ip addr add dev enp1s0 192.168.0.10/24
try to ping someone else in your network, if that works, try a dynamic ip manually assigned with dhcpcd:
(remove the old static ip)
> ip addr del dev enp1s0 192.168.0.10/24
(start dhcpcd)
> dhcpcd -L -B enp1s0
If that succeeds, then you should change something about your netctl config. If not, something about dhcp in your network is most likely broken.
Btw: do you (try to) assign ipv4 and ipv6 addresses via dhcp?
regards,
deep42thought
Offline
I've set up a simple profile:
Description='A basic static ethernet connection'
Interface=enp1s0
Connection=ethernet
IP=static
Address=('192.168.1.98/24')
Gateway='192.168.1.1'
DNS=('192.168.1.1')
But no matter what I've tried, it fails to start and says that the interface is already up, even when I disabled it (dhcpcd@enp1s0.service or netctl@enps0.service) with systemctl.
Offline
I guess,
ip link
shows that the link is "UP" (in contrast to "DOWN") - in that case, set it down first by
ip link set dev enp1s0 down
Offline
I would try to use 'DHCPClient=dhclient' in '/etc/netctl/dhcp' (or how your netctl profile is called).
Just to see if it makes a difference.
Offline
Now `journalctl -xe` gives "No connection found on interface 'enp1s0' (timeout)", so I guess it's back to square one?
I would try to use 'DHCPClient=dhclient' in '/etc/netctl/dhcp' (or how your netctl profile is called).
Just to see if it makes a difference.
Tried it, did not make a difference for netctl.
Last edited by mid (2019-05-29 13:37:16)
Offline
Yeah. Try to shutdown the link 'ip link set dev enp1s0 down', pkill any still running 'dhclient' or 'dhcpcd' process.
Then try to do a ''dhcpcd' as root by hand:
dhcpcd -4 -d enp1s0
What's the output of that?
What if the output of 'ifconfig -a'
Timeout on enp1s0 means, your router doesn't give you an IP.
Did you try other devices with the same router? Do they show
the same problems?
Do you have access to a logfile of the router? Maybe the DHCP
sever tells us more, what's going wrong..
Offline
dhcpcd-7.2.1 starting
enp1s0: executing '/usr/lib/dhcpcd/dhcpcd-run-hooks' PREINIT
enp1s0: executing '/usr/lib/dhcpcd/dhcpcd-run-hooks' NOCARRIER
enp1s0: waiting for carrier
enp1s0: carrier acquired
enp1s0: executing '/usr/lib/dhcpcd/dhcpcd-run-hooks' CARRIER
DUID AS:DF:AS:DF:AS:DF:AS:DF:AS:DF:AS:DF:AS:DF:AS:DF:AS:DF
enp1s0: IAID AS:DF:AS:DF
enp1s0: delaying IPv4 for 0.2 seconds
enp1s0: carrier lost
enp1s0: executing '/usr/lib/dhcpcd/dhcpcd-run-hooks' NOCARRIER
timed out
dhcpcd exited
Though, first time I tried this command after restarting the computer there were more "carrier lost"s (I rebooted each time before running dhcpcd again).
Other devices work fine, do you maybe mean with Arch specifically?
Offline
Reading the dhcpcd manpage tells me you can give is a -t option to specify the timeout (default is 30s). You can try setting it longer, or set it to 0 and it'll just hang waiting for an IP rather than timing out ever (but that would halt your boot if it ever tried to run dhcpcd on a duff network, so probably is only useful for testing).
I don't know how you'd configure this in a netctl.service file, but it could well help find out the root cause of the trouble. Might also explain why it sometimes falls over after 5 minutes, if it's giving it a lease only that long and renegotiating fails due to timeout.
Architecture: pentium4, Testing repos: Yes, Hardware: EeePC 901+2GB RAM+OS half on the SD card.
Offline
So.. uh... it turned out to be a faulty wire.
Sorry for wasting your time and thank you for wasting your time!
Offline
Pages: 1