Ubuntu Unleashed 2019 Edition: Covering 18.04, 18.10, 19.04

(singke) #1

For example, when a wireless networking device is first recognized and
initialized for use, the driver most likely reports a new device, like so:


Click here to view code image
zd1211rw 5-4:1.0: firmware version 4725


zd1211rw    5-4:1.0:    zd1211b chip    050d:705c   v4810   \
high 00-17-3f AL2230_RF pa0 G—ns

zd1211rw    5-4:1.0:    eth2

usbcore:    registered  new interface   driver  zd1211rw

This output (from the dmesg command) shows that the eth2 device has
been reported. If DHCP is in use, the device should automatically join the
nearest wireless subnet and be automatically assigned an IP address. If not,
the next step is to use a wireless tool such as iwconfig to set various
parameters of the wireless device. The iwconfig command, along with the
device name (eth2 in this example), shows the status:


Click here to view code image
matthew@seymour:~$ iwconfig eth2
eth2 IEEE 802.11b/g ESSID:"SKY35120" Nickname:"zd1211"
Mode:Managed Frequency:2.462 GHz \
Access Point: 00:18:4D:06:8E:2A
Bit Rate=24 Mb/s
Encryption key:0EFD-C1AF-5C8D-B2C6-7A89-3790-07A7-AC64-
0AB5\
-C36E-D1E9-A230-1DB9-D227-2EB6-D6C8 Security mode:open
Link Quality=100/100 Signal level=82/100
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:0 Invalid misc:0 Missed beacon:0


This example shows a 24Mbps connection to a network named SKY35120.
To change a parameter, such as the transmission rate, use a command-line
option with the iwconfig command like this:


Click here to view code image
matthew@seymour:~$ sudo iwconfig eth2 rate 11M


Other options supported by the iwconfig command include essid, to set
the NIC to connect to a specific network by name; mode, to enable the NIC
to automatically retrieve settings from an access point or connect to another
wireless host; and freq, to set a frequency to use for communication.
Additional options include channel, frag, enc (for encryption), power,
and txpower. Details and examples of these options are in the iwconfig
man page.

Free download pdf