Linux WiFi configuration

Source: Internet
Author: User
Tags get ip

Use the Iwconfig command:
Search Wireless network iwlist wlan0 Scan
Write down Essid.
Connect a wireless network without a password iwconfig wlan0 Essid chinanet where chinanet is the search for a wireless network Essid
Connect a password to the wireless network Iwconfig wlan0 Essid chinanet key xxxx where xxxx is the password
Enable wireless card ifconfig wlan0 up
Get IP dhclient wlan0 or dhcpcd wlan0 via DHCP?


$vi/etc/network/interfaces Add the following:
Auto Wlan0
Iface Wlan0 inet DHCP
pre-up IP link Set wlan0 up
Pre-up iwconfig wlan0 Essid your-ssid-here
Wpa-ssid Your-ssid-here
WPA-PSK Your-passwd-here

Finally restart the network $/etc/init.d/networking restart



Or

Auto loiface lo inet loopback #allow-hotplug eth0#iface eth0 inet dhcp #auto eth0#iface eth0 inet static#address 192.1 68.101.50#netmask 255.255.255.0#gateway 192.168.101.1#broadcast 192.168.101.255

#auto Wlan0

#iface Wlan0 inet DHCP

#wpa-ssid Your-network-name

#wpa-key-mgmt WPA-PSK

#wpa-group TKIP CCMP

#wpa-PSK Your-network-key




From for notes (Wiz)

Linux WiFi configuration

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.