Reboot loop due to WifiStateMachine bug in stock 5.0.1 update (i9500, Note 3 SM-N900) - Galaxy S 4 Q&A, Help & Troubleshooting

A WiFi-related bug in Samsung's recent 5.0.1 Lollipop update causes devices to go into a continuous reboot loop (rebooting every 1-1.5 minutes) after certain conditions.
Known affected devices:
Samsung Galaxy S4 International (GT-i9500) on Android 5.0.1
Samsung Galaxy Note 3 International (SM-N900) on Android 5.0.1
If the device comes in range of an open wireless network with blank/no SSID, it attempts to connect to it. This adds the network to the list of known/configured networks with the network name being null. The next time WiFi is enabled (either through manual switching or a reboot), the WifiStateMachine goes through the list of configured networks as usual, checking each one. A String .equals() method is called on the name of each network, so upon reaching the null network the following fatal NullPointerException is caused, rebooting the device:
HTML:
I/WifiConfigStore(13460): null is a captive portal!
I/WifiConfigStore(13460): not authenticated yet
E/WifiConfigStore(13460): Not a HS20
E/WifiConfigStore(13460): Not a HS20
E/AndroidRuntime(13460): *** FATAL EXCEPTION IN SYSTEM PROCESS: WifiStateMachine
E/AndroidRuntime(13460): java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.equals(java.lang.Object)' on a null object reference
E/AndroidRuntime(13460): at com.android.server.wifi.WifiConfigStore.readNetworkVariablesFromSupplicantFile(WifiConfigStore.java:2079)
E/AndroidRuntime(13460): at com.android.server.wifi.WifiConfigStore.readNetworkVariableFromSupplicantFile(WifiConfigStore.java:2109)
E/AndroidRuntime(13460): at com.android.server.wifi.WifiConfigStore.loadConfiguredNetworks(WifiConfigStore.java:1940)
E/AndroidRuntime(13460): at com.android.server.wifi.WifiConfigStore.loadAndEnableAllNetworks(WifiConfigStore.java:586)
E/AndroidRuntime(13460): at com.android.server.wifi.WifiStateMachine$SupplicantStartingState.processMessage(WifiStateMachine.java:7341)
E/AndroidRuntime(13460): at com.android.internal.util.StateMachine$SmHandler.processMsg(StateMachine.java:966)
E/AndroidRuntime(13460): at com.android.internal.util.StateMachine$SmHandler.handleMessage(StateMachine.java:789)
E/AndroidRuntime(13460): at android.os.Handler.dispatchMessage(Handler.java:102)
E/AndroidRuntime(13460): at android.os.Looper.loop(Looper.java:145)
E/AndroidRuntime(13460): at android.os.HandlerThread.run(HandlerThread.java:61)
Solutions:
Enable Airplane Mode: reboot loop will end after next reboot as WifiStateMachine does not check networks if WiFi is off at boot
Factory reset: the list of configured networks is cleared, so the error-causing network is removed
The ideal workaround would be to delete the error-causing network (or all configured networks) without a factory reset, but networks can only be removed the normal way when WiFi is on and removing them from the shell requires root access (to delete a system file).
I have not been able to find a way to report this to Samsung.
EDIT 1: It looks like this bug only applies to null networks that have captive portals/require browser sign-in.

Hey,
I've got this bug on the S6 edge too
Since I'm rooted, maybe I can fix it without factory reset??
I reported this but here :
http://forum.xda-developers.com/showthread.php?t=3131416
[Q] Some "Null" Wifi puts phone into loop reboots

kaemon said:
Hey,
I've got this bug on the S6 edge too
Since I'm rooted, maybe I can fix it without factory reset??
I reported this but here :
http://forum.xda-developers.com/showthread.php?t=3131416
[Q] Some "Null" Wifi puts phone into loop reboots
Click to expand...
Click to collapse
If you're rooted, a possible solution might be to remove the null network from the wpa_supplicant.conf file. I'm not sure where it is located, possibly /data/misc/wifi/wpa_supplicant.conf

I don't think there is a real 'null' wifi anywhere...
Anyway, I managed to fix my problem thanks to application on the market, see this post : http://forum.xda-developers.com/showthread.php?p=60349787
Sent from my SM-G925F using XDA Free mobile app

For me it wasn't `wpa_supplicant.conf` that was causing the problem, it was
`/data/misc/wifi/networkHistory.txt`
I deleted this file and my tablet returned back to normal

Related

[Q] NJ4 WiFi Issues

