Understanding handling of 'NOCARRIER' (dhcpcd 6.11.5)
Shahid Mahmood
Tue Jun 27 18:35:53 2017
Hello Roy,
we are observing a situation when dhcpcd gets a link lost notification, it
sends NOCARRIER to the hook script followed by removing the IP address and
then sending 'EXPIRE' to the hook script.
See:
Jun 27 15:26:12 kernel: [ 144.015919] wlan: EVENT: Link lost (reason 0x0)
Jun 27 15:26:12 kernel: [ 144.016145] wlan: Disconnected from
02:XX:XX:XX:6d:2f: Reason code 3
Jun 27 15:26:12 dhcpcd[696]: mlan0: carrier lost
Jun 27 15:26:12 dhcpcd[696]: mlan0: executing `XXX/dhcpcd-run-hooks'
NOCARRIER
Jun 27 15:26:12 dhcpcd[677]: mlan0: carrier lost
Jun 27 15:26:12 dhcpcd[677]: mlan0: executing `XXX/dhcpcd-run-hooks'
NOCARRIER
Jun 27 15:26:12 dhcpcd[677]: mlan0: deleting route to 192.168.43.0/24
Jun 27 15:26:13 dhcpcd[677]: mlan0: deleting IP address 192.168.43.98/24
Jun 27 15:26:13 dhcpcd[677]: mlan0: executing `XXX/dhcpcd-run-hooks' EXPIRE
This is causing us some grief, because of which we intend to use 'nolink'
option parameter to avoid this situation.
This leads to some questions:
- What is the rationale for forcing a lease (which may not have expired) to
expire for this event?
- What are the consequences of using 'nolink' to the end user application?
to dhcpcd internal functions? Are we compromising anything?
Thanks
-shahid
Archive administrator: postmaster@marples.name