Geolocation causes ping spikes in LAN until Firefox is closed
Categories
(Core :: DOM: Geolocation, enhancement, P3)
Tracking
()
People
(Reporter: chronos1970, Unassigned, NeedInfo)
References
Details
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Firefox/78.0
Steps to reproduce:
Platform: Windows 10, 20H2
Internet connected through WIFI
Tried on a clean Firefox profile
- Start ping monitoring in terminal (ping 192.168.1.1 -t)
- Visit maps.google.com (or any other site using location)
- Allow access to location
Actual results:
Ping starts spiking intermittently (from 1 ms up to 3000 ms) until all Firefox processes are closed (even if the Google Maps tab is closed)
Expected results:
Ping should not have been affected this much, and shouldn't persist even if location is no longer needed.
I assume this due to a continuous WIFI scanning of nearby networks.
Updated•4 years ago
|
Reporter | ||
Comment 1•4 years ago
|
||
PS: Tested Microsoft Edge (Chromium), and it doesn't have any issues.
I've noticed that this bug has been reported here and around the internet several times:
- Invoking Geolocation API causes system-wide packet delays (https://bugzilla.mozilla.org/show_bug.cgi?id=1516103)
- Firefox location service causing Internet connection intermittent. (https://bugzilla.mozilla.org/show_bug.cgi?id=1658449)
- Location API causing frequent system-wide disconnects (even when not used anymore) (https://bugzilla.mozilla.org/show_bug.cgi?id=1652303)
- Latest version of Firefox causes intermittent lag spikes (https://support.mozilla.org/en-US/questions/1286612)
- Narrows the bug to a weather extension
- Firefox open causing ping spikes (https://www.reddit.com/r/firefox/comments/g1sdh1/firefox_open_causing_ping_spikes/)
I hope this gets resolved soon, and thanks for your time.
Updated•4 years ago
|
Comment 2•4 years ago
|
||
I'm also encountering this issue as well: Windows 10, 91.0.2 (64-bit). It can almost always be immediately triggered by visiting Google Maps. Ping will spike from 10ms to about 25000ms almost exactly every 10 seconds until Firefox has been closed. Upon reopening everything is fine and dandy.
Comment 3•3 years ago
|
||
Also having this issue for a while on my laptop. Only now found that this is related to geolocation but requesting geolocation indeed reproduces it.
For me it makes 2-3 pings be 200-300ms instead of normal 10-20ms. Very frustrating issue but I guess I would try to avoid geolocation requests or reload firefox instantly after doing one.
I have had this problem for years but have just found the cause to be geolocation service recently.
Closing the tabs that use geolocation (or closing all tabs) does not solve the symptom but restarting firefox helps. However, if I use any website that uses geolocation again after restarting, the symptom keeps coming back.
I am on a PC using an on-board WIFI.
Edition Windows 10 Pro
Version 21H2
I have tried using FF dev edition, using both clean profile and my original FF profile and I encountered the same problem.
Comment 5•3 years ago
|
||
Found this bug as well.
OS: Windows 10 Education, Version 1909, 18363.2274
Firefox version 100.0 (64-bit)
WLAN adapter: Realtek 8812BU Wireless LAN 802.11ac
The ping spikes are extremely regular.
Comment 6•2 years ago
|
||
This bug is now affecting me without even geolocating, all I have to do is open Firefox, instant and endless lag spikes 10s+. If this isn't going to be addressed then time to switch to Chrome.
I've had this bug for years and only now found the link to location request. Like many here, I would find that sometimes my ping would randomly spike up at intervals (e.g. a few seconds every 10 seconds), and that closing Firefox would make the issue go away. But now I know that this is 100% because of location requests. If I open some sites and don't grant location permission, everything is fine. As soon as I grant location permission, within a few seconds the ping would go up and the issue wouldn't go away until restarting Firefox.
Windows 10 22H2
Firefox 107
TP-Link Archer T2U Plus Wifi Adapter
Reporter | ||
Comment 8•2 years ago
|
||
(In reply to fennecbutt from comment #6)
This bug is now affecting me without even geolocating, all I have to do is open Firefox, instant and endless lag spikes 10s+. If this isn't going to be addressed then time to switch to Chrome.
It could be an extension or a home page trying to use geolocation. In my case it was Nextcloud's home page. It's unfortunate that this bug hasn't yet received any developer attention. The main problem is how hard it's to diagnose. I just turn off geolocation on all Firefox instances now.
As of Firefox 107.0.1, I would like to inform that this bug magically disappeared, at least for me and on this particular PC. Same machine, same OS, same windows user, same Firefox user profile and plug-ins.
Either Firefox dev team did something or some windows update fix this for me.
Anyway, I no longer need to open Chrome to use Google Map anymore.
Comment 10•2 years ago
|
||
(In reply to nattee from comment #9)
As of Firefox 107.0.1, I would like to inform that this bug magically disappeared, at least for me and on this particular PC. Same machine, same OS, same windows user, same Firefox user profile and plug-ins.
Either Firefox dev team did something or some windows update fix this for me.
Anyway, I no longer need to open Chrome to use Google Map anymore.
Sorry, I think I made a mistake. The problem is still there. It is just that google map does not really use the geolocation as often as I think. If I force google map to use the geolocation (in a way that Firefox asks for my permission), the problem suddenly appears.
Comment 11•2 years ago
|
||
can confirm this happens to me too
never had this problem until I let google maps use firefox's location
problem still persists despite setting geo.enabled = false in about:config
the only way to resolve this is to restart the browser
any attempts in using geolocation will results in ping spikes again
Comment 12•2 years ago
|
||
I think I have found the culprit. I believe the problem is my Wi-Fi which is Realtek 8822BE. I bought a new Wi-Fi PCI-e card using Intel AX210. When I connect the Wi-Fi using AX210, there is no problem even I use the geolocation.
I have both Wi-Fi card enabled but the ping spike problem only happen when I use geolocation while connecting with Realtek 8822BE. If I switch my connection between Intel AX210 and Realtek 8822BE back and forth , the problem happens only with 8822BE. Of course, closing Firefox still stops the problem.
So, I will stick with my AX210 for now.
Can anyone with the problem confirm the connecting network card when the problem happen please?
Reporter | ||
Comment 13•2 years ago
|
||
(In reply to nattee from comment #12)
I think I have found the culprit. I believe the problem is my Wi-Fi which is Realtek 8822BE. I bought a new Wi-Fi PCI-e card using Intel AX210. When I connect the Wi-Fi using AX210, there is no problem even I use the geolocation.
I have both Wi-Fi card enabled but the ping spike problem only happen when I use geolocation while connecting with Realtek 8822BE. If I switch my connection between Intel AX210 and Realtek 8822BE back and forth , the problem happens only with 8822BE. Of course, closing Firefox still stops the problem.
So, I will stick with my AX210 for now.
Can anyone with the problem confirm the connecting network card when the problem happen please?
I can reproduce the problem with the rtl8814au chipset. Moreover, the issue doesn't appear on chromium browsers.
Comment 14•2 years ago
|
||
I have similar problem with Realtek RTL8852BE WiFi 6 802.11ax PCIe Adapter. And the problem occurs only when I am connected over WiFi, over wired connection everything is alright.
I have assumption about nature of the problem:
- Geolocation in Windows causes ping spikes. For example, when you open Maps application and try to detect your current location, ping spike can occur. Similar with Edge and https://www.google.com/maps
- Firefox for some reason starts to use geolocation every 5-10 seconds, which lead to periodical ping spikes due to 1).
Comment 15•2 years ago
•
|
||
Hello everyone, and thank you for your reports. There has been some progress recently on a probably duplicate bug 1810421, see here and there. While we'll be working on fixing this, it would help us a lot if you can confirm the following:
- Do you have Location Services set to Off in Windows?
- Do you have
geo.enabled
set totrue
if you navigate toabout:config
in Firefox? - Does setting
geo.enabled
tofalse
and restarting the browser fix the issue? - Same question with setting
geo.enabled
totrue
, butgeo.provider.network.scan
tofalse
, and restarting? - (Open question) Do you expect that geo location should continue to work in Firefox when Location Services are Off in Windows, by using Firefox's own geo location services as a fallback?
Our current hypothesis is that:
- You are using location services in Firefox but the Microsoft provider is unavailable because Location Services are Off in Windows.
- So Firefox falls back to using its own location services, which includes periodic scans of nearby Wi-Fi APs, currently every 5 seconds.
- Some network cards are unable to service regular network activity during scans.
Aside from fixing this, we wonder whether we should propagate the user's choice in Windows configuration to Firefox when they disable Location Services, and not use a fallback in that case.
(Edit: more context and questions)
Comment 16•2 years ago
|
||
Hello! In my case the answers are:
- Status of Location Services in Widows 11 doesn't matter. Firefox somehow is able to update my location with Location Services Off
- I have
geo.enabled
set totrue
- Yes, setting
geo.enabled
tofalse
helps. However, geo location stops working
My algorithm to reproduce the problem is as follows.
Prerequisites:
- Be connected over WiFi
- Have
geo.enabled
set totrue
(other geo parameters seems to be at their default as well) - Have cmd with
ping -t <router IP>
running in the background for lag spikes detection
Actions:
- Open tab with https://www.google.com/maps
- Forcefully update you current location. It can be done by hovering mouse cursor over a location icon in the left-bottom of the page and pressing
Update
in a pop-up that appears. - Lag spikes start to appear in cmd every 5-10 seconds. The tab with Google Maps can be closed, it doesn't matter at this point. The lag spikes continue even after closing the tab and they persist until Firefox is restarted.
Comment 17•2 years ago
|
||
Setting geo.provider.network.scan
to false
as was recommended in 1810421 helps as well.
Comment 18•2 years ago
|
||
(In reply to NoneDark from comment #16)
- Status of Location Services in Widows 11 doesn't matter. Firefox somehow is able to update my location with Location Services Off
It seems I made a mistake. The problem only appears with Location Services turned off.
Comment 19•2 years ago
|
||
geo.enabled
to false
solve the problem but the location service is not available. Please see my detailed update at https://bugzilla.mozilla.org/show_bug.cgi?id=1810421#c43
Comment 20•2 years ago
|
||
Thanks, I updated comment 15 with more context and questions based on your answers.
Comment 21•2 years ago
|
||
In case there is still any question, I can reproduce this and can confirm that the value mentioned in bug 1810421 comment 41 ( kDefaultWifiScanInterval ) controls this failure. Changing it from 5 seconds to 60 results in hanging every 60 seconds, for the same amount of time (2 - 3 seconds).
Updated•2 years ago
|
Description
•