FS#46859 - [netctl] netctl & netctl-auto fail to restart adapter that was physically removed

Attached to Project: Arch Linux
Opened by Nicholas Moore (diamondice00085) - Saturday, 24 October 2015, 15:10 GMT
Last edited by Jouke Witteveen (jouke) - Tuesday, 14 March 2017, 17:16 GMT
Task Type Bug Report
Category Arch Projects
Status Closed
Assigned To Jouke Witteveen (jouke)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Description:

Upon removal of a USB wireless adapter, netctl@wlan0 or netctl-auto@wlan0 (wlan0 for example) does not clean up after itself and fails to restart cleanly upon reattachment of the device. In order to have netctl or netctl-auto you need to remove some temporary files first, only after these files are removed will netctl-auto restart properly.

Additional info:
* package version(s)
netctl version 1.11

* config and/or log files etc.
-- Logs begin at Tue 2015-09-29 00:37:42 UTC. --
Oct 23 22:36:24 beluga dhcpcd[7154]: wlan0: soliciting a DHCP lease
Oct 23 22:36:28 beluga dhcpcd[7154]: wlan0: offered 192.168.200.178 from 192.168.200.1
Oct 23 22:36:28 beluga dhcpcd[7154]: wlan0: ignoring offer of 192.168.200.178 from 192.168.200.1
Oct 23 22:36:28 beluga dhcpcd[7154]: wlan0: probing static address 192.168.200.178/24
Oct 23 22:36:33 beluga dhcpcd[7154]: wlan0: leased 192.168.200.178 for 259200 seconds
Oct 23 22:36:33 beluga dhcpcd[7154]: wlan0: adding route to 192.168.200.0/24
Oct 23 22:36:33 beluga dhcpcd[7154]: wlan0: adding default route via 192.168.200.1
Oct 23 22:36:48 beluga systemd[1]: Started Automatic wireless network connection using netctl profiles.
Oct 23 22:37:21 beluga wpa_actiond[7142]: Interface 'wlan0' lost connection to network 'picostation'
Oct 23 22:37:51 beluga wpa_actiond[7142]: Interface 'wlan0' reestablished connection to network 'picostation'
Oct 24 15:06:24 beluga wpa_actiond[7142]: Interface 'wlan0' lost connection to network 'picostation'
Oct 24 15:06:24 beluga dhcpcd[7264]: wlan0: dhcp if_readrawpacket: Network is down
Oct 24 15:06:24 beluga dhcpcd[7264]: wlan0: removing IP address 192.168.200.178/24
Oct 24 15:06:24 beluga dhcpcd[7264]: wlan0: deleting route to 192.168.200.0/24
Oct 24 15:06:24 beluga dhcpcd[7264]: wlan0: deleting default route via 192.168.200.1
Oct 24 15:06:24 beluga systemd[1]: Stopping Automatic wireless network connection using netctl profiles...
Oct 24 15:06:24 beluga wpa_actiond[7142]: Interface 'wlan0' disconnected from network 'picostation'
Oct 24 15:06:24 beluga dhcpcd[25704]: sending signal TERM to pid 7264
Oct 24 15:06:24 beluga dhcpcd[25704]: waiting for pid 7264 to exit
Oct 24 15:06:24 beluga dhcpcd[7264]: wlan0: removing interface
Oct 24 15:06:35 beluga systemd[1]: Stopped Automatic wireless network connection using netctl profiles.
Oct 24 15:06:51 beluga systemd[1]: Stopped Automatic wireless network connection using netctl profiles.
Oct 24 15:06:51 beluga systemd[1]: Starting Automatic wireless network connection using netctl profiles...
Oct 24 15:06:52 beluga netctl-auto[25870]: Could not create the configuration file for interface 'wlan0'
Oct 24 15:06:52 beluga systemd[1]: netctl-auto@wlan0.service: Control process exited, code=exited status=1
Oct 24 15:06:52 beluga systemd[1]: Failed to start Automatic wireless network connection using netctl profiles.
Oct 24 15:06:52 beluga systemd[1]: netctl-auto@wlan0.service: Unit entered failed state.
Oct 24 15:06:52 beluga systemd[1]: netctl-auto@wlan0.service: Failed with result 'exit-code'.
Oct 24 15:07:21 beluga systemd[1]: Stopped Automatic wireless network connection using netctl profiles.
Oct 24 15:07:21 beluga systemd[1]: Starting Automatic wireless network connection using netctl profiles...
Oct 24 15:07:21 beluga netctl-auto[25945]: Included profile 'wlan0-picostation'
Oct 24 15:07:21 beluga netctl-auto[25945]: Included profile 'wlan0-Starbucks WiFi'
Oct 24 15:07:22 beluga wpa_actiond[25967]: Starting wpa_actiond session for interface 'wlan0'
Oct 24 15:07:22 beluga systemd[1]: Started Automatic wireless network connection using netctl profiles.
Oct 24 15:07:33 beluga wpa_actiond[25967]: Interface 'wlan0' connected to network 'picostation'
Oct 24 15:07:33 beluga dhcpcd[25993]: DUID 00:01:00:01:1d:a7:e8:c0:c4:e9:84:18:0c:77
Oct 24 15:07:33 beluga dhcpcd[25993]: wlan0: IAID 27:12:ac:19
Oct 24 15:07:34 beluga dhcpcd[25993]: wlan0: rebinding lease of 192.168.200.178
Oct 24 15:07:34 beluga dhcpcd[25993]: wlan0: probing static address 192.168.200.178/24
Oct 24 15:07:39 beluga dhcpcd[25993]: wlan0: leased 192.168.200.178 for 259200 seconds
Oct 24 15:07:39 beluga dhcpcd[25993]: wlan0: adding route to 192.168.200.0/24
Oct 24 15:07:39 beluga dhcpcd[25993]: wlan0: adding default route via 192.168.200.1

Steps to reproduce:
[root@beluga network]# systemctl start netctl-auto@wlan0
#*Physically remove the USB wireless adapter*
[root@beluga network]# systemctl status netctl-auto@wlan0 #(unit should be failed)
#*Physically reattach the USB wireless adapter*
[root@beluga network]# systemctl restart netctl-auto@wlan0 #(unit should fail to start because of the presence of temprary files)
[root@beluga network]# rm /run/network/wpa_supplicant_wlan0.conf
[root@beluga network]# systemctl restart netctl-auto@wlan0
[root@beluga network]# systemctl status netctl-auto@wlan0 #unit should be active again
This task depends upon

Closed by  Jouke Witteveen (jouke)
Tuesday, 14 March 2017, 17:16 GMT
Reason for closing:  Fixed
Additional comments about closing:  8ccfe97
Comment by Jouke Witteveen (jouke) - Tuesday, 14 March 2017, 17:16 GMT
Should be fixed in 1.13.

Loading...