Open ghost opened 8 years ago
Give exactly the create_ap command you are running and it's output. Also give me the iw list
, iw dev
(after you run create_ap).
What phone do you have?
The command I use for creating the AP and its output:
root@CYBERDYNE-SYSTEMS:/opt/create_ap# create_ap wlan0 eth0 "Acer Aspire V3-772G" "mamaaremere"
Config dir: /tmp/create_ap.wlan0.conf.6R1a6QwO
PID: 6290
Network Manager found, set ap0 as unmanaged device... DONE
Creating a virtual WiFi interface... ap0 created.
Sharing Internet using method: nat
hostapd command-line interface: hostapd_cli -p /tmp/create_ap.wlan0.conf.6R1a6QwO/hostapd_ctrl
Configuration file: /tmp/create_ap.wlan0.conf.6R1a6QwO/hostapd.conf
Using interface ap0 with hwaddr 3c:77:e6:af:8c:54 and ssid "Acer Aspire V3-772G"
ap0: interface state UNINITIALIZED->ENABLED
ap0: AP-ENABLED
iw list
output:
root@CYBERDYNE-SYSTEMS:/home/cosmin# iw list
Wiphy phy0
max # scan SSIDs: 4
max scan IEs length: 2257 bytes
Retry short limit: 7
Retry long limit: 4
Coverage class: 0 (up to 0m)
Device supports RSN-IBSS.
Device supports AP-side u-APSD.
Device supports T-DLS.
Supported Ciphers:
* WEP40 (00-0f-ac:1)
* WEP104 (00-0f-ac:5)
* TKIP (00-0f-ac:2)
* CCMP (00-0f-ac:4)
* 00-0f-ac:10
* GCMP (00-0f-ac:8)
* 00-0f-ac:9
* CMAC (00-0f-ac:6)
* 00-0f-ac:13
* 00-0f-ac:11
* 00-0f-ac:12
Available Antennas: TX 0x3 RX 0x3
Configured Antennas: TX 0x3 RX 0x3
Supported interface modes:
* IBSS
* managed
* AP
* AP/VLAN
* WDS
* monitor
* mesh point
* P2P-client
* P2P-GO
Band 1:
Capabilities: 0x11ef
RX LDPC
HT20/HT40
SM Power Save disabled
RX HT20 SGI
RX HT40 SGI
TX STBC
RX STBC 1-stream
Max AMSDU length: 3839 bytes
DSSS/CCK HT40
Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
Minimum RX AMPDU time spacing: 8 usec (0x06)
HT TX/RX MCS rate indexes supported: 0-15
Bitrates (non-HT):
* 1.0 Mbps
* 2.0 Mbps (short preamble supported)
* 5.5 Mbps (short preamble supported)
* 11.0 Mbps (short preamble supported)
* 6.0 Mbps
* 9.0 Mbps
* 12.0 Mbps
* 18.0 Mbps
* 24.0 Mbps
* 36.0 Mbps
* 48.0 Mbps
* 54.0 Mbps
Frequencies:
* 2412 MHz [1] (16.0 dBm)
* 2417 MHz [2] (17.0 dBm)
* 2422 MHz [3] (17.0 dBm)
* 2427 MHz [4] (17.0 dBm)
* 2432 MHz [5] (17.0 dBm)
* 2437 MHz [6] (17.0 dBm)
* 2442 MHz [7] (17.0 dBm)
* 2447 MHz [8] (17.0 dBm)
* 2452 MHz [9] (17.0 dBm)
* 2457 MHz [10] (16.0 dBm)
* 2462 MHz [11] (17.0 dBm)
* 2467 MHz [12] (17.0 dBm) (no IR)
* 2472 MHz [13] (16.0 dBm) (no IR)
* 2484 MHz [14] (disabled)
Band 2:
Capabilities: 0x11ef
RX LDPC
HT20/HT40
SM Power Save disabled
RX HT20 SGI
RX HT40 SGI
TX STBC
RX STBC 1-stream
Max AMSDU length: 3839 bytes
DSSS/CCK HT40
Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
Minimum RX AMPDU time spacing: 8 usec (0x06)
HT TX/RX MCS rate indexes supported: 0-15
Bitrates (non-HT):
* 6.0 Mbps
* 9.0 Mbps
* 12.0 Mbps
* 18.0 Mbps
* 24.0 Mbps
* 36.0 Mbps
* 48.0 Mbps
* 54.0 Mbps
Frequencies:
* 5180 MHz [36] (15.0 dBm) (no IR)
* 5200 MHz [40] (15.0 dBm) (no IR)
* 5220 MHz [44] (15.0 dBm) (no IR)
* 5240 MHz [48] (15.0 dBm) (no IR)
* 5260 MHz [52] (17.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5280 MHz [56] (15.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5300 MHz [60] (15.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5320 MHz [64] (15.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5500 MHz [100] (16.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5520 MHz [104] (17.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5540 MHz [108] (17.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5560 MHz [112] (17.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5580 MHz [116] (17.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5600 MHz [120] (17.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5620 MHz [124] (17.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5640 MHz [128] (17.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5660 MHz [132] (17.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5680 MHz [136] (17.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5700 MHz [140] (16.0 dBm) (no IR, radar detection)
DFS state: usable (for 295 sec)
DFS CAC time: 0 ms
* 5745 MHz [149] (17.0 dBm) (no IR)
* 5765 MHz [153] (17.0 dBm) (no IR)
* 5785 MHz [157] (17.0 dBm) (no IR)
* 5805 MHz [161] (17.0 dBm) (no IR)
* 5825 MHz [165] (17.0 dBm) (no IR)
Supported commands:
* new_interface
* set_interface
* new_key
* start_ap
* new_station
* new_mpath
* set_mesh_config
* set_bss
* authenticate
* associate
* deauthenticate
* disassociate
* join_ibss
* join_mesh
* remain_on_channel
* set_tx_bitrate_mask
* frame
* frame_wait_cancel
* set_wiphy_netns
* set_channel
* set_wds_peer
* tdls_mgmt
* tdls_oper
* probe_client
* set_noack_map
* register_beacons
* start_p2p_device
* set_mcast_rate
* channel_switch
* Unknown command (104)
* connect
* disconnect
Supported TX frame types:
* IBSS: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* managed: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* AP: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* AP/VLAN: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* mesh point: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* P2P-client: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* P2P-GO: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* P2P-device: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
Supported RX frame types:
* IBSS: 0x40 0xb0 0xc0 0xd0
* managed: 0x40 0xd0
* AP: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
* AP/VLAN: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
* mesh point: 0xb0 0xc0 0xd0
* P2P-client: 0x40 0xd0
* P2P-GO: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
* P2P-device: 0x40 0xd0
software interface modes (can always be added):
* AP/VLAN
* monitor
valid interface combinations:
* #{ managed } <= 2048, #{ AP, mesh point } <= 8, #{ P2P-client, P2P-GO } <= 1,
total <= 2048, #channels <= 1, STA/AP BI must match
* #{ WDS } <= 2048,
total <= 2048, #channels <= 1, STA/AP BI must match
HT Capability overrides:
* MCS: ff ff ff ff ff ff ff ff ff ff
* maximum A-MSDU length
* supported channel width
* short GI for 40 MHz
* max A-MPDU length exponent
* min MPDU start spacing
Device supports TX status socket option.
Device supports HT-IBSS.
Device supports SAE with AUTHENTICATE command
Device supports low priority scan.
Device supports scan flush.
Device supports AP scan.
Device supports per-vif TX power setting
P2P GO supports CT window setting
Driver supports a userspace MPM
Device supports active monitor (which will ACK incoming frames)
Driver/device bandwidth changes during BSS lifetime (AP/GO mode)
iw dev
output:
root@CYBERDYNE-SYSTEMS:/home/cosmin# iw dev
phy#0
Interface ap0
ifindex 6
wdev 0x2
addr 3c:77:e6:af:8c:54
ssid Acer Aspire V3-772G
type AP
channel 1 (2412 MHz), width: 20 MHz (no HT), center1: 2412 MHz
Interface wlan0
ifindex 3
wdev 0x1
addr 3c:77:e6:af:8c:53
type managed
My phone is a Samsung Galaxy S2 (GT-I9100). I also tried with my roommate's Iphone 5, and it also doesn't work.
UPDATE: I have no idea what I have done. It works now! I don't now why! I didn't do a thing... Hmm, that is very weird... Thank you for your reply! I guess we can mark it problem solved? If it happens again, I will notify you :)
Maybe the channel had a lot of noise? If it happens again, try channel 6 and 11.
Hi! I have been using your script for a long time, worked flawlessly, but now, I am staying at a hostel, where I study for faculty, and I encounter a problem: the connection works fine after sharing the eth0 internet through WiFi, but after I connect my phone, for example, there is no working internet at all. I discovered a clue: when I use Connectify in Windows, it sends me a warning: "5GHz mode. Some devices might not be able to connect.". Will this be the problem in Linux? It does not support 5GHz mode sharing? What should I do to make it work?