I manually upgraded my i337 from NB1 (4.4.2) to NJ4 (4.4.4), and then I re-rooted it. While I noted minor differences between the versions (I now had the "Custom Unlocked" logo on the splash screen, for example, and the notification "shade" did not scroll off and on as quickly), the most problematic issue was WiFi connectivity, which caused me to reinstall NB1 (pending a solution).
With NB1, my WiFi worked as I thought it should. It would automatically re-connect to hot spots and, if there is a password, it would automatically handle it for those sites I had logged into previously. Thus, for example, my phone would automatically log into my home WiFi router as soon as I walked through the door.
It appears that NJ4 is broken. I have found that under NJ4, the WiFi will only *automatically* re-connect to the most recently-used hotspot (whether or not passworded). This is not affected by restarting either the phone or the router. Thus, if I connect to my home router, the phone will re-connect effortlessly PROVIDED I don't connect to any other hotspot. If I have connected to another hotspot, once I return home, I find that there is no longer an automatic connection (I receive a "WiFi Hotspots are Available" notification), and once I initiate the connection manually, I am asked for my password EVERY TIME. At least I know my home password; I don't know the passwords of the many other hotspots I have connected to.
The collected WiFi credentials are maintained in the file data/misc/wifi/wpa_supplicant.conf. I looked at that file to see whether the passwords had been deleted. No, they were all still there (albeit encrypted). Here is an entry like the one for my home router:
network={
ssid="SqueekyNet"
psk=[the encrypted p/w is located here]
key_mgmt=WPA-PSK
priority=657
frequency=2462
disabled=1
autojoin=1
usable_internet=0
skip_internet_check=0
}
Note the line that says "disabled". The system inserts this line once you log into a *different* hotspot. It does this for *every* entry, so the only entry without this line will be the one for the current hotspot (or for the most recent one, if you aren't logged in to any WiFi hotspot).
I have found that if I edit the wpa_supplicant.conf file on-the-fly ... changing "disabled=1" to "disabled=0", then my home WiFi is instantly recognized, and I am immediately logged in (the "forgotten" password isn't really forgotten). Further, if I then re-examine the wpa_supplicant.conf file, I will see that the "disabled" line has been deleted from the current hotspot, and will only be re-inserted once I log into a *different* hotspot. BTW, while I am using the home hotspot as a test, the same behavior applies to ANY hotspot. Thus, under 4.4.4, NO hotspot is logged into automatically (unless it is the most recent hotspot), and unless you are attempting to log into the most recent hotspot, you ALWAYS receive a request to enter the password for a protected hotspot (even though the password is actually still in the file). I use WiFi heavily, and this isn't viable for me.
The problem apparently isn't limited to the i337 (AT&T) build of NJ4. I noticed this discussion in the T-Mobile forum: https://support.t-mobile.com/thread/84926 (I tried to comment on it, but I can't register for the forum since I'm not a T-Mobile customer).
I am now comfortably back on NB1.
Does anyone have a solution for this?
UPDATE: I found that after I reinstalled 4.4.2 (NB1), using ODIN and then Titanium Backup, as soon as I activated WiFi, my device would strip all of the entries from wpa_supplicant.conf that contained a password (psk). I tried a number of different techniques to reload my original wpa_supplicant.conf file, and was never successful. All of the entries without a psk remained, however (there are hundreds).
I also found that after reinstalling NB1 (including the restore via Titanium Backup) once I re-entered the password for a particular WiFi hotspot, then the re-entered password would stay in the wpa_supplicant.conf file (and the phone would again login to WiFi automatically, without ever/always asking for a password re-prompt as was happening with 4.4.4 NJ4).
While I don't really know for sure, it is my guess that the psk entries were stripped from the wpa_supplicant.conf file by the Google server. Not sure why, but since I am able to totally restore the device with all of the pre-backup data files (including the original wpa_supplicant.conf file), this is my only explanation.
For me, NB1 works to remember passwords and log-in automatically to WiFi hotspots; 4.4.4 NJ4 does not.

[Q] G900F HOSTS FILE is normal but couldn't add a Google account

Hi,
Dear All,
Ok, the problem is very famous i.e. i factory reset my device and when powered one like a fresh piece, i cannot add google account on my G900F (can't establish a reliable connection to the server).
i have searched a lot over the internet. Read about the HOSTS files description as well. All i found was the modification of the "etc/hosts" with the clients.google.... following "#" so that 127.0.0.1 localhost is only the operational entity.
My device is un-rooted and just for the confirmation of the above mentioned, i opened the hosts file via HTML Viewer (just readonly) and found that the etc/hosts file on my S5 has 127.0.0.1 localhost only and no any other information, which i think should be available for your device to work normal and google accounts can be added. See attached screenshot.
Need your kind help in resolving my issue please.
Try clearing caches from recovery
Still same issue...
Might be worth factory resetting again
How did you access the HOSTS files without being rooted?
did the factory reset 3 times but nothing, issue stands unresolved.
i opened the HOSTS file through RARLAB. Actually it allows you to view the root folder and all of its contents even if your phone is un-rooted.
Could try removing the device from Google Play
https://support.google.com/googleplay/answer/2407656?hl=en-GB
Create a new Google account as a test to see if the issue is the phone or the account
If that doesn't help, Id flash a stock ROM through ODIN, this will NOT trip KNOX if you are still 0x0
Are you sure all your data connections are working properly, WiFi/3/4G ?
*Detection* said:
Could try removing the device from Google Play
https://support.google.com/googleplay/answer/2407656?hl=en-GB
Create a new Google account as a test to see if the issue is the phone or the account
If that doesn't help, Id flash a stock ROM through ODIN, this will NOT trip KNOX if you are still 0x0
Are you sure all your data connections are working properly, WiFi/3/4G ?
Click to expand...
Click to collapse
ok here are some interesting occurrences:
Worth mentioning that i was operating over Wi-Fi.
1) - i flashed a stock Kitkat ANG2 ROM via odin and the problem still persists.
2) - Then i flashed stock Lollipop BOB7 and still the same.
3) - Then i created a new account via the first sign in page on the phone (after flashing the new ROM), and i was able make a new account(through my phone) but still it was unable to login on the phone.
4) - Then i installed a Proxy/VPN betternet and then i was able add an account successfully and also Play store is working fine.
5) - Means there is some issue with my wi-fi adapter routing (may be inside the phone or the carrier) etc.
6) - Then i switched off the wi-fi and enabled LTE (of my SIM card provider) and connected my phone through it, say what! its working fine.
7) - again i tried over the wi-fi and the issue started to happen again
Well, one important thing, i am using wi-fi which is also a LTE carrier (having the google issues) and the second LTE (which worked fine) is by the SIM card operator.
So , is there any problem with my wi-fi (inside the phone) or may be with the operator from which i am getting my services??
its quite confusing at the moment. well i am going to try the whole thing over the Wi-Fi of another operator and will feedback the results.
Mean while any suggestions ??
Reboot the router you are connected to WiFi from?
Doesn't sound like the phones fault, unless you have a proxy enabled in WiFI settings or something, sounds like the issue is with your ISP/Router

