- Build a network configuration file
Wpa_passphrase SSID passwd > net.conf
- Configuring the NIC
IfconfigWlan0 192.168.1.2Netmask255.255.255.0# Configure network card address
Route add default GW192.168.1.1# Configure the default gateway
IwconfigWlan0Txpower on # Turn on the wireless card
IwconfigWlan0EssidSSID# Set the wireless network SSID
IfconfigWlan0Up #启动Wlan0
- Wpa_supplicant-i wlan0 - c net.conf -dwext # Connect to a wireless network
The above problem stems from my deletion pdnsd, causes all network unreachable, its reason deletes pdnsd when simultaneously deletes the Network-manager and the Network-manager-gnome package, after the network reinstall these two packages can solve.
Note: 1. The above italic part should be modified according to the individual situation
2. You can connect to the wireless network at this time, the following questions can be queried online
3. This method applies to WPA-encrypted wireless networks, which are not normally encrypted or unencrypted in this range
Ubuntu 12.04 cannot connect to a wireless network