You are not logged in.

#1 2014-09-18 14:32:04

lagagnon
Member
From: an Island in the Pacific...
Registered: 2009-12-10
Posts: 1,087
Website

netctl: automatic switch to stronger router?

I live in  concrete and steel home, hence have 3 routers to enable signal strength in all parts of the house. One router is the primary router, a second router is set up as a WAP, with same SSID but on a different channel and the third router is a Repeater of the second one, with a different SSID and different channel.

I am using netcl-auto with systemd. I have the profiles for the two different SSID's set up and wireless works fine.

However, I am hoping to get netctl to switch automatically to the strongest signal and cannot seem to do that - if there even is a way. At present I am having to use wifi-menu to switch manually. Any assistance appreciated.

Last edited by lagagnon (2014-09-18 18:13:05)


Philosophy is looking for a black cat in a dark room. Metaphysics is looking for a black cat in a dark room that isn't there. Religion is looking for a black cat in a dark room that isn't there and shouting "I found it!". Science is looking for a black cat in a dark room with a flashlight.

Offline

#2 2014-09-18 16:26:55

rsmarples
Member
Registered: 2009-05-12
Posts: 287

Re: netctl: automatic switch to stronger router?

That's not really a job for netctl, or any wifi manager really.
Try instead building your home network like this:

http://wiki.openwrt.org/doc/howto/clientmode

I myself use 2 OpenWRT APs in WDS in my house and it works wonders. However there still has to be a strong reason to change which AP the wireless uses and there is a little lag in changing, but it works walking from one end of the house to the other.

Offline

#3 2014-09-18 18:27:59

lagagnon
Member
From: an Island in the Pacific...
Registered: 2009-12-10
Posts: 1,087
Website

Re: netctl: automatic switch to stronger router?

WDS may not be an option as I have different routers - I'll check their chipsets, so thanks for the suggestion....


Philosophy is looking for a black cat in a dark room. Metaphysics is looking for a black cat in a dark room that isn't there. Religion is looking for a black cat in a dark room that isn't there and shouting "I found it!". Science is looking for a black cat in a dark room with a flashlight.

Offline

#4 2014-09-18 21:48:43

Leonid.I
Member
From: Aethyr
Registered: 2009-03-22
Posts: 999

Re: netctl: automatic switch to stronger router?

lagagnon wrote:

I live in  concrete and steel home, hence have 3 routers to enable signal strength in all parts of the house. One router is the primary router, a second router is set up as a WAP, with same SSID but on a different channel and the third router is a Repeater of the second one, with a different SSID and different channel.

I am using netcl-auto with systemd. I have the profiles for the two different SSID's set up and wireless works fine.

However, I am hoping to get netctl to switch automatically to the strongest signal and cannot seem to do that - if there even is a way. At present I am having to use wifi-menu to switch manually. Any assistance appreciated.

netctl-auto is quite convoluted thing because it starts wpa_actiond which in turn listens to events from wpa_supplicant  and executes predefined scripts. Now, wpa_supplicant knows about signal strength (in dBm). It follows that one can _in principle_ define a custom action script for wpa_actiond which will disconnect from a weak AP and connect to a stronger one.

That said, what you want to do is a _terrible_ idea because of:
1. Wifi signal strength is not what you think it is. Basically, that number above in dBm has almost nothing to do with actual intensity of the radio signal, but rather depends on the wireless driver and strongly fluctuates with time.
2. Signal strength has only indirect relation to the bandwidth (which you want to maximize): weak APs will provide small bandwidth, but converse is not true...
3. What about situations when there are 2 APs of roughly the same strength (as seen by your wpa_supplicant)? You'll experience endless reconnects most likely...

Do what rsmarples suggested -- that's a proper way of handling things.


Arch Linux is more than just GNU/Linux -- it's an adventure
pkill -9 systemd

Offline

#5 2014-09-18 22:05:45

progandy
Member
Registered: 2012-05-17
Posts: 5,280

Re: netctl: automatic switch to stronger router?

It might be possible to set up a traditional roaming wireless network.
Connect all access points via wired LAN
each AP gets a static IP
disable all but one DHCP server
give all APs the same SSID
set the same encryption for each AP
use a different channel for each AP, e.g. 3, 6, 11 (always in increments of at least 3)


| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |

Offline

Board footer

Powered by FluxBB