When we configure the network of the Raspberry Pi, some problems often occur. Here, I will list several common problems and solutions for network configuration.
The following problems occur when configuring network wlan0
1. The Raspberry Pi is configured with a network to show that there is no network
The network is configured in the Raspberry Pi, and wlan0 still does not appear with ifconfig.
Solution
1) The first solution:
Use the command sudo raspi-config to display the following interface;
Choose the second carriage return, and the following interface will appear;
Choose N2 Wi-Fi and press Enter, and the following interface will appear;
Scroll down to find cn china and press Enter, and the following interface appears;
This is to enter the name of the WiFi, and the following interface will appear when you press Enter;
This is to enter the WiFi password, press Enter, and then exit.
The above method does not work, and please try the following method
2) The second solution
Create a file on your computer as wpa_supplicant.conf
Enter something:
country=CN
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
network={undefined
ssid="WiFi name"
psk="WiFi Password"
key_mgmt=WPA-PSK
priority=1}
Then throw it into the SD card and power it on again
Special attention is: the suffix name is .conf
2. The following problems occurred during network configuration
Solution
cause of the issue:
When the ifconfig command is executed, no wlan0 information is output, but when iwconfig is executed, you can see the wlan0 information.
When the ifconfig wlan0 command is executed, the output SIOCSIFFLAGS: cannot be operated due to RF-kill.
Execute rfkill unblock all to unlock and solve the problem.
Remember to ifconfig wlan0 on in advance when using WLAN.