What information iwconfig provides on Ubuntu


lo        no wireless extensions.

eth0      no wireless extensions.

wmaster0  no wireless extensions.

wlan0     IEEE 802.11bgn  ESSID:"Network"  
          Mode:Managed  Frequency:2.412 GHz  Access Point: Not-Associated   
          Tx-Power=20 dBm   
          Retry min limit:7   RTS thr:off   Fragment thr=2352 B   
          Power Management:off
          Link Quality:0  Signal level:0  Noise level:0
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:0   Missed beacon:0

vboxnet0  no wireless extensions.

pan0      no wireless extensions.

“Network” is the name of my wireless network, btw. But what does this all mean? How can this information help me aquire a working wireless connection?

When I try associating a key using

sudo iwconfig wlan0 key s:my_key

I get the following error message:

Error for wireless request "Set Encode" (8B2A) :
    SET failed on device wlan0 ; Invalid argument.

I do have the right key though, so what’s the problem?


wlan0 IEEE 802.11bgn ESSID:””

Means your card supports 802.11 b/g/n standards and you are currently not conneted to any network (ESSID, the name identifying network is empty)


Operating mode for the device. Depending on your card you may select one of these:

  • Ad-Hoc (network composed of only one cell and without Access Point)
  • Managed (node connects to a network composed of many Access Points, with roaming)
  • Master (the node is the synchronisation master or acts as an Access Point)
  • Repeater (the node forwards packets between other wireless nodes)
  • Secondary (the node acts as a backup master/repeater)
  • Monitor (the node is not associated with any cell and passively monitor all packets on the frequency)
  • Auto.

Frequency:2.412 GHz

Or channel – same as you see in GUI tools to manage wireless cards – you may input either frequency or channel number

Access Point: Not-Associated

Gives you exact MAC address of AP you’re connecting to. If you have multiple AP’s in your network and you’d like to figure out to which AP you’re connected.

Tx-Power=20 dBm

This is your’s card transmit power – basicaly the higher, the more energy your card will require.

Retry min limit:7

This option describes retry behaviour of your card.

RTS thr:off

This describes whether your card checks for clear channel everytime it sends a packet. This may improve performance in some cases.

Fragment thr=2352 B

This describes maximum packet size your card will send – basicaly if you have a noisy environment, the smaller the packets, the less propable is that your packet would have to be retransmitted, and if it would happen, the less data would have to be transmitted. According to manual, if this value is higher than maximum packet size, card may send several packets together.

Power Management:off

This option gives information about power management your card use. You may choose to discard some packages (ie. bcast and mcast), set your card’s activity cicles and some other options.

Link Quality:0 Signal level:0 Noise level:0

If your card is connected, this is where you’d be looking for link quality:) Signal lvl and noise lvl may be given dBm or any arbirtary unit.

Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0

Some statistics about errors during receiving: nwid means that probably there’s another network in your neighbourhood using same channel as yours, invalid crypto is a number of packet you card was unable to decrypt, invalid fragmentation means there were some packets missing.

Tx excessive retries:0

This is a number of packets your card was unable to deliver.

All above is based on iwconfig manual, you may find hml version here.

If you’re going to configure your card using command line tools be sure to turn nerworkmanager off and use Sathya’s answer. If you have your key as a text, use

sudo iwconfig wlan0 key s:your_key

instead of

sudo iwconfig wlan0 key ABCD-1234-5678-EFG2