After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 767696 - Cannot disable Airplane Mode - randomly on
Cannot disable Airplane Mode - randomly on
Status: RESOLVED DUPLICATE of bug 760517
Product: gnome-settings-daemon
Classification: Core
Component: media-keys
3.20.x
Other Linux
: Normal normal
: ---
Assigned To: gnome-settings-daemon-maint
gnome-settings-daemon-maint
Depends on:
Blocks:
 
 
Reported: 2016-06-15 14:28 UTC by leazar
Modified: 2017-05-19 09:02 UTC
See Also:
GNOME target: ---
GNOME version: 3.19/3.20



Description leazar 2016-06-15 14:28:14 UTC
I enabled Gnome's airplane mode by pressing its function key accidentally, then disabled it as I don't need it. Since then, it keeps reenabling randomly - sometimes at boots, sometimes after resuming from sleep, thus disabling my wifi and bluetooth devices.

It keeps happening no matter how many times I:
- rebooted, or
- enabled/disabled airplane mode, and/or wifi, and/or bluetooth, or
- used nmcli r all off / nmcli r all on
- or used any other advice found on the web (looks like I'm not alone...)

I reinstalled my linux system, but then when I hit the function key again (wifi key lies next to brightness key on my laptop, so it's bound to happen sooner or later), I went through the same nightmare and I had to reinstall again.

Please fix this absurd behaviour, or let me know where is airplane mode's state stored so that I can revert it instead of reinstalling everything.

Specs: Arch Linux with kernel 4.5.4-1, gnome-shell 3.20.2-1, networkmanager 1.2.2-1
Comment 1 Thomas Haller 2016-06-15 14:47:03 UTC
what is the output of
  rfkill list
and
  nmcli radio
?

(you may have to first install rfkill package.)



Also, enable debug logging of NetworkManager.
For that, edit /etc/NetworkManager/NetworkManager.conf and add
  [logging]
  level=TRACE
then, restart NetworkManager via `systemctl restart NetworkManager`.

then, reproduce the issue. show show the output of the commands above, and attach the logfile to this bug (journalctl -u NetworkManager).

Thanks
Comment 2 leazar 2016-06-15 15:14:37 UTC
Thanks for your reply. I had to reboot 3-4 times and finally got airplane mode to auto-enable.

Here are the results or rfkill, nmcli and journalctl: http://pastebin.com/raw/U3Ss58tK
Comment 3 Lubomir Rintel 2016-06-16 16:31:24 UTC
A regression in "media-keys: Add support for Killswitch media keys".

When the XF86WLAN is pressed (on a Lenovo T540p GMET65WW (2.13 )) the following is logged:

(gnome-settings-daemon:389): rfkill-plugin-DEBUG: RFKILL event: idx 3 type 1 (WLAN) op 2 (CHANGE) soft 0 hard 0
(gnome-settings-daemon:389): rfkill-plugin-DEBUG: Changed rfkill with ID 3
(gnome-settings-daemon:389): media-keys-plugin-DEBUG: Received accel id 283 (device-id: 3, timestamp: 279846155, mode: 0x1
(gnome-settings-daemon:389): media-keys-plugin-DEBUG: Launching action for key type '58' (on device id 3)
(gnome-settings-daemon:389): media-keys-plugin-DEBUG: Setting rfkill property AirplaneMode to true
(gnome-settings-daemon:389): rfkill-plugin-DEBUG: RFKILL event: idx 3 type 1 (WLAN) op 2 (CHANGE) soft 1 hard 0
(gnome-settings-daemon:389): rfkill-plugin-DEBUG: Changed rfkill with ID 3
(gnome-settings-daemon:389): rfkill-plugin-DEBUG: Sending original RFKILL_OP_CHANGE_ALL event done
(gnome-settings-daemon:389): media-keys-plugin-DEBUG: Finished changing rfkill, property AirplaneMode is now true
Comment 4 leazar 2016-06-24 17:45:31 UTC
Any update on this yet?
Comment 5 Hans de Goede 2017-05-19 08:46:42 UTC
This sounds a lot like other issues with wlan rfkill handling where both the kernel and gnome are responding to the wifi/wlan hotkey presses which leads to a double toggle of the mode, this has been fixed recently, for gnome 3.24.2 by disabling the hotkey handling in gnome:
https://git.gnome.org/browse/gnome-settings-daemon/commit/?h=gnome-3-24&id=858346b784ee986ef536b68827959105fea84460

And for the upcoming 3.26 series we've done a proper fix:
https://git.gnome.org/browse/gnome-settings-daemon/commit/?id=ccceec40f8302973af47d64846d4c6ea12a938af

Can you see if gnome-3.24.2 fixes this (or the 3.22 gnome-settings-daemon branch from git which also has the 3.24 fix) ?

If that fixes this, this bug should be marked as a duplicate of the bug where the 2 above fixes are discussed: bug 760517.
Comment 6 Rui Matos 2017-05-19 09:02:38 UTC
If it ends up not being a duplicate, feel free to re-open.

*** This bug has been marked as a duplicate of bug 760517 ***