In not sure why or how this is happening, but if I leave my device sitting for a while (sometimes 20 minutes sometimes hours) and wake my device, it freezes totally, can't unlock with fingerprint and screen stops. Boom crash dead. Hold power button for a second and it boots up. Originally it seemed to be the kernel and a tweak I was using. After removing that tweak this issue is still here. I can now say it most likely isn't the kernel but I don't know WHAT it is. I read online a rouge partial wakelock could be the cause but BBS stats look normal.
Also I don't have a last_kmsg in /Proc someone wanted me to grab that to help me but it isn't in there.
So is there some way I can grab logs after a system crash? I know people have said logcat could help but alogcat only logs when you execute the app. Any help on this would be great.
I'm running lineage 16 on my Razer phone (Cheryl) I have magisk and some modules including the fde app installed.
Thanks.
Related
Hello,
I'm currently running the lastest (150118) release of mokee, and my phone can't seem to enter deep sleep. In BBS, the event0 and event2 wakelocks take up nearly 50% of the device on time, and I get an average of a few seconds of deep sleep time, resulting in terrible battery life. Attached are the BBS screenshots.
I did some research and figured out that event0 and event2 are the events from the touchscreen and hardware buttons, but I'm not sure how this would affect the battery levels especially when the screen is off.
Any help is appreciated.
Thanks in advance!
it's not, it's a wifi issue, and most likely an issue with your router. it seems that with some routers produce some weird signals with your phone, and leads a rogue app to constantly try and use your wifi whilst you're in deep sleep.
Is this supposed to happen even while my WiFi is off? It seems that no matter where I go, the phone just won't enter deep sleep and seems to drain more battery locked and off than unlocked. I've tried switching to nameless 4.4 and it is giving me the same problem, which doesn't seem right.
Sent from my Find7 using XDA Free mobile app
The nature of eventN wakelocks is that they almost NEVER actually hold the device awake for very long.
They're a symptom, not a cause - when the system resumes, they hold a wakelock from the time the kernel resumes, up to the time when the frameworks wake up and process the event (which in the case of a resume is, if I recall correctly, pretty much a null event.)
So if you have high eventN wakelocks - something is causing your system to suspend-thrash.
In older kernels, there was a "suspend_backoff" driver to handle this case, and at least hint as to the nature of the problem. I reimplemented the backoff functionality in Omni's kernel to help debug such an issue. (Way back last spring, there was a bug in the battery/charger management driver that would cause a stuck interrupt to prevent suspend. The device would try to suspend, error and abort, then resume, then immediately try again, over and over and over again. You could actually SAVE power by holding a wakelock to prevent the thrashing.)
You'll probably need to look through dmesg to figure out why your device is suspendthrashing.
Hi Entropy!
I've gone through and attached a dmesg.
I'm not particularly sure how to interpret this, but instead of trying to suspend and abort, it seems as if the device is continuously suspending for 0 seconds and waking up. I'm not quite sure why.
Could you take a look? If you need anything else to figure this out I'd be happy to provide it.
Thanks!
I even broke my phone with App Ops trying to figure it out, disabling wake permissions for most apps which caused FC's and even reboots. I have since restored all permissions but I still get FC's whenever I leave an app or switch out of it. Not sure if it's really crashing, but I get a FC message every time. So much so that Substratum turned off its theming for Files because it "crashed" after every screenshot was successfully uploaded to this post. Btw I just removed CrossBreed Lite and it seems to have helped. So far no reboots doing the same stuff that caused reboots! Not sure why it caused problems though. I used it for a few days with no issues.
Anyway, back to my battery woes. 30-40% kernel system usage. Why is this happening? Even Snapchat which is abusing wake locks is nothing compared to kernel system.
I'm running the latest build of AIM 8.1 with EX Kernel. I have just visited the other thread about tweaking governer values to optimize battery life so I'll report back with results although I doubt that's relevant to my battery drain.
I've Googled quite a bit on the subject and it seems that each case is different. Usually caused by a certain bug, although a lot of people say it's "normal" which I strongly disagree with.
Update: optimizing the CPU has definitely made an improvement, but the kernel battery drain still exists.
Could it really be pick up to wake and wifi search behind the drain? Isn't this phone supposed to have a sensor hub that allegedly allows for all sensors to constantly be on while using minimal power? I never noticed this drain on any other phone with both of these features on.
Anyway, I disabled pick up to wake and I'll start trying to remember to turn off wifi when not in use.
I think you're trying too hard and running a bunch of stuff. The kernal usage looks about right. I wouldn't run Gsam and BBS at the same time. They can fight each other. What makes you think there's a problem? Nothing jumps out at me.
Sent from my [device_name] using XDA-Developers Legacy app
I also can't see anything out of the ordinary, except this one picture where it shows the phone being active while dozing. I don't know how to understand that because I don't use that app, maybe I'm reading it wrong. What does Android's built-in battery monitor show? Is it dozing properly while screen is off? What is your average SOT? Is your mobile signal strong? I'm also using AIM 8.1+EX combination with satisfying results. Is your radio up to date?
maybe Wakelock Detektor or Greenify can help you.
And if you currently have things crashing all the time, start with a factory reset. Much easier to diagnose the cause when the apps aren't doing random stuff.
Long story short, I have been experiencing a severe battery drain with any ROM I try for the last month or so. Some ROMs seemed not to have it until first reboot, then the drain showed up.
Installing BetterBatteryStats showed me there was a "fingerprint wakelock" active 100% of the time. This was a bit strange, because my fingerprint sensor doesn't even work most of the time (sometimes it works after installing a ROM, sometimes after a few reboots, but it always stops working eventually for no apparent reason).
But searching around, I came across this page, where the following step is suggested:
mv "/vendor/bin/hw/[email protected]" "/vendor/bin/hw/[email protected]"
By renaming the corresponding file on my current ROM (/vendor/bin/hw/[email protected]) and restarting the device, I got rid of the battery drain and it now shows a healthy deep sleep time! I suppose that kills the fingerprint sensor, but since it wasn't working anyway, no harm done.
Just posting it for posterity and reference to whoever wants to try, I have no idea if anyone else has the same issue. (now I'll go hunt down PowerManagerService wakelocks, which seem to be the next big thing eating battery)
First, thank you for your guide. After updating from 7.1.2 to 9 i experienced a severe battery drain issue as well and this solved it. Actually, the fingerprint sensor never worked on android pie for me (crdroid 5.3). I would like to add some information that may be usefull to people.
This battery drain was caused by the fingerprint sensor and can be diagnosed by cpu spy where you will see your phone not going into deep sleep at all (interactive mode kernel, no idea for performance or gaming modes), and better battery stats showing finger print sensor being responsible for a big part of kernel wake lock when the screen is off.
Renaming the file can be done either if you are rooted on the phone or ( as i have noticed many apps like netflix refusing to work on rooted phones, making it inplactical to having your phone rooted ) using adb usb debugging to rename the files. if you are not allowed to rename the files, remount the phone and try again, remounting will automatically mount it in ReadWrite, while sometimes the first time will mount only as read.
If the problem is fixed the cpu spy app will show a much larger time spent in the lowest clock state in interactive mode and actually phone spending time in deep sleep.
PS: DO NOT hunt down the power wake locks as stated in your post, as those are active when your screen is on, and those should be on.
Since I already made several posts / topics regarding issues on my phone with deep sleep, I was able track down different issues and scenarios which prevented the phone from going into deep sleep.
Thanks to
@Freak07
@Lughnasadh
@RetroTech07
@TNSMANI
@craznazn
ProxyHandler gets stuck after a reboot
Link: https://support.google.com/pixelpho...oxycontroller-wakelock-draining-battery?hl=en
Basically every now and then the "ProxyHandler" will get stuck after a reboot and prevent the phone from ever going into deep sleep.
Fix:
To temporarily fix this go into airplane mode and reboot again. Disable airplane mode after the reboot and use your phone until the next reboot
When the screen gets stuck at 60Hz
I wasn't able to figure out which service is keeping the device awake.
But I did track down that the 60Hz stuck-issue is also prevent the phone to going into deep sleep.
Fix:
Reboot the phone
I will update this post when new bugs get reported or figured out.
In my testing it doesn't seem like "Naptime" will fix or help with any of the issues.
Also in my testing it seems like "Naptime" in general doesn't do anything regarding battery drain / deep sleep.
So far I have been using BBS to track down most of the issues.
To use BBS on Android 12:
Install BBS
Grant all permissions
Run in adb: adb shell settings put global hidden_api_policy 1
Reboot phone
Everything except kernel wakelocks will work
Utini said:
Since I already made several posts / topics regarding issues on my phone with deep sleep, I was able track down different issues and scenarios which prevented the phone from going into deep sleep.
Thanks to
@Freak07
@Lughnasadh
@RetroTech07
@TNSMANI
@craznazn
ProxyHandler gets stuck after a reboot
Link: https://support.google.com/pixelpho...oxycontroller-wakelock-draining-battery?hl=en
Basically every now and then the "ProxyHandler" will get stuck after a reboot and prevent the phone from ever going into deep sleep.
Fix:
To temporarily fix this go into airplane mode and reboot again. Disable airplane mode after the reboot and use your phone until the next reboot
When the screen gets stuck at 60Hz
I wasn't able to figure out which service is keeping the device awake.
But I did track down that the 60Hz stuck-issue is also prevent the phone to going into deep sleep.
Fix:
Reboot the phone
I will update this post when new bugs get reported or figured out.
Click to expand...
Click to collapse
Please check whether the A12 update fixes any of your issues.
TNSMANI said:
Please check whether the A12 update fixes any of your issues.
Click to expand...
Click to collapse
I intend to do so. Will get released in one week for Pixel 6 Pro. So I still have to wait ;-)
Don't seem to have any issues with deep sleep, unlocked 512Gb version.
Utini said:
In my testing it doesn't seem like "Naptime" will fix or help with any of the issues.
Also in my testing it seems like "Naptime" in general doesn't do anything regarding battery drain / deep sleep.
So far I have been using BBS to track down most of the issues.
To use BBS on Android 12:
Install BBS
Grant all permissions
Run in adb: adb shell settings put global hidden_api_policy 1
Reboot phone
Everything except kernel wakelocks will work
Click to expand...
Click to collapse
In general, Naptime, and similar apps, have not really been needed since Android 10. In my experience, they can do more harm than good, for what it's worth. A properly running OS with properly running apps shouldn't need apps like this nowadays. If you feel the need to use apps like this then something else is wrong. These types of apps only address the symptom, not the cause (Rocky Horror flashback ).
Just my opinion...
Does anyone know if poor signal strength prevents deep sleep or causes the phone to take longer into deep sleep?
Could it be that countries where the pixel is not official being sold somehow affect deep sleep?
It is weird because usually I am like 65% deep sleep while screen is off and 35% awake while screen is off.
Today I am in a country where the Pixel is also officially being sold (I actually bought it here) instead of my home country and I am like 95% in deep sleep and only 5% awake.
Utini said:
Does anyone know if poor signal strength prevents deep sleep or causes the phone to take longer into deep sleep?
Could it be that countries where the pixel is not official being sold somehow affect deep sleep?
It is weird because usually I am like 65% deep sleep while screen is off and 35% awake while screen is off.
Today I am in a country where the Pixel is also officially being sold (I actually bought it here) instead of my home country and I am like 95% in deep sleep and only 5% awake.
Click to expand...
Click to collapse
I remember when traveling to Europe my P5 (or P4 perhaps it was long ago) drained like 20% overnight while in the US, same programs same everything, it was loke 4 or 5%. So you might have something there.
bobby janow said:
I remember when traveling to Europe my P5 (or P4 perhaps it was long ago) drained like 20% overnight while in the US, same programs same everything, it was loke 4 or 5%. So you might have something there.
Click to expand...
Click to collapse
Well US and EU are quite different (some brands/models even sell the same device as US model and as EU model). I think the frequency bands are different and maybe other things?
But if this is caused simply because I am in the neighbor country in which the P6 is not being officially sold...well **** google and my carrier then.
Has this issue been resolved?
I found on Reddit posted by u/zakazak:
Due to the help of people over at xda, I manged to figure out two scenarios where a software bug will prevent the phone from ever going into deep sleep. I am posting this here because r/GooglePixel seems to have changed into a territory for haters of rooting and custom ROMs/Kernel. How ever, without root you will probably never figure this out.
So here I am posting this for everyone who is facing massive battery drain (like I did):
ProxyHandler gets stuck after a reboot
Link: https://support.google.com/pixelpho...oxycontroller-wakelock-draining-battery?hl=en
Basically every now and then the "ProxyHandler" will get stuck after a reboot and prevent the phone from ever going into deep sleep.
Fix:
To temporarily fix this go into airplane mode and reboot again.
Disable airplane mode after the reboot and use your phone until the next reboot
When the screen gets stuck at 60Hz
I wasn't able to figure out which service is keeping the device awake. But I did track down that the 60Hz stuck-issue is also prevent the phone to going into deep sleep.
Fix:
Reboot the phone
Other notes regarding testing:
In my testing it doesn't seem like "Naptime" will fix or help with any of the issues. Also in my testing it seems like "Naptime" in general doesn't do anything regarding battery drain / deep sleep.
Deep Sleep means that the phone will save a lot of battery while the screen is off. Usually the drain during deep sleep is 0,2-0,5%/h. Without deep sleep it is somewhere at 2-4%/h.
So far I have been using BBS to track down most of the issues.To use BBS on Android 12:
Install BBS
Grant all permissions
Run in adb: adb shell settings put global hidden_api_policy 1
Reboot phone
Everything except kernel wakelocks will work
Hope this helps some people.
https://www.reddit.com/r/GooglePixel/comments/rboc06