Currently, in /etc/wpa_supplicant/wpa_cli.sh, the following is mentioned: # Deactivated, since stopping /etc/init.d/net.wlanX # stops the network completly. EXEC="false ${EXEC} stop" This causes several problems when switching between wifi networks, in that the SSID values and corresponding configuration never get updated after the first connection. I removed the "false" command, and everything seems to work as normal, the network doesn't seem to be stopped completely, as I'm still able to use wpa_cli to connect to a new network, and the status of the connection in "rc-service" seems to update appropriately. So, I'm wondering, is the comment above still valid? Under what circumstances does this break things?
See also comments in Bug 591752.
Comment 1 in that thread is essentially my use case https://bugs.gentoo.org/591752#c1 I'm surprised that this has been noted a few times for over 8 years now. Thanks for letting me know.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ace10427ce3ffe912d349cd8aea32673ecd719d9 commit ace10427ce3ffe912d349cd8aea32673ecd719d9 Author: Matoro Mahri <matoro_gentoo@matoro.tk> AuthorDate: 2024-02-29 19:42:14 +0000 Commit: Mike Gilbert <floppym@gentoo.org> CommitDate: 2024-05-08 01:22:38 +0000 net-wireless/wpa_supplicant: call service stop on AP disconnect Lot of discussion in the primary ticket for this, but apparently multiple users report that previously connected wifi does not come up on resume from suspend. This is due to the original implementation wpa_cli.sh not stopping the service, which was to avoid taking the interface down, which would interfere with wpa_supplicant which needs the interface to be up. However, nowadays we set IN_BACKGROUND which takes care of preventing the interface from being taken down, so it's safe to stop the service. If the service isn't stopped, then trying to start the service on reconnection is a no-op (because the service is already started). Closes: https://bugs.gentoo.org/591752 Closes: https://bugs.gentoo.org/909574 Signed-off-by: Matoro Mahri <matoro_gentoo@matoro.tk> Closes: https://github.com/gentoo/gentoo/pull/35579 Signed-off-by: Mike Gilbert <floppym@gentoo.org> net-wireless/wpa_supplicant/files/wpa_cli-r1.sh | 44 ++ .../wpa_supplicant/wpa_supplicant-2.10-r5.ebuild | 477 +++++++++++++++++++++ .../wpa_supplicant/wpa_supplicant-9999.ebuild | 2 +- 3 files changed, 522 insertions(+), 1 deletion(-)
Thanks!