You are not logged in.
Pages: 1
Hi all, I use wired and wifi connections on my laptop. I'd like the wifi automatically disabled when I use the wired connection ; and the wifi connection automatically on when I don't use the wired one. How to set that up? thanks in advance.
ps: I use the mate desktop with network-manager.
Offline
Please always check the Wiki first before posting: Use dispatcher to automatically toggle wireless depending on LAN cable being plugged in
Offline
Thanks for answering with a link to a solution, but it's not exactly what I'm looking for...
So, whatever, I'm going to look up on the net for a better solution. Thanks.
Offline
It's exactly the solution to your described problem. If it isn't then your problem description doesn't match your end goal.
Offline
How is that not the solution you are looking? your request and that solution linked are 1:1 the same
Offline
It doesn't! I don't want both connections (wifi and wired) connected in the same time. I use mainly wired connection. And maybe an hour a day (wifi). When I disconnect wifi it doesn't reconnect automatically when Ethernet cable is removed... I use a command line "nmcli con up my-uid" to reconnect the wifi manually. The script doesn't do it.
Offline
Did you check the journal to see why the script failed?
I've had sucess following https://wiki.archlinux.org/title/System … _interface but I appreciate you might not want to change away from NM.
Jin, Jîyan, Azadî
Offline
It should, otherwise you can also add the corresponding nmcli con command to the radio on directive. It's a dispatcher script, did you put it at the correct location and make it executable and enabled and started the NetworkManager-dispatcher.service?
Last edited by V1del (2025-01-08 15:05:04)
Offline
what is your output of /etc/NetworkManager/dispatcher.d/wlan_auto_toggle.sh
Offline
https://deepl.com is fluent in french and english.
Offline
FWIW if you don't actually care about the fact the wlan device is still active, I'm pretty sure you can define routing rules (might even already be default) so that the ethernet connection is prioritised anyway even if WLAN is connected at the same time
Offline
I tried the tutorial on that page: https://blog.christophersmart.com/2021/ … rkmanager/
What it does? the wifi is disabled when Ethernet is turned on ; but when I turn Ethernet off it doesn't enable wifi again, and even less my personal wifi connection.
Ps: To Seth, Deepl told me you can't speak French... :-)
Offline
OK, my mistake... wifi is enabled again when Ethernet is turned off... but my personal wifi connection isn't restored... I have to put it back manually if I want Internet.
Something I didn't figure out correctly on what the script does? maybe Deepl could help on this?
Last edited by prince2phor (2025-01-08 17:25:33)
Offline
You said anything about some blog?
Try https://wiki.archlinux.org/title/Networ … et_on_boot
Je ne parle pas français, mais si je peux, c'est une autre question.
Offline
OK my mistake (part 2) I finally noticed that something wasn't well set on my known connection in Network-Manager. "Connect automatically" with priority was unticked... So now It works like a clockwise.
Who said that users are often responsible of the issue they're asking help for... thanks!
Last edited by prince2phor (2025-01-08 17:54:15)
Offline
Next time, please read any wiki articles we link you carefully and thoroughly instead of saying "it doesn't work!"
Offline
Next time I won't ask here to avoid reading such comments.
Offline
Checking your auto connection settings would've been my next suggestion, but generally we can help you better if you provide more info on the trouble you have.
If you consider this [SOLVED] please mark it as such by editing the title in your first post.
Offline
Pages: 1