-
Notifications
You must be signed in to change notification settings - Fork 5.1k
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
Number of wireless clients in AP mode is very limited #3010
Comments
Mhhh I meet the same problem ! Could be really useful to fix it ! |
I can connect only 9 devices with RPi 3B+ ... |
Seems like every time, before reaching the quota, there is like some kind undervoltage issue... Jul 28 20:49:07 dnsmasq-dhcp[896]: DHCPACK(ap0) 10.3.141.110 xx:xx:xx:xx:xx:xx HUAWEI_P9_lite I'm using a duracell power bank rated for 2.4A, with no peripherals other than a LAN cable |
@marcusdiy You should absolutely be certain to use a adequate power supply and cable before any testing, so that not under-voltage issue occurs in these testing. I'll edit my bug report to positively indicate that a limited number of clients occurs even when no under-voltage event occurs. Edit: though, thank you for the confirmation that under-voltage has an drastic effect on the number of wireless clients |
RPI is a very nice plateform for a lot of "boxes" (moodlebox, piratebox etc) so this resolution willy be very usefull... Thanks |
I were able to connect more than 20+ devices using ubuntu mate + snap wifi-ap |
Any news about this? I manage to get exactly 19 connections on a Rpi 3b and 14 connections on a Rpi 3b+ with the following hostapd conf on Raspbian Stretch:
I will soon proceed to new tests on Raspbian Buster. |
Both 43438 and 43455 are designed for "mobile or handheld wireless system[s]". As such, 19 and 14 sounds pretty good. I suspect they both have relatively small RAMs that also need to contain the firmware, so resources are going to be limited. |
any news about this? |
Some reports seem to indicate that the issue is worse on RPi 4 hardware, where max. number of wireless clients is sometimes less than 10! Ref: https://discuss.moodlebox.net/d/198-wifi-client-advice/6 |
Same results here, 8 devices connected with a Rapsberry Pi 4 on Buster... but same with a 3b+ |
In my case I have a Raspberry Pi 4, I have tried your same configuration for |
Same problem here on Raspi4. Hostapd worked well when testing with 2 clients back home, failed utterly when using it in school during my Web-Dev class... If there is any information I can provide to help solving this issue, pls let me know. |
I have also just encountered this issue with a Raspi4 (both 4 and 8 GB ram) using Buster. Can't get more than 7 other raspis to connect... Also, I don't know if this is pertinent, but it seems like power save mode is automatically enabled for the brcm wifi driver. I saw in earlier iterations that this may cause clients to get dropped? |
I am using Raspberry Pi 4 (1 GB Ram), and only able to connect 1 client to it... |
Hi, Same issue, no more than 8 devices connected in same time on Raspbian with RaspAP :(
Even if I can put some devices on sleep and wait events to wake up them, others devices need permanent connection (like the camera). Apparently people have successfully connected close to 20 devices (my target for the number of device connected in same time). Any idea/workaround to move forward ? because apparently this will not be fixed in 2020 ^^ Thanks and take care! |
I think there is no possibility of a "fix" - every change to the firmware (vulnerability patch, etc.) takes up more of the limited RAM, resulting in less space to host AP clients. If you really care about AP clients then you'll have to either use an old firmware or buy a USB dongle (which might give you higher performance as well). |
Can we please clarify, is this system RAM, or RAM specific to the chipset / wireless chip? I.E., having a Pi with 1 vs. 8 GB of RAM doesn't seem to make any difference here? |
The RAM on the WiFi part, into which the firmware is loaded, and which is also used for the running state of the device. |
@pelwell using a USB dongle is considering an alternative solution for me. Could you please share which USB dongle can handle more wifi clients, with brand and model specs? Thank you very much! UpdateI have an answer on StackExchange for the question Maximum Wi-Fi clients on Pi |
FYI, there is the reference at https://elinux.org/RPi_USB_Wi-Fi_Adapters . It would be nice to see included a number of supported WiFi clients, etc. - might be a good place to start. Would also be nice to have a cross-reference as to which support various features such as which wireless bands and WiFi versions are supported in AP mode, which support external antennas, etc. I previously had high hopes of using a "utility" Pi that I carry in my bag as a "can meet any need" device. Given these issues, I had to also include a separate "travel router" for serving as an AP. It easily serves 12+ WiFi clients, but the CPU was lacking for NAT + routing. I could use the 2 together, and use the travel router as just a "dumb AP", and then let the Pi do the rest of the networking - but it would be nice to consolidate this all together. I'm also interested in any specific product recommendations here. |
Yep, Since my message I've buyed the USB key BossTrend AC1200 based on the chipset RTL8812AU and now I've ~15 devices connected without issue. It works like a charm with the driver https://github.com/cilynx/rtl88x2bu.git.
If I've new I'll let you know there. Enjoy and take care. |
Got hit by that new limitation too. The maximum Wifi connection I've reached on a Pi4 is 7 as opposed to about 30 on a Pi3 18 months ago. I have no idea where and why that limitation got added but it's rendering the Pi pretty useless in my scenario. |
@guillain and @ericbeaudry - Could each of you please share which Pi and OS versions you are seeing your latest results with? |
Hi Ziesemer, |
@ericbeaudry says:
This leads to think there's indeed something wrong either in Pi4 hardware or in Raspberry Pi OS or drivers (which is the purpose of this issue). Humbly suggesting we stick to this, and talk about dongles elsewhere (e.g. on RPi forums). @ziesemer: I'm getting poor results with RPi4 since many versions of Raspberry Pi OS, and disappointing results with RPi 3B too (see #3010 (comment)). But I could not test on a large scale if the new wifi drivers shipped with last image (version 2020-12-02) have changed anything. I'd be glad to have some feedback about this. |
Daaamn, it is really working. Thank you very much, for sharing this, but in any case, i need to consider some better wifi-adapter, this will be fine as a temporary fix. Solution is not for production for sure. |
@pelwell Any idea how frequently that firmware is used? Since apt updates to the package will overwrite the user's changes, I was wondering whether it's worth adding and documenting a mechanism to switch between them properly (https://wiki.debian.org/DebianAlternatives). |
If there is a recognised way to support such user choices then that would be awesome - the priority was to get the firmware out there. |
Can I ask why you think this is not suitable for production? |
With a Raspberry Pi Zero W |
The Zero W is a different WLAN chip - less capable than the 43455, and not compatible with its firmware. |
You can set your goal as high as you like, but it's not achievable on what is essentially a 10 year old mobile phone class WLAN chip. |
Because it is not yet tested by me for some period of time. Time will show. :) |
Just to say: @pelwell, thank for 'cyfmac43455-sdio-minimal.bin'. Exactly what the doctor ordered. Grateful for that. We popped it in and will start testing today. |
btw, just to make this concrete for others searching: We ran into this bug recently as well with a slightly different manifestation, using a cm4. We're having the CM4 be both a wifi client and running hostapd. (1) If the chip is in station (STA) mode and connected to an AP, then only one client can connect to the CM4. Other clients are instantly rejected. (2) If the chip is in STA but searching for an AP - but not connected - then several clients can connect but they get transiently disconnected every minute or so as the chip tries again to find its AP to associate with. (3) If the chip is NOT in STA mode / not trying to associate, then several clients can connect. We have yet to try the minimized firmware mentioned above to see if it fixes either the disconnect behavior or allows more clients to connect while in station mode. But this may explain why a few people in this thread observed as little as 1 client able to connect to hostap. I hadn't seen (2) reported previously but I assume it's related to a lack of memory resources on the chip as well. |
@dave-andersen IIRC, STA and AP mode must use the same channel for AP+STA to work correctly. But I suppose you've already checked this. |
Yeah, we're pinning everything to ch1 for now, but I suspect the AP scanning is breaking clients transiently for the reason you note: It's almost certainly looking at all channels. |
Does anyone have any foresight into the possibility that the RPi 5 will be different that the RPi4 in this respect? Integral WiFi station limits on the RPi4 is so much lower than our market needs that we are testing USB dongles. If the RPi 5 is gonna be markedly better, that would be a big factor for us. |
I haven't received one to test with yet. However, combined with that neither the Pi 4 or 5 have an external antenna connector :-(, I've started to default to using USB dongles whenever I'm not otherwise cabled. |
The Pi 5 uses the same wireless chip as the Pi 4. |
Yes - the same chip and the same firmware(s), but the SDIO interface runs faster so you should be able to achieve a higher throughput. |
Thank you, gentlemen. We ship a portable module that can run on a power pack; people access it through WiFi. Sometimes a lot of people, even if not all at once. The integral wireless has been relegated to being an "admin" port and we use a USB dongle to deliver user services. It sounds like it will stay that way. |
@briantbutton Could you share the model of your USB wifi dongle? |
@martignoni it would be my pleasure. In fact, I posted the larger journey here: morrownr/USB-WiFi#296 The larger repo has tons of information about USB dongles and drivers, and maintains some drivers. Invaluable really. The chipset underlying is really the keys thing that determines functionality and driver compatibility. https://github.com/morrownr/USB-WiFi holds tables that disclose what chipsets go with what models of adapter. You should be able to find all you need there. |
Thank you, much appreciated. I've already read thoroughly https://github.com/morrownr/USB-WiFi, but your "journey" will be very helpful. |
Glad to hear. The adapter we tested with, that gave good results was the Alpha AWUS036AC. I liked it because we wanted range and it emphasized range. We got the driver off morrownr and it has worked fine and the range is very good. Ages ago, antenna diversity was emphasized to me. It has two antenna. |
I'm reporting this on Jamesh's advice (see this forum discussion).
Describe the bug
On RPi 3B+, on can expect an optimistic max. of 20-30 devices connected simultaneously via Wi-Fi, even when no under-voltage event occurs.
To reproduce
Use case: the RPi serves as a wifi AP and a web server, that's all. No user is logged in the RPi in production use. An official Raspberry Foundation power supply and cable is used, so that no under-voltage event occurs.
Nginx and php-fpm are optimized so that memory is not a problem. Flooding the web server using ApacheBench shows that memory is not a problem: available memory remains at around 600M at any time, even with 100 concurrent http requests! Swap is never used.
The limitation experienced is uniquely caused by concurrent wifi connections to the AP (hostapd). For that reason, I'm suspecting it's a wifi driver issue.
Expected behaviour
More client devices than a mere 20 can be simultaneously connected to the RPi in AP mode.
Actual behaviour
When about 20 devices are connected to the RPi in AP mode, the RPi freezes.
System
Logs
Not applicable.
Additional context
This is the content of my
/etc/hostapd/hostapd.conf
:The text was updated successfully, but these errors were encountered: