You are not logged in.
Hi,
as the title says, I'm trying to create a Wifi-Hotspot with NetworkManager. I don't have a wireless router, so I use a Belkin Usb-Stick (F7D1101 v1).
nordlicht@Aegis:~ $ lsusb -v
Bus 001 Device 004: ID 050d:945a Belkin Components F7D1101 v1 Basic Wireless Adapter [Realtek RTL8188SU]
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 0
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x050d Belkin Components
idProduct 0x945a F7D1101 v1 Basic Wireless Adapter [Realtek RTL8188SU]
When I try to create a Hotspot with nm-applet, there appears no wizard (it should?) and I get a WEP-secured Network with my Hostname and a predefined password, but I am not able to connect with it. It shows up in my Android device, but when I try to connect with it (after entering the pw), nothing happens, the Hotspot dissapears after some seconds and I am not able to disable the hotspot within NM. I turn it off, but the slider automatically goes back to "on".
Because I try this for days now and because I'm not really into networking-stuff, I now feel ok with aksing for some help here.
Offline
as much as I remember networkmanager creates adhoc type hotspot by default, android requires infrastructure type hotspot, look this links for help
http://ubuntuhandbook.org/index.php/201 … ot-ubuntu/
https://aur.archlinux.org/packages/create_ap/ (there is forum post for this aur package with instruction, just search)
first link is guide to setup hotspot with network-manager, second is an aur package to easily create wifi-hotspot, you can use whichever suits you
EDIT:
link to create_ap forum post https://bbs.archlinux.org/viewtopic.php?id=162895
Last edited by Docbroke (2016-02-27 02:24:01)
Arch is home!
https://github.com/Docbroke
Offline
Tried the first method, but still without luck.
/etc/NetworkManager/system-connections/Hotspot:
[connection]
id=Hostspot
uuid=7ffcb38e-eb8d-4f0f-a199-bdaf022395d3
type=wifi
interface-name=wlp0s20u5
permissions=
secondaries=
[wifi]
band=bg
mac-address=EC:1A:59:52:95:D2
mac-address-blacklist=
mode=ap
seen-bssids=
ssid=Hotspot
[wifi-security]
group=
key-mgmt=wpa-psk
pairwise=
proto=
psk=XXXXXXXX
[ipv4]
dns-search=
method=shared
[ipv6]
dns-search=
ip6-privacy=0
method=ignore
Restarted NM, tried to activate the Hotspot, but now nothing happens at all, means: the hotspot isn't activated at all. What am I doing wrong?
Last edited by Thorsten Reinbold (2016-02-26 14:07:46)
Offline
this method used to work, however I am not using it now as I am no longer using networkmanager, so I use the second method, however if you have followed all the steps exactly it should be working. Also I presume you are not connected to wifi before while creating hotspot.
Arch is home!
https://github.com/Docbroke
Offline
Yes, you're right. I've tried the method with create_ap now (after removing the changes to NM made before and set the WLAN-device on NM's blacklist).
This came out:
[nordlicht@Aegis:~ $ sudo create_ap wlp0s20u7 enp0s25 MyAccesspoint XXXXXXXX
WARN: Your adapter does not fully support AP virtual interface, enabling --no-virt
Config dir: /tmp/create_ap.wlp0s20u7.conf.DIUzatKK
PID: 1316
Sharing Internet using method: nat
hostapd command-line interface: hostapd_cli -p /tmp/create_ap.wlp0s20u7.conf.DIUzatKK/hostapd_ctrl
Configuration file: /tmp/create_ap.wlp0s20u7.conf.DIUzatKK/hostapd.conf
Low entropy detected, starting haveged
nl80211: Driver does not support authentication/association or connect commands
nl80211: deinit ifname=wlp0s20u7 disabled_11b_rates=0
nl80211 driver initialization failed.
wlp0s20u7: interface state UNINITIALIZED->DISABLED
wlp0s20u7: AP-DISABLED
hostapd_free_hapd_data: Interface wlp0s20u7 wasn't started
Error: Failed to run hostapd, maybe a program is interfering.
If an error like 'n80211: Could not configure driver mode' was thrown
try running the following before starting create_ap:
nmcli r wifi off
rfkill unblock wlan
Doing cleanup.. done
Last edited by Thorsten Reinbold (2016-02-26 23:30:07)
Offline
This is really driving me nuts. I have to admit: networks in all ways are a blind spot to me. I'm confused by all the different stuff there. NetworkManager, systemd, dnsmasq, iwconfig, wpa_supplicant, etc.pp.
But it seems as if the Stick is not the problem, at least. With Windows it is possible to create a usable AP with it. But that's of course not what I intend to use.
According to the error messages above: Is it possible that the driver is incorrect?
Last edited by Thorsten Reinbold (2016-02-26 23:29:15)
Offline
Let's see from beginning.
1. Were you able to connect to wifi using networkmanager?
2. Did you disable NetworkManager.service before starting create_ap, as wifi may be controlled by networkmanger causing interference.
My guess is you are trying to share your ethernet connection which is connected by networkmanager, so before disabling networkmanager, you will have to created alternate connection method.
try below to see if this works
sudo systemctl stop NetworkManager
dhcpcd enp0s25
if you are able to connect with your ethernet
sudo systemctl disable NetworkManager
sudo systemctl enable dhcpcd@enp0s25
followed by your create_ap command.
EDIT:
my be I missed simple thing,
just try nmcli r wifi off and rfkill unblock wlan as suggested by create_ap in your posted output and try again.
Last edited by Docbroke (2016-02-27 01:43:11)
Arch is home!
https://github.com/Docbroke
Offline
As Docbroke said, android doesn't support ad hoc connections. I was able to work around that by setting up my computer with a combo of hostapd/dnsmasq. Haven't quite gotten it to work in Arch yet, so I'm still researching the topic. It works just fine in Ubuntu though, maybe I'm just missing something.
My modified scripts/config files for Arch,
A tutorial I wrote on this subject on the Ubuntu forums
Offline
@Docbroke:
1. Yes.
2. Yes.
After your suggestions, I get the following:
[nordlicht@Aegis:~ $ sudo create_ap wlp0s20u8 enp0s25 ArchShare
WARN: Your adapter does not fully support AP virtual interface, enabling --no-virt
Config dir: /tmp/create_ap.wlp0s20u8.conf.pjBVintf
PID: 1396
Network Manager found, set wlp0s20u8 as unmanaged device... DONE
Sharing Internet using method: nat
hostapd command-line interface: hostapd_cli -p /tmp/create_ap.wlp0s20u8.conf.pjBVintf/hostapd_ctrl
Low entropy detected, starting haveged
Configuration file: /tmp/create_ap.wlp0s20u8.conf.pjBVintf/hostapd.conf
nl80211: Driver does not support authentication/association or connect commands
nl80211: deinit ifname=wlp0s20u8 disabled_11b_rates=0
nl80211 driver initialization failed.
wlp0s20u8: interface state UNINITIALIZED->DISABLED
wlp0s20u8: AP-DISABLED
hostapd_free_hapd_data: Interface wlp0s20u8 wasn't started
Error: Failed to run hostapd, maybe a program is interfering.
Doing cleanup.. done
Funny: iwconfig gives me this
wlp0s20u8 unassociated Nickname:"rtl_wifi"
Mode:Managed Access Point: Not-Associated Sensitivity:0/0
Retry:off RTS thr:off Fragment thr:off
Power Management:off
Link Quality:0 Signal level:0 Noise level:0
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:0 Invalid misc:0 Missed beacon:0
and 'iwlist wlp0s20u8 scan' shows ma all available networks.
@Branau: Adhoc isn't the problem at this point. The point is that I'm unable to create a hotspot at all.
Offline