Fix for constant rebooting after upgrade to 2.1.0

**TLDR** - If your shield keeps rebooting after the 2.1.0 update, unplug your ethernet cable and/or disable your wifi as a temporary fix.
I recently got a 16GB model. After the latest firmware update (to 2.1.0) I started to get constant rebooting. My first thought was to use fastboot to get back to 2.0.0 - I believe you can do this without wiping your user data, as the official images are signed with the nvidia key and I believe their bootloader would allow you to downgrade - can anyone confirm this? See https: // developer .nvidia. com/ gameworksdownload (sorry, can't link with <10 posts...) for nvidia 2.0.0 image.
However I wanted to see what was happening first. Running
Code:
$ adb logcat
...lots of output
...the system just rebooted, so let's watch the logs!
D/AndroidRuntime( 4318): Shutting down VM
E/AndroidRuntime( 4318): *** FATAL EXCEPTION IN SYSTEM PROCESS: main
E/AndroidRuntime( 4318): java.lang.IndexOutOfBoundsException: Invalid index 0, size is 0
E/AndroidRuntime( 4318): at java.util.ArrayList.throwIndexOutOfBoundsException(ArrayList.java:255)
E/AndroidRuntime( 4318): at java.util.ArrayList.get(ArrayList.java:308)
E/AndroidRuntime( 4318): at com.android.server.pm.PackageManagerService$PMLocationListener.getCountryFromLocation(PackageManagerService.java:14375)
E/AndroidRuntime( 4318): at com.android.server.pm.PackageManagerService$PMLocationListener.onLocationChanged(PackageManagerService.java:14282)
E/AndroidRuntime( 4318): at android.location.LocationManager$ListenerTransport._handleMessage(LocationManager.java:281)
E/AndroidRuntime( 4318): at android.location.LocationManager$ListenerTransport.access$000(LocationManager.java:210)
E/AndroidRuntime( 4318): at android.location.LocationManager$ListenerTransport$1.handleMessage(LocationManager.java:226)
E/AndroidRuntime( 4318): at android.os.Handler.dispatchMessage(Handler.java:104)
E/AndroidRuntime( 4318): at android.os.Looper.loop(Looper.java:135)
E/AndroidRuntime( 4318): at com.android.server.SystemServer.run(SystemServer.java:276)
E/AndroidRuntime( 4318): at com.android.server.SystemServer.main(SystemServer.java:177)
E/AndroidRuntime( 4318): at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime( 4318): at java.lang.reflect.Method.invoke(Method.java:372)
E/AndroidRuntime( 4318): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:903)
E/AndroidRuntime( 4318): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:698)
I/Process ( 4318): Sending signal. PID: 4318 SIG: 9
E/installd( 226): eof
E/installd( 226): failed to read size
I/installd( 226): closing connection
For those of you that don't speak stacktrace or android internals, what happened here is that something (presumably, my network state tracker noticed either an IP change or something else from my ethernet) sent a message to the internal LocationManager saying "something happened, update your location estimate". In the process of doing this LocationManager crashes, and then the entire android framework crashes in response to this critical component (system_server) crash. Then the init binary helpfully restarts everything, and in a few minutes it crashes again.
Unplugging the ethernet cable has resulted in a stable system. I haven't experienced the crash while on WiFi, but I wouldn't rule it out yet.
While I have not looked in extreme detail, my suspicion is that something about the firmware update broke google mobile services - I see an error trying to mount the data for GMS in the logs, and noticed the stacktrace above seems to be failing when the LocationManager uses the PackageManager which uses installd which then fails with some kind of file read.
Code:
E/Vold ( 206): Failed to find mounted volume for /storage/sdcard1/Android/data/com.google.android.gms/files/
W/Vold ( 206): Returning OperationFailed - no handler for errno 0
W/ContextImpl( 6163): Failed to ensure directory: /storage/sdcard1/Android/data/com.google.android.gms/files
Turning off location services seems to stop this too
I'm 100% that no ethernet stops the rebooting (got a few hours of testing and no crashes). Tried turning off location services after I saw the logs of the error, and I've had about 30 min with no crashes, so that's obviously a much more preferred way to address this issue until nvidia fixes the bug
well interesting to know about this issue.
slammertime said:
I'm 100% that no ethernet stops the rebooting (got a few hours of testing and no crashes). Tried turning off location services after I saw the logs of the error, and I've had about 30 min with no crashes, so that's obviously a much more preferred way to address this issue until nvidia fixes the bug
Click to expand...
Click to collapse
Has having locations services turned off solved the random restarts for you inevitably?
Yes, it seems so
Sorry for resurrecting an old thread, but I'm still having this issue.
Tried disabling location, changing languages, every other suggestion here and elsewhere online.. still getting reboots ~3-5 mins after the system starts, and random lockups. Only started happening post 2.1. The device is basically unusable at this point.
I'm just about to factory wipe/reinstall. Is there any other solution?
Same
grivad said:
Sorry for resurrecting an old thread, but I'm still having this issue.
Tried disabling location, changing languages, every other suggestion here and elsewhere online.. still getting reboots ~3-5 mins after the system starts, and random lockups. Only started happening post 2.1. The device is basically unusable at this point.
I'm just about to factory wipe/reinstall. Is there any other solution?
Click to expand...
Click to collapse
I am having the same issue. Talked to support, and they told me to unpair, and reset my devices that were attached to it, and unplug the hdmi and power, and still no dice.
peppy6582 said:
I am having the same issue. Talked to support, and they told me to unpair, and reset my devices that were attached to it, and unplug the hdmi and power, and still no dice.
Click to expand...
Click to collapse
I got sick of it, wiped the device, and did a fresh install of 2.1 (IIRC, whatever factory image was available a few weeks back) and applied the OTA once prompted. Zero issues since. It took some time installing and configuring everything again, but having a completely stable device made it worth it. It was unusable before, as it'd reboot every few minutes no matter what it was doing.
It looks like they have the 3.0 image up now, if you're thinking of reinstalling as well.
https://developer.nvidia.com/shield-open-source
grivad said:
I got sick of it, wiped the device, and did a fresh install of 2.1 (IIRC, whatever factory image was available a few weeks back) and applied the OTA once prompted. Zero issues since. It took some time installing and configuring everything again, but having a completely stable device made it worth it. It was unusable before, as it'd reboot every few minutes no matter what it was doing.
It looks like they have the 3.0 image up now, if you're thinking of reinstalling as well.
https://developer.nvidia.com/shield-open-source
Click to expand...
Click to collapse
Yeah, I actually did that, with a fastboot -w after the system.img part, just to make sure.
hey guys, do you still have the problem with the random reboot?
I have the same problem with the 500gb version but I didn't root this device or whatever, it isn't even my intention to root it.
Any idea what it is?? Nvidia want to send me a new one (or refurbished item) but I have like the idea that it will not be solved if I get a new one.
I read to much people with the same problems, even on 2 links I read from someone who got a new one and the problem was still there :s
I'm a little scared to send it back , because I fear it will not be solved.
Any idea guys???

Cannot Access WLAN via a DHCP connection , only by using a Static IP

Hey everyone, long time reader- first time poster- hopefully someone can help me!
really frustrating issue, after over 2 years of near flawless use with my n9005 yesterday i noticed i was no longer connected to my saved home wlan, every time i tried i would receive the message: AP currently not in use......, i proceeded to restart phone/router, forget network- and re enter details without any success. after googling the issue i tried all the basic suggested fixes, toggling various wifi settings, toggling date and time, toggling wifi power saving mode via *#0011# all without avail. I researched further and attempted to access the dhcp_list to delete it via root explorer (also viewed the permissions using x-plore and its all ticked for read and write accordingly) etc, however i was never able to do this- always being told i didn't have the file permissions, same story when trying to use terminal with the input: rm /data/misc/dhcp/*. I have checked and do have root access and always granted access before attempting these through the configs of the file explorer and super user or by typing su first in the terminal. Whenever i enter a static IP it connects and works immediately, however when i was out the house yesterday i noticed it was doing the same issue with 2 other saved WLAN networks which being public i cannot use a static ip/ and ultimately cannot join/use. So last night i factory reset my phone/cleared cache this did not work as im still receiving the same Obtaining IP Address loop and AP not in use error message and once again the Static IP work round is my only way to gain access. Im now at a loss what to do next, considering to flash a different ROM/Modem/Boot Loader but dont know if this would be any help?. My system details are listed below any help would be much appreciated
BOOTLOADER: N9005XXUGBOA5
RADIO: N9005XXUGBOA1
home wifi router is the, EE brightbox
Solved installed new ROM all good!

Newbie: GPS problem with Core Plus

Hi all, hi tim,
I'm new in smartphone world but I am "hacking" lover and want to play with my girlfriend old Core Plus.
I enabled debugger mode, Installed TWRP and lineage-13.0-20170524-UNOFFICIAL-cs02.zip ROM (tim's 3.4.5+, Android 6.0.1).
I tried many ROMs but other have problem at boot ("trebuchet" loops chash).
Maybe it's because data and system were not correctly wiped (error during ROMs deployment, I had to manually delete /data and /system using ADB)...
Is there a way to install new rom without loosing data ?
Using OTA updates ? Currently it does not found any update ("No items available").
My main problem is GPS does not work:
(I want to use it for walking, so without internet location providers)
Code:
[email protected]:/ # settings put secure location_providers_allowed +gps
[email protected]:/ # dumpsys location
Current Location Manager state:
Location Listeners:
Reciever[f571137 listener UpdateRecord[passive android(1000) Request[POWER_NONE passive fastest=0]]]
Reciever[6db46a4 listener UpdateRecord[passive android(1000) Request[POWER_NONE passive fastest=0]]]
Active Records by Provider:
passive:
UpdateRecord[passive android(1000) Request[POWER_NONE passive fastest=0]]
UpdateRecord[passive android(1000) Request[POWER_NONE passive fastest=0]]
Historical Records by Provider:
android: passive: Interval 0 seconds: Duration requested 177 out of the last 177 minutes: Currently active
Last Known Locations:
Last Known Locations Coarse Intervals:
Geofences:
Enabled Providers:
fused
passive
mWhitelist=[] mBlacklist=[]
fudger: offset: -276, 1160 (meters)
passive Internal State:
mReportLocation=true
gps Internal State:
mFixInterval=1000
mDisableGps (battery saver mode)=false
mEngineCapabilities=0x6 (MSB MSA )
fused Internal State (com.android.location.fused):
REMOTE SERVICE name=fused pkg=com.android.location.fused version=0
mEnabled=false null
fused=null
gps Location[ 0,000000,0,000000 acc=340282346638529000000000000000000000000 t=?!? et=?!?]
---
net Location[ 0,000000,0,000000 acc=340282346638529000000000000000000000000 t=?!? et=?!?]
---
It there an hardware problem or a OS problem ? How to check ?
I'am also looking for a tutorial to build Lineage from scratch, for my interest.
Any link welcome.
Last request: I didn't find any reliable FM radio tuner apk. Device have a tuner, it works with samsung ROM.
Have a nice day.
Can You send me this rom?
Because source link is dead.
EDIT: Nevermind, sorry 'bout that.

Categories

Resources