내 무선 어댑터:
lsusb | rg -i wireless
Bus 001 Device 005: ID 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter
내 네트워크 인터페이스를 나열합니다.
iwconfig
lo no wireless extensions.
enp6s0 no wireless extensions.
wlx38a28c80c24f IEEE 802.11 Mode:Master Tx-Power=20 dBm
Retry short long limit:2 RTS thr:off Fragment thr:off
Power Management:off
Hostapd를 설치하고 구성을 설정합니다.
sudo apt-get install hostapd
sudo vim /etc/hostapd/hostapd.conf
interface=wlx38a28c80c24f
driver=nl80211
ssid=myap
hw_mode=g
channel=7
macaddr_acl=0
auth_algs=3
ignore_broadcast_ssid=0
wmm_enabled=1
ieee80211n=1
ht_capab=[HT40-][SHORT-GI-20][SHORT-GI-40]
wpa=2
wpa_passphrase=linuxprobe
macaddr_acl=0
auth_algs=1
ignore_broadcast_ssid=0
wpa_key_mgmt=WPA-PSK
wpa_pairwise=TKIP
rsn_pairwise=CCMP
dnsmasq를 설치하고 구성을 설정합니다.
sudo apt-get install dnsmasq
sudo vim /etc/dnsmasq.conf
resolv-file=/etc/resolv.dnsmasq.conf
server=/cn/114.114.114.114
server=/taobao.com/114.114.114.114
listen-address=127.0.0.1,192.168.11.1
dhcp-range=192.168.11.50,192.168.11.150,12h
dhcp-option=3,192.168.11.1
dhcp-option=6,192.168.11.1
cache-size=1024
conf-dir=/etc/dnsmasq.d
sudo vim /etc/resolv.dnsmasq.conf
nameserver 114.114.114.114
sudo vim /etc/resolv.conf
nameserver 127.0.0.1
서비스를 시작합니다:
sudo systemctl start dnsmasq.service
sudo systemctl start hostapd.service
이제 myap
비밀번호를 사용하여 연결했는데 linuxprobe
Android 휴대폰을 통해 액세스 포인트에 액세스할 수 없는 이유는 무엇입니까?
답변1
다음 명령을 실행합니다.
git clone https://github.com/oblique/create_ap.git
cd create_ap
sudo make install
ifconfig
enp6s0
wlx38a28c80c24f
sudo ifconfig wlx38a28c80c24f up
wlan="wlx38a28c80c24f"
eth="enp6s0"
create_ap $wlan $eth MyAccessPoint MyPassPhrase
sudo systemctl start create_ap
이제 Android 휴대폰에서 create_ap을 통해 AP 설정에 연결할 수 있습니다.