dhcpcd
dhcpcd copied to clipboard
Waiting for carrier blocks timeout
Problem:
--timeout isn't respected when no carrier has been acquired
I see:
# dhcpcd --nobackground --ipv4only --oneshot --waitip=4 --persistent --timeout=5 --debug wlo1
dhcpcd-10.0.5 starting
DUID 00:01:00:01:2d:1e:ed:87:b6:18:32:62:ff:1a
wlo1: executing: /lib/dhcpcd/dhcpcd-run-hooks PREINIT
wlo1: executing: /lib/dhcpcd/dhcpcd-run-hooks NOCARRIER
Dropped protocol specifier '.link' from 'wlo1.link'. Using 'wlo1' (ifindex=3).
wlo1: waiting for carrier
I would expect the timeout ideally to be respected, or at the very least document this behavior.
I'm thinking about removing the timeout option as it becomes meaningless when #271 happens.
@holmanb once #271 happens the --oneshot option would be removed as well, but you used it in your example. Do you have a rationale for it?
@rsmarples Thanks for the reply and followup.
Using --oneshot for synchronous dhcp address assignment to a single interface by other tools. For example initramfs-tools recently replaced their isc dependency with dhcpcd using --oneshot. Do you have a proposal for how one might do this that works under current and future dhcpcd plans?
Ok, that's a good enough reason to keep it. I'll add that the fine man page.
Ok, that's a good enough reason to keep it. I'll add that the fine man page.
Thanks @rsmarples. I have more questions regarding #271, but will continue the conversation here.