Find and connect to WiFi networks from the command line
Run:
$ nmcli device wifi
to list availabe Wifi access points.
You should see something like this:
IN-USE BSSID SSID MODE CHAN RATE SIGNAL BARS SECURITY
A2:C9:EB:E7:DB:B8 Wifi_name Infra 3 270 Mbit/s 100 ▂▄▆█ WPA2
9C:C9:EB:E7:DB:B8 -- Infra 3 130 Mbit/s 100 ▂▄▆█ WPA2
9C:C9:EB:32:41:DD -- Infra 3 270 Mbit/s 85 ▂▄▆█ WPA2
A2:C9:EB:32:41:DD Wifi_name Infra 3 270 Mbit/s 82 ▂▄▆█ WPA2
A2:C9:EB:E9:92:87 Wifi_name Infra 3 270 Mbit/s 75 ▂▄▆_ WPA2
9C:C9:EB:E9:92:87 -- Infra 3 270 Mbit/s 70 ▂▄▆_ WPA2
A2:C9:EB:E9:88:49 Wifi_name Infra 3 270 Mbit/s 29 ▂___ WPA2
9C:C9:EB:E9:88:49 -- Infra 3 130 Mbit/s 25 ▂___ WPA2
Then pick the BSSID of the access point you want to connect to e.g. A2:C9:EB:E7:DB:B8
, and run:
$ nmcli device wifi connect A2:C9:EB:E7:DB:B8 password [password]
If the connection to the access point was successful, you should see:
Device 'wlp2s0' successfully activated with 'redacted_address'.
To test the connection was established, you can run:
$ ping yctct.com
See man nmcli
to learn more about nmcli
.
Issues
- when I connect to a WiFi access point using nmcli, I have to disconnect from the VPN, for the internet connection to establish; then I can reconnect to the VPN
- sometimes, nmcli says my laptop is connected to an access point, however, ping yields 100% packet loss; I need to figure why.
This was tested on a Thinkpad X220 running GNU/Linux Trisquel 11 on osboot.
Note: I found nmcli
with the help of the utility apropos
by running apropos network
.
✍✍✍✍✍✍✍✍✍✍✍✍✍✍
I do self-funded research and I'm writing a book.
> What's the book about?
About technologies and agency.
Meaning, technologies can foster agency. No doubt. But I am also asking:
Can usage of technologies give us a sense of empowerment while in fact undermining our abilities?
I posted a summary of the prologue on the homepage: https://yctct.com/
✍✍✍✍✍✍✍✍✍✍✍✍✍✍
personal computing command-line interface (cli) gnu linux trisquel shell literacy office applications wiki nmcli