-
Notifications
You must be signed in to change notification settings - Fork 5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hostapd + 4.19.40 + Edimax EW-7811Un fails to accept client connections #2979
Comments
Do you have a console connection, I’m seeing a segfault. I didn’t have time to go any further. |
Post the segfault. |
Sorry meant a kernel panic.....im a bit tired, fighting a cold. I'll have to setup a serial console to be able to capture it....or take a picture. Will do it when I can, just didn't know if were seeing the same thing. |
Thanks @paul-1. I don't have any way to do a serial connection to capture a crash but I was able to get what appears to be the last part of it using a 3B with a 7" Touch. It happens exactly when the client connects to the AP. |
You should be able add pause_on_oops=xx to cmdline.txt (Where xx is number of seconds to pause) That will keep the top of the oops from scrolling off the screen. |
Ok, I'll try in a bit. |
Try adding "framebuffer_height=2160” to config.txt - you may get the whole report on screen at once. |
Gave it a try but there was still scrolling past the top. I'd guess maybe 2-3 pages. |
Raspberry 2Bv1.2 with hostapd running crash when client tries to connect to hostapd [ 216.702035] ------------[ cut here ]------------ |
same to kernel: Linux xxxxx 4.19.46-v7+ #1230 SMP Tue May 28 16:18:48 BST 2019 armv7l GNU/Linux [ 72.158114] ------------[ cut here ]------------ |
I believe issue is more related to driver rather than operating system |
Yes, most probably a driver/hostapd combination issue than kernel. 8192cu had problematic driver version(s) and may need customized version of Also, "regular" |
@klimchuk - I would tend to agree that the issue is in the driver given that kernel panic occurs in 4.19 and no issues in 4.14. Same version of Raspbian, hostapd and hostapd config. @macmpi - I've not experienced any issues with hostapd, 8192cu and cfg80211 over the years. It's only since the 4.19 branch that connection attempts to the AP cause kernel crash. |
@moodeaudio - Looking @ first post, it occurs you are running Raspbian Stretch Lite: so it's very likely So, I advise you try on stock Buster distribution first. If it works and you still need to use Stretch, then try to get |
Yes, our project has built hostapd from sources since v2.4 as I recall. I've included the build recipe and hostapd.conf. The 2.7 binary that was compiled on Stretch works fine in Buster but we also experience same kernel crash on connection attempt when using Edimax adapter. This is with 4.19.56 kernel. @jan-h-1970 posted two complete crash dumps so I think it's just a matter of someone with enough experience analyzing them, isolating the issue and hopefully determining root cause. If there is anything that should be adjusted in the build recipe or config I'll be happy to test.
|
I meant: can you please get Raspbian Lite Buster image, and try with your FWIW, Buster version is not plain 2.7: you may want to get hostapd (2:2.7+git20190128+0c1e29f-6) sources, assuming that's the one that Raspbian ships. (or try 2.8 if that one does not work) |
Do you know what wold be different in Buster hostapd? I just tested the Buster hostapd package and it exhibits the exact same symptoms when trying to connect to AP using Edimax adapter, the Pi hangs (kernel crashes). No issues with Pi integrated adapter. Here is the version installed by the package.
|
And from baseline Raspbian Lite Buster image ? |
pi@rp2:~ $ cat /etc/rpi-issue pi@rp2:~ $ vcgencmd version pi@rp2:~ $ uname -a |
What if AP security is disabled (WPA2)? |
Sorry for asking the obvious, but I assume you blacklisted |
I see the same issue as @moodeaudio , I also tried disabling the security, and the same kernel fault occurs.. |
Where to look for blacklisting? |
See |
what I am seeing is this:, which I assume means that the 8192 is blacklisted??, pi@raspberrypi:~ $ cd /etc/modprobe.d/ |
Thx, confirmed the file is present
|
As a side note, my hw guy here had an alternative LM811 wifi module, which I just compiled the driver for, and it works just fine with the 6/20 raspbian lie. . .https://github.com/lwfinger/rtl8723bu ... uses the rtl8723bu... we are most likley going to move forward with that.. |
I can confirm the kernel crash comes still with raspbian buster lite (2019-06-20), it's independent of HW, I tested 2Bv1.2, 3B, 3B+.
same with the latest kernel:
error is the same at all ... kernel BUG at mm/slub.c:3904! ... I can send another kernel crash dump output if it's helpful. |
Still broken with:
|
Still broken in 4.19.69 and 4.19.71 . |
I had the same problem ... deleting the blacklisting-file /etc/modprobe.d/blacklist-rtl8192cu.conf did the job for my installation ... now the hostapd runs perfectly ... |
Your fix also works for me. I did notice though that the driver no longer supports scanning while running with hostapd. Scan works fine however when the adapter is connected to WiFi Router. Very odd.
|
Hi, |
Using a model B+ Rev 1.2 with Realtek RTL8188CUS and deleting /etc/modprobe.d/blacklist-rtl8192cu.conf worked wonderfully for me. Appreciate the info and work above. |
Hi, i will share my setup in order to help to solve the issue in case of... Rapsberry = RP1
Station 14:9f:3c:e3:98:23 (on wlan0) Sergio |
Exact same issue and solution here (Raspberry 1 Model B + TP-Link TL-WN823N V2) Thanks @DannyMTK ! |
I'm still unable to connect to the AP, even after fiddling with the blacklist. Just me? Kernel 4.19.75 Where is the log where people are seeing the kernel panic? Is it the logs seen when running hostapd in debugging mode? |
Hi there, I've recently been trying to use this to make an up to date tutorial for setting these adaptors up on Raspbian (https://www.hamishmb.com/blog/how-to-make-a-raspi-ap-with-a-rtl8xxx-wifi-adaptor/) but I get a kernel panic as soon as anything connects to the AP. Is this a resolved/known issue or anything? I might well be doing something wrong so if you have any advice please let me know :) |
@hamishmb Have you tried setting |
Interesting, what chipset and kernel version was this with? |
since 4.4.13 for 8192cu as per this and referred details. |
Causes a kernel panic for me when I try to connect, much like with the modified hostapd :/ NOTE: I'm using RTL8188CUS if that makes any difference. |
@hamishmb did you ever get this working? Came across your blog while trying to get mine setup. Tried multiple different patches of hostapd, followed numerous different tutorials but can't get anything working on the Edimax-7811UN. I am currently using the latest version of Raspbian. Tempted to try downgrading to a 5yr old one just to see if it makes a difference. |
Nope, never managed to get it working or complete that post, unfortunately. I did once having it working on Raspbian Wheezy I think, so I guess it must not work with newer kernels of something. Unfortunately I'm not sure exactly what I did back then. I'm not even sure if the repos are still up for older versions to be honest, maybe there's something like old-releases.ubuntu.com but for Raspbian. |
FYI, I just fixed the kernel panic on connection, which seems to have started with kernel >=4.18. If anyone is interested in testing it you can build the module for here: https://github.com/ktp420/rtl8192cu-fixes/tree/fix_ap_crash |
I'd love to try it, but sods law happened: I let someone borrow the relevant WiFi dongle and they broke it. My replacement doesn't use a Realtek chipset (it uses a Ralink RT5370 IIRC), but I'll have a shot at fixing the old one soon probably. If I get it working, I'll definitely try this out. |
Describe the bug
Kernel 4.19.40 + Pi-2B + Edimax EW-7811Un adapter results in hostapd failing to accept client connections. The error message on the client is "Incorrect password". Reverting to 4.14.98 kernel and no issues.
To reproduce
https://github.com/moode-player/moode/releases/download/r52prod-fix/moode-r52.zip
sudo sed -i "/AP mode/,/$p/ d" /etc/dhcpcd.conf
sudo sed -i "$ a#AP mode\ninterface wlan0\nstatic ip_address=172.24.1.1/24\nnohook wpa_supplicant" /etc/dhcpcd.conf
sudo systemctl daemon-reload
sudo systemctl restart dhcpcd
sudo systemctl start hostapd
sudo systemctl start dnsmasq
a. ifconfig (verify that 172.24.1.1 address assigned to wlan0)
b. On a client device for example an iPhone verify that SSID Moode appears in the list of available WiFi networks
sudo systemctl stop hostapd
sudo hostapd -d /etc/hostapd/hostapd.conf
Expected behaviour
iPhone client is able to successfully connect to AP SSID = Moode using password = moodeaudio. Sometimes 2 attempts are required.
Actual behaviour
iPhone client receives error message "Incorrect password". Any number of repeated attempts to connect to AP SSID using the correct password result in the same error message. This also appears to hang the network interfaces and the Pi must be power-down rebooted.
System
Pi-2B
cat /etc/rpi-issue
)?Raspbian Stretch Lite
pi@rp6:~ $ cat /etc/rpi-issue
Raspberry Pi reference 2018-11-13
Generated using pi-gen, https://github.com/RPi-Distro/pi-gen, 7e0c786c641ba15990b5662f092c106beed40c9f, stage2
vcgencmd version
)?pi@rp6:~ $ vcgencmd version
Mar 27 2019 15:45:53
Copyright (c) 2012 Broadcom
version 2e98b31d18547962e564bdf88e57b3df7085c29b (clean) (release) (start)
uname -a
)?pi@rp6:~ $ uname -a
Linux rp6 4.19.40-v7+ rpi2 running omxplayer repeatedly ok on linux-4.2.6 but hangs on linux-4.4.0-rc3 #1217 SMP Tue May 7 17:22:08 BST 2019 armv7l GNU/Linux
Logs
Logs and additional information on the issue are in moOde Support Forum thread
http://moodeaudio.org/forum/showthread.php?tid=1399&pid=10581#pid10581
The text was updated successfully, but these errors were encountered: