현재 아치리눅스에서 무선 네트워크를 공유하려고 합니다. 네트워크 설정에 이 작업을 수행할 수 있는 버튼이 있습니다.
제가 찾던 것이 바로 그것이기 때문에 "열기" 버튼을 클릭했습니다!
그러나 터미널에서 다음 명령을 사용하십시오.
$ sudo journalctl -xef
Nov 03 08:39:53 zbookarch NetworkManager[477]: <info> [1478176793.8790] audit: op="connection-add-activate" pid=12673 uid=1000 result="fail" reason="A 'wireless' setting with a valid SSID is required if no AP path was given."
Nov 03 08:39:53 zbookarch NetworkManager[477]: <info> [1478176793.8928] audit: op="connection-add-activate" pid=12673 uid=1000 result="fail" reason="A 'wireless' setting with a valid SSID is required if no AP path was given."
Nov 03 08:39:53 zbookarch NetworkManager[477]: <info> [1478176793.8967] audit: op="connection-add-activate" pid=12673 uid=1000 result="fail" reason="A 'wireless' setting with a valid SSID is required if no AP path was given."
Nov 03 08:39:53 zbookarch NetworkManager[477]: <info> [1478176793.9001] audit: op="connection-add-activate" pid=12673 uid=1000 result="fail" reason="A 'wireless' setting with a valid SSID is required if no AP path was given."
Nov 03 08:39:53 zbookarch NetworkManager[477]: <info> [1478176793.9011] audit: op="connection-add-activate" pid=12673 uid=1000 result="fail" reason="A 'wireless' setting with a valid SSID is required if no AP path was given."
Nov 03 08:39:53 zbookarch NetworkManager[477]: <info> [1478176793.9019] audit: op="connection-add-activate" pid=12673 uid=1000 result="fail" reason="A 'wireless' setting with a valid SSID is required if no AP path was given."
Nov 03 08:39:53 zbookarch NetworkManager[477]: <info> [1478176793.9029] audit: op="connection-add-activate" pid=12673 uid=1000 result="fail" reason="A 'wireless' setting with a valid SSID is required if no AP path was given."
Nov 03 08:39:53 zbookarch NetworkManager[477]: <info> [1478176793.9037] audit: op="connection-add-activate" pid=12673 uid=1000 result="fail" reason="A 'wireless' setting with a valid SSID is required if no AP path was given."
Nov 03 08:39:53 zbookarch NetworkManager[477]: <info> [1478176793.9046] audit: op="connection-add-activate" pid=12673 uid=1000 result="fail" reason="A 'wireless' setting with a valid SSID is required if no AP path was given."
Nov 03 08:39:53 zbookarch gnome-control-c[12673]: Failed to add new connection: (2) A 'wireless' setting with a valid SSID is required if no AP path was given.
Nov 03 08:39:53 zbookarch gnome-control-c[12673]: Failed to add new connection: (2) A 'wireless' setting with a valid SSID is required if no AP path was given.
Nov 03 08:39:53 zbookarch NetworkManager[477]: <info> [1478176793.9055] audit: op="connection-add-activate" pid=12673 uid=1000 result="fail" reason="A 'wireless' setting with a valid SSID is required if no AP path was given."
Nov 03 08:39:53 zbookarch gnome-control-c[12673]: Failed to add new connection: (2) A 'wireless' setting with a valid SSID is required if no AP path was given.
Nov 03 08:39:53 zbookarch gnome-control-c[12673]: Failed to add new connection: (2) A 'wireless' setting with a valid SSID is required if no AP path was given.
Nov 03 08:39:53 zbookarch gnome-control-c[12673]: Failed to add new connection: (2) A 'wireless' setting with a valid SSID is required if no AP path was given.
Nov 03 08:39:53 zbookarch gnome-control-c[12673]: Failed to add new connection: (2) A 'wireless' setting with a valid SSID is required if no AP path was given.
Nov 03 08:39:53 zbookarch gnome-control-c[12673]: Failed to add new connection: (2) A 'wireless' setting with a valid SSID is required if no AP path was given.
Nov 03 08:39:53 zbookarch gnome-control-c[12673]: Failed to add new connection: (2) A 'wireless' setting with a valid SSID is required if no AP path was given.
Nov 03 08:39:53 zbookarch gnome-control-c[12673]: Failed to add new connection: (2) A 'wireless' setting with a valid SSID is required if no AP path was given.
Nov 03 08:39:53 zbookarch NetworkManager[477]: <info> [1478176793.9064] audit: op="connection-add-activate" pid=12673 uid=1000 result="fail" reason="A 'wireless' setting with a valid SSID is required if no AP path was given."
Nov 03 08:39:53 zbookarch gnome-control-c[12673]: Failed to add new connection: (2) A 'wireless' setting with a valid SSID is required if no AP path was given.
Nov 03 08:39:53 zbookarch gnome-control-c[12673]: Failed to add new connection: (2) A 'wireless' setting with a valid SSID is required if no AP path was given.
아직도 여기저기서 일부 문서를 읽고 있지만 여기 일부 소스 코드에 있는 정확한 오류 메시지 외에는 이 오류와 관련된 어떤 것도 찾지 못했습니다.
https://github.com/lcp/NetworkManager/blob/master/src/nm-device-wifi.c#L1211
친구가 Fedora에서 테스트한 결과 즉시 작동했으며 ESSID
여기서 그는 자신이 만든 Wi-Fi와 일치하는 설정을 찾았습니다.
/etc/sysconfig/network-scripts/ifcfg-Hotspot
하지만 Arch Linux에는 이 경로가 없습니다.
가지다아치의 Software_access_point 위키 페이지핫스팟을 생성하는 방법에 대한 일부 정보가 포함될 수 있습니다. 나중에 후속 조치를 취하겠지만 누구든지 오류에 대한 정보를 갖고 있다면 좋을 것입니다. :)
내 네트워크 카드는 다음과 호환되어야 합니다.
$ iw list
Wiphy phy0
...
Supported interface modes:
* IBSS
* managed
* AP
* AP/VLAN
* monitor
* P2P-client
* P2P-GO
* P2P-device
(필요 AP
)
$ lspci -k | grep -A 3 -i network
3d:00.0 Network controller: Intel Corporation Wireless 7260 (rev 6b)
Subsystem: Intel Corporation Dual Band Wireless-AC 7260
Kernel driver in use: iwlwifi
Kernel modules: iwlwifi
iwlwifi
찾을수있다다음 목록:
| Driver | Manufacturer | cfg80211 | AP | IBSS | mesh | monitor | PHY modes | Buses |
|----------------------------------------------------|---------------------|----------|---------|------|------|---------|------------|--------------------------|
| iwlwifi | Intel | yes | yes (6) | yes | no | yes | A/B/G/N/AC | PCI-E |
AP를 지원하는 것 같습니다.
첫 시도
나는 사용하려고 핫스팟
python2.7 virtualenv를 만들어 설치한 hotspotd==0.1.4
다음 설치했습니다.주인그리고 dnsmasq
.
$ sudo pacman -S hostapd
$ mkvirtualenv -p $(which python27) hotspot
$ workon hotspot
$ pip install hotspotd==0.1.4
$ sudo hotspotd -h
usage: hotspotd [-h] [-v] {start,stop,configure}
A small daemon to create a wifi hotspot on linux
positional arguments:
{start,stop,configure}
optional arguments:
-h, --help show this help message and exit
-v, --verbose
$ sudo hotspotd configure
Verifying connections
Wifi interface found: wlp61s0
Network interface found: enp0s25:
Enter an IP address for your ap [192.168.45.1] :
Enter SSID [joe_ssid] :
Enter 10 digit password [1234567890] :
created hostapd configuration: run.conf
{'wlan': 'wlp61s0', 'SSID': 'joe_ssid', 'ip': '192.168.45.1', 'netmask': '255.255.255.0', 'password': '1234567890', 'inet': 'enp0s25:'}
Configuration saved
$ sudo hotspotd start -v
command: ps aux |grep hostapd |grep -v grep
Verifying interfaces
command: ifconfig
done.
created interface: mon.wlp61s0 on IP: 192.168.45.1
command: ifconfig wlp61s0 up 192.168.45.1 netmask 255.255.255.0
wait..
command: sleep 2
command: ps aux |grep dnsmasq |grep -v grep
command: ps aux |grep hostapd |grep -v grep
enabling forward in sysctl.
command: sysctl -w net.ipv4.ip_forward=1
net.ipv4.ip_forward = 1
creating NAT using iptables: wlp61s0<->enp0s25:
command: iptables -P FORWARD ACCEPT
command: iptables --table nat --delete-chain
command: iptables --table nat -F
command: iptables --table nat -X
command: iptables -t nat -A POSTROUTING -o enp0s25: -j MASQUERADE
command: iptables -A FORWARD -i enp0s25: -o wlp61s0 -j ACCEPT -m state --state RELATED,ESTABLISHED
command: iptables -A FORWARD -i wlp61s0 -o enp0s25: -j ACCEPT
command: iptables -A OUTPUT --out-interface wlp61s0 -j ACCEPT
command: iptables -A INPUT --in-interface wlp61s0 -j ACCEPT
running dnsmasq
command: dnsmasq --dhcp-authoritative --interface=wlp61s0 --dhcp-range=192.168.45.20,192.168.45.100,255.255.255.0,4h
running hostapd
wait..
command: sleep 2
command: hostapd -B /home/gableroux/.virtualenvs/hotspot/lib/python2.7/site-packages/hotspotd/run.conf
Configuration file: /home/gableroux/.virtualenvs/hotspot/lib/python2.7/site-packages/hotspotd/run.conf
Could not read interface wlan0 flags: No such device
nl80211: Driver does not support authentication/association or connect commands
nl80211: deinit ifname=wlan0 disabled_11b_rates=0
Could not read interface wlan0 flags: No such device
nl80211 driver initialization failed.
wlan0: interface state UNINITIALIZED->DISABLED
wlan0: AP-DISABLED
hostapd_free_hapd_data: Interface wlan0 wasn't started
hotspot is running.
wlan0
왜 사용되는지 모르기 때문에 편집을 시도하고 내가 감지한 것으로 /home/gableroux/.virtualenvs/hotspot/lib/python2.7/site-packages/hotspotd/run.conf
교체 했습니다 .wlan0
wlp61s0
$ sudo hotspotd start -v
command: ps aux |grep hostapd |grep -v grep
Verifying interfaces
command: ifconfig
done.
created interface: mon.wlp61s0 on IP: 192.168.45.1
command: ifconfig wlp61s0 up 192.168.45.1 netmask 255.255.255.0
wait..
command: sleep 2
command: ps aux |grep dnsmasq |grep -v grep
command: ps aux |grep hostapd |grep -v grep
enabling forward in sysctl.
command: sysctl -w net.ipv4.ip_forward=1
net.ipv4.ip_forward = 1
creating NAT using iptables: wlp61s0<->enp0s25:
command: iptables -P FORWARD ACCEPT
command: iptables --table nat --delete-chain
command: iptables --table nat -F
command: iptables --table nat -X
command: iptables -t nat -A POSTROUTING -o enp0s25: -j MASQUERADE
command: iptables -A FORWARD -i enp0s25: -o wlp61s0 -j ACCEPT -m state --state RELATED,ESTABLISHED
command: iptables -A FORWARD -i wlp61s0 -o enp0s25: -j ACCEPT
command: iptables -A OUTPUT --out-interface wlp61s0 -j ACCEPT
command: iptables -A INPUT --in-interface wlp61s0 -j ACCEPT
running dnsmasq
command: dnsmasq --dhcp-authoritative --interface=wlp61s0 --dhcp-range=192.168.45.20,192.168.45.100,255.255.255.0,4h
running hostapd
wait..
command: sleep 2
command: hostapd -B /home/gableroux/.virtualenvs/hotspot/lib/python2.7/site-packages/hotspotd/run.conf
Configuration file: /home/gableroux/.virtualenvs/hotspot/lib/python2.7/site-packages/hotspotd/run.conf
nl80211: Could not configure driver mode
nl80211: deinit ifname=wlp61s0 disabled_11b_rates=0
nl80211 driver initialization failed.
wlp61s0: interface state UNINITIALIZED->DISABLED
wlp61s0: AP-DISABLED
hostapd_free_hapd_data: Interface wlp61s0 wasn't started
hotspot is running.
아직 핫스팟은 없습니다. 검색해보니 그 오류가 있네
nl80211: 드라이버 모드를 구성할 수 없습니다.
권장 명령을 시도했습니다.
$ sudo iwconfig wlp61s0 mode master
Error for wireless request "Set Mode" (8B06) :
SET failed on device wlp61s0 ; Invalid argument.
알았어 알았어. 내 네트워크 카드인 것 같군.
MacOS에서는 확실히 더 쉽습니다 :/
편집하다: Fedora로 전환한 이후로 더 이상 이 문제를 재현할 수 없으며 이제 대부분의 기능이 기본적으로 작동합니다. 당신의 도움을 주셔서 감사합니다:)
답변1
호스트 이름에 문제가 있을 수 있습니다. 마침표를 사용하여 이름을 지정하세요. 예: "localhost.mine" 또는 간단히 "localhost"
그놈 제어 센터 -> 세부 정보 -> 개요 -> 장치 이름 설정을 통해 호스트 이름을 설정할 수 있습니다.
호스트 이름을 설정한 후 핫스팟을 다시 생성하세요.
답변2
나는 사용했다create_ap
.
pacman -S create_ap
sudo create_ap -m bridge wifi_interface ethernet_interface test_arch vinod123
참고: 본체에서는 인터넷을 검색할 수 없습니다. NAT
대신 을 사용해야 할 수도 있습니다 bridge
. NAT에 대해 아무것도 확인하려고 시도하지 않았습니다.
답변3
nm-connection-editor
Wi-Fi 핫스팟 연결을 수동으로 생성하여 이 오류를 해결했습니다 . 그 후에는 "핫스팟으로 사용" 버튼이 예상대로 작동합니다.