Battery life in LineageOS

Why not? Maybe some other people are interested

Puh, yes I am also running out of battery quite fast. I have installed the latest test build, because I am expecting the new camera module :grinning: But things going even worse. Capacity has been about 44% when switching off wifi/ network and going on fligth modus over night. Result this morning 14% battery capacity … :hushed:
I will switch back to FP Open, because I am going on holiday tomorrow…

1 Like

For the record: I’m on the latest test build (new cameras) + Open GApps pico and my battery holds up totally fine, at the moment I don’t see a difference to my previous Fairphone Open OS + Open GApps pico installation.

If somebody could give me a summary of test cases or what settings to check for comparison, I could check and report back.

Could it be that batterydrain is more related to the display? I read in bugtracker that the last change in august was related to display blobs(?). I run my phone always on the lowest brightness but still the battery use from display seems relatively high!

About Greenify: I have started using it under FPopenOS and it seems to help. This article may be of interest:


see here: Greenify on FP2 LineageOS


in regard to Greenify please post in Greenify on FP2 LineageOS

1 Like

So I installed greenify now and all of a sudden I have amazing battery time, better then ever before since I have the phone!!

1 Like

I reinstalled Greenify but don’t see significant improvement. I use the free version since I don’t see any advantage in the extra futures as most of them need Xposed (what is still in Beta):
◆ Allow (most) system apps to be greenified in Greenify
◆ Boost mode (requires Xposed)
◆ Allow GCM push message to wake hibernated apps (requires Xposed)
◆ Reveal hidden sync tasks (requires Xposed)
BBS isn’t that much if of help since I cannot compare certain time periods. Enabling the watchdog feature is a bit of help. I noticed that

  • msm_ehci_host
  • PowerManagerService.WakeLocks
  • PowerManagerService.WakeLocks

causing the majority of wakelocks.
The WiFi is still always on I don’t want to have it swiched of in deep sleep than I won’t receive any messenger/mails etc. notification. Any idea how to switch on the WiFi in deep sleep in periodic steps to check for new messages/mails?

For a very short moment I was optimistic that the battery is back to long running periods but as I left home and consequently switched to mobile data battery was dropping as usual even as I was connected to my office WLAN.
I would like to compare that period with a later period but I don’t have a clue how to do that.

I was doing some observations with bbs (idle dumps). There i got an average battery drop around 1-2% per hour, which is much compared with other devices getting an average of 0.5-0.7% per hour… The msm_ehci_host is supposed to only be leveraged in the kernel. It’s either sd card or wifi, according to a Google search (would have to check which device is hooked to this subsystem/usb hw).
Still, i got my battery usage somewhat mitigated. I switched from greenify to forcedoze, but am still undecided whether this move helped.
One this i see in your battery stats is that you had very bad mobile coverage, this will drain battery…

I continued with my test as battery drain is really frustrating.
First of all is there any alternative to BBS as I want to extract data for a set time range, so far I found
GSam Battery Monitor and Watchdog Task Manager Lite but don’t know anything about them.
I’m saying that since I’ve noticed once that battery drop trend was quite flat as I used in the morning as every morning than I went to work and logged in the local Wi-Fi but as I left home battery drain became much worse and it didn’t improved as it was connected to a Wi-Fi again.
What would help me a lot would be a possibility to compare wakelocks etc before and after I went to work as I didn’t trigger anything actively.
I even restrict mobile background data to three apps.

Yesterday I checked the battery may became weak but when I switch to flight mode I lost only 0.9%/h.

Well, you won’t see too much interesting stuff while using you phone as the display will override every other consumer. Especially wakelocks are irrelevant while using the phone. Still, the worst drainer besides display is the mobile reception. It’s red, so the phone desperately tried to stay connected…
Wakelocks are only relevant when the phone is sleeping


as slight off topic question, who triggers the wakelock is it the app itselft or Android service what invokes apps in scheduled pattern?
I’m asking since I don’t understand how setting permission such as background data, mobile data usage influences an app.
Is the call in the app even blocked or does it wake up the phone notices that I can’t use the mobile data (Wi-Fi or Celluar) and allows the phone go back into deep sleep?

When I put in mobile data only battery last longer than being only on Wi-Fi.
I will upload some screenshots as soon as I have some being worth to be published.

In this regard, is there any app what switched on WiFi in a certain pattern when I deactivate Keep Wi-Fi on during sleep so that I can switch of mobile data or in case I roam.

Both questions…
A wakelocks serves the purpose of keeping the phone awake when it otherwise is supposed to sleep. I.e. some app needs work to do when screen is off and won’t be stopped by energy management. Often, a wakelick in itself need not be bad and use battery (lots of in depth threads on xda…). I did learn that wifi might be easier on battery than mobile, and sometimes not… But you can’t decide with an active phone (see idle dump on bbs threads). It might help to switch to fixed ip from dhcp, if you can.
Second question: I’m using taker with location based profiles for controlling wifi and mobile data. Maybe this might be the way to go?

1 Like

thx Klaus for the explanation but what triggers the wakelock is it the app itself or an Android System Service.
I wondering how data usage can be blocked the privacy guard & app settings.

If I forbid an app to run in background will it be killed or freezed when isn’t active, means displayed, anymore?
If I forbid (cellular) data usage of an app, will it still wake up and tries to connect to a server or whatever?

I got tasker on my phone but haven’t got the chance to set up some profiles, because if I do it, I want tasker to login in the mainly used wifi automatically (including entering credentials into login page)

It depends on what the app wants to achieve. So either the app holds the wackelock, or some service initiated by a request from the app in the framework or the system holds the wakelock.
If you forbid the app to run in the background, the the app will be suspended, and, depending on memory available, might be killed. If you forbid data transfer, the “app doesn’t know” and will try to connect, so in this case it will run.

Back to wakelocks, you won’t be able to do anything about msm_ehci_host, besides airplane mode, this is a kernel issue. You might try to make an bbs idle dump and post it in the xda thread. There a people who can explain it very well

1 Like

thx for the reply I will try my best on XDA, is there any specific thread, a first google up came up wit that one [GUIDE] 0% [0.0%/h] Idle Battery Drain on Stock ROM (XPosed & Amplify Required!)
Besided this I did two more test. Phone was ony on Wi-Fi at the beginning without any restriction and made the Wi-Fi a metered one. The result is a drop from 2.2%/h to 0.9%/h, you can even see how the battery trend flattened.
So it seem app/network status related.

I’d use this:.
This is “pure” bbs, the other also handles topics achievable with xposed and the likes