innocent / # nmcli d wifi list
* SSID MODE CHAN RATE SIGNAL BARS SECURITY
=========================================================================
HillBillies Infra 2 54 Mbit/s 90 ▂▄▆█ WPA2
* TELPorto Infra 6 54 Mbit/s 76 ▂▄▆_ WPA1 WPA2
NgNetHookup Infra 6 54 Mbit/s 60 ▂▄▆_ WPA2
我只想保留TELPorto
,HillBillies
并且NgNetHookup
需要被核武器摧毁。通过阅读man nmcli
,我无法发现如何编辑该列表。我正在运行 Linux Mint。
发出:无辜/# iw wlp2s0 扫描
其中一项是(部分):
BSS f8:c3:9e:5d:2d:b8(on wlp2s0)
TSF: 127000886994 usec (1d, 11:16:40)
freq: 2417
beacon interval: 100 TUs
capability: ESS Privacy ShortSlotTime RadioMeasure (0x1411)
signal: -50.00 dBm
last seen: 2964 ms ago
Information elements from Probe Response frame:
SSID: Ng WiFiLink
(...)
(...) /...
发出:innocent / # nmcli -f all dev wifi list
像这样返回输出
SSID => Ng WiFiLink
SSID-HEX => 436975612057256961
BSSID => F8:C3:9E:5D:2D:B8
MODE => Infra
CHAN => 2
FREQ => 2417 MHz
RATE => 54 Mbit/s
SIGNAL => 90
BARS => ▂▄▆█
SECURITY => WPA2
WPA-FLAGS => pair_ccmp group_ccmp psk
RSN-FLAGS => wlp2s0
DEVICE ACTIVE => [ ] ( * if yes ?)
DBUS-PATH => /org/freedesktop/NetworkManager/AccessPoint/85
发出:innocent / # nmcli -p -f General,wifi-properties device show wlp2s0
====================================================================
Device details (wlp2s0)
====================================================================
GENERAL.DEVICE: wlp2s0
(...)
(...) /...
GENERAL.CON-UUID: eb8ab8ea-e616-48ba-a9eb-a6bfdf1ec480
GENERAL.CON-PATH: /org/freedesktopNetworkManagerActiveConnection/6
以下只是 20 个中的几个?还是30?于格组合/实验努力尝试某些语法 nmcli 可以使用:
尝试使用DBUS-PATH // GENERAL.CON-PATH:innocent / # nmcli dev disconnect /org/freedesktop/NetworkManager/ActiveConnection/6
错误:找不到设备“/org/freedesktop/NetworkManager/AccessPoint/83”。
错误:未找到所有设备。
尝试使用 SSID-HEX:innocent / # nmcli dev disconnect 436975612057256961
错误:找不到设备“436975612057256961”。
错误:未找到所有设备。
尝试使用 UUID:
无辜的系统连接 # nmcli dev 断开连接 'eb8ab8ea-e616-48ba-a9eb-a6bfdf1ec480'
错误:找不到设备“eb8ab8ea-e616-48ba-a9eb-a6bfdf1ec480”。
错误:未找到所有设备。
最后,对于 WIN,使用下面答案中引用的命令之一(来自 GAD3R),完成了这项工作:
无辜的系统连接 # nmcli 连接删除 id Ng\ WiFiLink
连接“Ng WiFiLink”(eb8ab8ea-e616-48ba-a9eb-a6bfdf1ec480) 已成功删除。无辜的系统连接#
答案1
该命令nmcli d wifi list
将列出上次扫描的可用接入点。您需要通过以下方式刷新AP列表:
nmcli device wifi rescan
然后:
nmcli d wifi list
info nmcli
:
wifi rescan [ifname ifname] [ssid SSID...] Request that NetworkManager immediately re-scan for available access points... This command does not show the APs, use nmcli device wifi list for that.
可以通过以下方式列出保存的配置:
nmcli connection
要按名称删除连接:
nmcli connection delete id 'connection name'
要通过 UUID 删除连接:
nmcli connection delete uuid 'connection uuid'