LinuxCommandLibrary

iwinfo

Get wireless interface information

TLDR

List all available wireless interfaces

$ iwinfo
copy

Display detailed information on a specific wireless interface
$ iwinfo [interface] info
copy

Scan for nearby wireless networks visible to the interface
$ iwinfo [interface] scan
copy

List connected devices
$ iwinfo [interface] assoclist
copy

List channels supported by the interface
$ iwinfo [interface] freqlist
copy

List available transmit power levels for the interface
$ iwinfo [interface] txpowerlist
copy

Display help
$ iwinfo h
copy

SYNOPSIS

iwinfo [] [ []]
iwinfo []

PARAMETERS


    Specifies the wireless interface to query (e.g., wlan0, radio0).

info
    Displays comprehensive information about the specified wireless device, including mode, SSID, channel, frequency, transmit power, signal quality, noise, and encryption details.

scan
    Initiates a scan for available wireless networks and lists the found SSIDs along with their properties like signal strength and security type.

assoclist
    When the device is operating in Access Point (AP) mode, this command lists all currently associated client devices, often including their MAC address, signal strength, and connection duration.

freqlist
    Shows a list of supported frequencies and channels for the specified wireless device.

txpowerlist
    Displays a list of supported transmit power levels (in dBm) for the wireless device.

event
    Monitors and displays real-time wireless events, such as client association or de-association, useful for debugging and monitoring network changes.


    Allows querying a specific property of the wireless device directly (e.g., channel, ssid, signal) to get a single value output.

DESCRIPTION

The iwinfo command is a lightweight utility designed primarily for embedded Linux systems, such as OpenWrt, to query and display wireless device information and statistics. It serves as a simplified, unified interface to access data that might otherwise require more complex tools like iw (for netlink) or iwconfig (for wireless extensions).

iwinfo provides concise and script-friendly output, making it ideal for automated monitoring, configuration scripts, and diagnostic purposes on resource-constrained devices. It can retrieve details like network mode, SSID, channel, frequency, transmit power, signal quality, noise level, and associated client lists. Its design focuses on ease of use and consistent output for various wireless drivers and hardware.

CAVEATS

iwinfo is not a standard utility on all Linux distributions; it is predominantly found on embedded systems like OpenWrt and other custom Linux builds. Users on typical desktop Linux environments usually rely on iw or iwconfig. Its functionality can vary slightly based on the installed version and the specific wireless driver capabilities. Direct configuration of wireless parameters is not supported by iwinfo; it is solely for querying information.

SCRIPTING OUTPUT

iwinfo's output is often designed to be easily parseable by scripts, frequently presenting information in a structured, key-value format or as raw numerical data suitable for automation and integration into system monitoring tools.

DRIVER ABSTRACTION

One of iwinfo's key strengths is its ability to abstract away the underlying wireless driver and kernel interface details, providing a consistent way to query information regardless of whether the device uses cfg80211/nl80211 (Netlink) or the older Wireless Extensions API.

HISTORY

iwinfo was developed as part of the OpenWrt project to provide a more consistent and simplified interface for retrieving wireless network information compared to the existing, often disparate, tools like iw (which uses Netlink) and iwconfig (which uses Wireless Extensions). Its inception aimed to address the specific needs of embedded systems, offering a unified API for various wireless drivers and making wireless diagnostics and scripting more straightforward within the OpenWrt ecosystem, abstracting away underlying kernel interface complexities.

SEE ALSO

iw(8), iwconfig(8), ip(8), netstat(8)

Copied to clipboard