1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2024-10-28 15:19:43 +01:00
tldr/pages/linux/iw-dev.md
Pete 32cae5420e
Iw-dev: add page iw: information link {dev, phy, reg, help examples} (#14133)
* 

Co-authored-by: Wiktor Perskawiec <git@spageektti.cc>
Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>
2024-10-12 12:43:55 +02:00

1.1 KiB

iw dev

Show and manipulate wireless devices. For a list of channels, frequencies and reg information: https://wireless.docs.kernel.org/en/latest/en/developers/documentation/channellist.html. More information: https://wireless.docs.kernel.org/en/latest/en/users/documentation/iw.html.

  • Set device to monitor mode (interface must be down first. See also ip link):

sudo iw dev {{wlp}} set type monitor

  • Set device to managed mode (interface must be down first):

sudo iw dev {{wlp}} set type managed

  • Set device WiFi channel (device must first be in monitor mode with the interface up):

sudo iw dev {{wlp}} set channel {{channel_number}}

  • Set device WiFi frequency in Mhz (device must first be in monitor mode with the interface up):

sudo iw dev {{wlp}} set freq {{freq_in_mhz}}

  • Show all known station info:

iw dev {{wlp}} station dump

  • Create a virtual interface in monitor mode with a specific MAC address:

sudo iw dev {{wlp}} interface add "{{vif_name}}" type monitor addr {{12:34:56:aa:bb:cc}}

  • Delete virtual interface:

sudo iw dev "{{vif_name}}" del