📄 iwconfig.8
字号:
.\" Jean II - HPLB - 96.\" iwconfig.8.\".TH IWCONFIG 8 "31 October 1996" "net-tools" "Linux Programmer's Manual".\".\" NAME part.\".SH NAMEiwconfig \- configure a wireless network interface.\".\" SYNOPSIS part.\".SH SYNOPSIS.BI "iwconfig [" interface ].br.BI "iwconfig " interface " [essid " X "] [nwid " N "] [freq " F "] [channel " C ].br.BI " [sens " S "] [mode " M "] [ap " A "] [nick " NN ].br.BI " [rate " R "] [rts " RT "] [frag " FT "] [txpower " T ].br.BI " [enc " E "] [key " K "] [power " P "] [retry " R ].br.BI " [commit].br.BI "iwconfig --help".br.BI "iwconfig --version".\".\" DESCRIPTION part.\".SH DESCRIPTION.B Iwconfigis similar to.IR ifconfig (8),but is dedicated to the wireless interfaces. It is used to set theparameters of the network interface which are specific to the wirelessoperation (for example : the frequency)..B Iwconfigmay also be used to display those parameters, and the wirelessstatistics (extracted from.IR /proc/net/wireless )..PPAll these parameters and statistics are device dependant. Each driverwill provide only some of them depending on the hardware support, andthe range of value may change. Please refer to the man page of eachdevice for details..\".\" PARAMETER part.\".SH PARAMETERS.TP.B essidSet the ESSID (or Network Name - in some products it may also calledDomain ID). The ESSID is used to identify cells which are part of thesame virtual network..brAs opposed to the NWID which defines a single cell, the ESSID definesa group of cell connected via repeaters or infrastructure, where theuser may roam. With some card, you may disable the ESSID checking(ESSID promiscuous) with.IR off " or " any " (and " onto reenable it)..br.B Examples :.br.I " iwconfig eth0 essid any".br.I " iwconfig eth0 essid ""My Network"".TP.BR nwid / domainSet the Network ID (in some products it is also called Domain ID). Asall adjacent wireless networks share the same medium, this parameteris used to differenciate them (create logical colocated networks) andidentify nodes belonguing to the same cell. With some card, you maydisable the Network ID checking (NWID promiscuous) with.IR off " (and " onto reenable it)..br.B Examples :.br.I " iwconfig eth0 nwid AB34.br.I " iwconfig eth0 nwid off".TP.BR freq / channelSet the operating frequency or channel in the device. Value below 1000are the channel number, value over this is the frequency in Hz. Youmust append the suffix k, M or G to the value (for example, "2.46G"for 2.46 GHz frequency), or add enough '0'..brChannels are usually numbered starting at 1,and you may use.IR iwpriv (8)to get the total number of channels and list the availablefrequencies. Depending on regulations, some frequencies/channels maynot be available..br.B Examples :.br.I " iwconfig eth0 freq 2.422G".br.I " iwconfig eth0 channel 3".TP.B sensSet the sensitivity threshold. This is the lowest signal level forwhich we attempt a packet reception, signal lower than this are notreceived. This is used to avoid receiving background noise, so youshould set it according to the average noise level. Positive valuesare assumed to be the raw value used by the hardware or a percentage,negative values are assumed to be dBm..brWith some hardware, this parameter also control the defer threshold(lowest signal level for which we consider the channel busy) and thehandover threshold (lowest signal level where we stay associated withthe current access point)..br.B Example :.br.I " iwconfig eth0 sens -80".TP.B modeSet the operating mode of the device, which depends on the networktopology. The mode can be.I Ad-hoc(network composed of only one cell and without Access Point),.I Managed(node connects to a network composed of many Access Points, with roaming),.I Master(the node is the synchronisation master or act as an Access Point),.I Repeater(the node forward packets between other wireless nodes),.I Secondary(the node act as a backup master/repeater),.I Monitor(the node act as a passive monitor and only receives packets) or.IR Auto ..br.B Example :.br.I " iwconfig eth0 mode Managed".br.I " iwconfig eth0 mode Ad-Hoc".TP.B apForce the card to register to the Access Point given by the address,if it is possible. When the quality of the connection goes too low,the driver may revert back to automatic mode (the card finds the bestAccess Point in range)..brYou may also use.I offto re-enable automatic mode without changing the current Access Point,or you may use.I anyor.I autoto force the card to reassociate with the current best Access Point..br.B Example :.br.I " iwconfig eth0 ap 00:60:1D:01:23:45".br.I " iwconfig eth0 ap any".br.I " iwconfig eth0 ap off".TP.BR nick [name]Set the nickname, or the station name. Most 802.11 products do defineit, but this is not used as far as the protocols (MAC, IP, TCP) areconcerned and completely accessory as far as configuration goes. Infact only some diagnostic tools may use it..br.B Example :.br.I " iwconfig eth0 nickname ""My Linux Node"".TP.BR rate / bit [rate]For cards supporting multiple bit rates, set the bit-rate in b/s. Thebit-rate is the speed at which bits are transmitted over the medium,the user speed of the link is lower due to medium sharing andoverhead..brYou must append the suffix k, M or G to the value (decimal multiplier: 10^3, 10^6 and 10^9 b/s), or add enough '0'. Values below 1000 arecard specific, usually an index in the bit-rate list. Use.I autoto select the automatic bit-rate mode (fallback to lower rate on noisychannels), which is the default for most cards, and.I fixedto revert back to fixed setting. If you specify a bit-rate value and append.IR auto ,the driver will use all bit lower and equal than this value..br.B Examples :.br.I " iwconfig eth0 rate 11M".br.I " iwconfig eth0 rate auto".br.I " iwconfig eth0 rate 5.5M auto".TP.BR rts [_threshold]RTS/CTS adds a handshake before each packet transmission to make surethat the channel is clear. This adds overhead, but increaseperformance in case of hidden nodes or large number of activenodes. This parameters set the size of the smallest packet for whichthe node sends RTS, a value equal to the maximum packet size disablethe scheme. You may also set this parameter to.IR auto ", " fixed " or " off ..br.B Examples :.br.I " iwconfig eth0 rts 250".br.I " iwconfig eth0 rts off".TP.BR frag [mentation_threshold]Fragmentation allow to split a IP packet in a burst of smallerfragments transmitted on the medium. In most cases this adds overhead,but in very noisy environment this reduce the error penalty. Thisparameter set the maximum fragment size, a value equal to the maximumpacket size disable the scheme. You may also set this parameter to.IR auto ", " fixed " or " off ..br.B Examples :.br.I " iwconfig eth0 frag 512".br.I " iwconfig eth0 frag off".TP.BR key / enc [ryption]Used to manipulate encryption or scrambling keys and security mode..brTo set the current encryption key, just enter the key in hex digits as.IR XXXX-XXXX-XXXX-XXXX " or " XXXXXXXX .To set a key other than the current key, prepend or append.I [index]to the key itself (this won't change which is the active key). You canalso enter the key as an ASCII string by using the.I s:prefix. Passphrase is currently not supported..brTo change which key is the current active key, just enter.I [index](without entering any key value)..br.IR off " and " ondisable and reenable encryption..brThe security mode may be.I openor.IR restricted ,and its meaning depend on the card used. With most card, in.I openmode no authentication is used and the card may also acceptnon-encrypted sessions, whereas in.I restrictedmode only encrypted sessions are accepted and the card will useauthentication if available..brIf you need to set multiple keys, or set a key and change the activekey, you need to use multiple.B keydirectives. Arguments can be put in any order, the last one will takeprecendence..br.B Examples :.br.I " iwconfig eth0 key 0123-4567-89".br.I " iwconfig eth0 key s:password [2]".br.I " iwconfig eth0 key [2] open".br.I " iwconfig eth0 key off".br.I " iwconfig eth0 key restricted [3] 0123456789".br.I " iwconfig eth0 key 01-23 key 45-67 [4] key [4]".TP.BR powerUsed to manipulate power management scheme parameters and mode..brTo set the period between wake up, enter.IR "period `value'" .To set the timeout before going back to sleep, enter.IR "timeout `value'" .You can also add the.IR min " and " maxmodifiers. By defaults, those values are in seconds, append thesuffix m or u to specify values un milliseconds ormicroseconds. Sometimes, those values are without units (number ofdwell or the like)..br.IR off " and " ondisable and reenable power management. Finally, you may set the powermanagement mode to.I all(receive all packets),.I unicast(receive unicast packets only, discard multicast and broadcast) and.I multicast(receive multicast and broadcast only, discard unicast packets)..br.B Examples :.br.I " iwconfig eth0 power period 2".br.I " iwconfig eth0 power 500m unicast".br.I " iwconfig eth0 power timeout 300u all".br.I " iwconfig eth0 power off".br.I " iwconfig eth0 power min period 2 power max period 4".TP.BR txpowerFor cards supporting multiple transmit powers, set the transmit power in dBm. If .I Wis the power in Watt, the power in dBm is.IR "P = 30 + 10.log(W)" .If the value is postfixed by.IR mW ,it will be automatically converted to dBm..brIn addition, .IR on " and " offenable and disable the radio, and.IR auto " and " fixedenable and disable power control (if those features are available)..br.B Examples :.br.I " iwconfig eth0 txpower 15".br.I " iwconfig eth0 txpower 30mW".br.I " iwconfig eth0 txpower auto".br.I " iwconfig eth0 txpower off".TP.BR retryMost cards have MAC retransmissions, and some allow to set thebehaviour of the retry mechanism..brTo set the maximum number of retries, enter.IR "limit `value'" .This is an absolute value (without unit).The set the maximum length of time the MAC should retry, enter.IR "lifetime `value'" .By defaults, this value in in seconds, append the suffix m or u tospecify values un milliseconds or microseconds..brYou can also add the.IR min " and " maxmodifiers. If the card support automatic mode, they define the boundsof the limit or lifetime. Some other cards define different valuesdepending on packet size, for example in 802.11.I min limitis the short retry limit (non RTS/CTS packets)..br.B Examples :.br.I " iwconfig eth0 retry 16".br.I " iwconfig eth0 retry lifetime 300m".br.I " iwconfig eth0 retry min limit 8".TP.BR commitSome cards may not apply changes done through Wireless Extensionsimmediately (they may wait to agregate the changes or apply it onlywhen the card is brought up via ifconfig). This command (whenavailable) force the card to apply all pending changes..brThis is normally not needed, because the card will eventually applythe changes, but can be usefull for debugging..\".\" DISPLAY part.\".SH DISPLAYFor each device which support wireless extensions,.I iwconfigwill display the name of the.B MAC protocolused (name of device for proprietary protocols), the.B ESSID(Network Name), the.BR NWID ,the.B frequency(or channel), the.BR sensitivity ,the.B modeof operation, the.B Access Pointaddress, the.B bit-ratethe.BR "RTS threshold" ", the " "fragmentation threshold" ,the.B encryption keyand the.B power managementsettings (depending on availability)..brSee above for explanations of what these parameters mean..brIf the label for some values (such as bitrate) is followed by.RB ` = ',it means that the parameter is fixed and forced to that value, if itis followed by.RB ` : 'it is only the current value (device in normal auto mode)..PPIf.I /proc/net/wirelessexists,.I iwconfigwill also display its content. Note that those values will depend onthe driver and the hardware specifics, so you need to refer to yourdriver documentation for proper interpretation of those values..TP.B Link qualityOverall quality of the link. May be based on the level of contentionor interference, the bit or frame error rate, how good the receivedsignal is, some timing synchronisation, or other hardware metric. Thisis an aggregate value, and depend totally on the driver and hardware..TP.B Signal levelReceived signal strength (RSSI - how strong the received signalis). May be arbitrary units or dBm,.I iwconfiguses driver meta information to interpret the raw value given by.I /proc/net/wirelessand display the proper unit or maximum value (using 8 bit arithmetic). In.I Ad-Hocmode, this may be undefined and you should use.IR iwspy ..TP.B Noise levelBackground noise level (when no packet is transmited). Similarcomments as for.BR "Signal level" ..TP.B Rx invalid nwidNumber of packets received with a different NWID or ESSID. Used todetect configuration problems or adjacent network existence (on thesame frequency)..TP.B Rx invalid cryptNumber of packets that the hardware was unable to decrypt. This can beused to detect invalid encryption settings..TP.B Rx invalid fragNumber of packets for which the hardware was not able to properlyre-assemble the link layer fragments (most likely one was missing)..TP.B Tx excessive retriesNumber of packets that the hardware failed to deliver. Most MACprotocol will retry the packet a number of time before giving up..TP.B Invalid miscOther packets lost in relation with specific wireless operations..TP.B Missed beaconNumber of periodic beacons from the Cell or the Access Point we havemissed. Beacons are sent at regular interval to maintain the cellcoordination, failure to receive them usually indicate that we are outof range..\".\" AUTHOR part.\".SH AUTHORJean Tourrilhes \- jt@hpl.hp.com.\".\" FILES part.\".SH FILES.I /proc/net/wireless.\".\" SEE ALSO part.\".SH SEE ALSO.BR ifconfig (8),.BR iwspy (8),.BR iwlist (8),.BR iwevent (8),.BR iwpriv (8),.BR wireless (7).
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -