Linux: Wireless Network

From OnnoWiki
Revision as of 05:27, 15 August 2023 by Onnowpurbo (talk | contribs)
Jump to navigation Jump to search

Install

sudo su
apt update
apt upgrade
apt -y install wireless-network iw network-manager

Cek wireless extension

iwconfig 
wlp2s0    IEEE 802.11  ESSID:off/any  
          Mode:Managed  Access Point: Not-Associated   Tx-Power=-2147483648 dBm   
          Retry short limit:7   RTS   Fragment thr:off
          Encryption key:off
          Power Management:on

Setup menggunakan nmcli

nmcli d
nmcli r wifi on
nmcli d wifi list

Ganti my_wifi dengan access point kita Ganti <password> dengan password wifi

nmcli d wifi connect my_wifi password <password>
nmcli d wifi connect o1 password 123456

Setup WiFi

ifconfig wlp2s0 up

sudo iw wlp2s0 scan | grep -Po '(signal|SSID):\K.*' | sed 's/ $/ [unknown SSID]/' | paste -d ' ' - - | cut -c2- | sort -gr 
-54.00 dBm  o1
-55.00 dBm  o3
-65.00 dBm  Derry's
-75.00 dBm  Yan's Family\x20
-77.00 dBm  Zamzam
-79.00 dBm  TP-Link_C1C8
-79.00 dBm  ODC
-83.00 dBm  Swadaya20
-83.00 dBm  OXYGEN

Set ESSID dll

iwconfig wlp2s0 essid o1
iwconfig wlp2s0
wlp2s0    IEEE 802.11  ESSID:"o1"  
          Mode:Managed  Access Point: Not-Associated   Tx-Power=-2147483648 dBm   
          Retry short limit:7   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:on