google play services debug - General Questions and Answers

is there any way to find out (debug) which app is causing google play services to drain battery in background ?
apart from trial and error of course ?
my guesses in my case are telegram (with a few bot notifications including pictures) / spotify running in background
tried clearing up cache, readd google account, disabled sync, everything same drain (2-3%/h)

nobody got a smart way to see which app causes google play services to missbehave?

As long as a service / app is running - where it doesn't matter whether in background or in foreground - battery gets drained.

common sense this. but how do i know which app is causing this drain to gms ?

My guess is you're confusing things:
GMS stands for Google Mobile Services and is essentially a bundle of applications and APIs ( application programming interfaces ) installed at the system level. This essentially means that they are deeply integrated with the operating system.
The list of apps tied together with GMS you surely can find on Internet.
Google Play Services is a proprietary background service and API package produced by Google for Android devices. It was introduced in 2012, it is allowing applications to communicate with the services through common means.
To check whether an app makes use of Google Play Services or not you would do a LOGCAT.

Related

Any way to disable "you must have Google play services to run (name of app that doesn

Any way to disable "you must have Google play services to run (name of app that doesn
Title cut off, rest should say "doesn't require Google play services to run"
I only use the play store basically, and have no issues with manually enabling before checking for app updates or to download new apps (on my newer device, my older device doesn't even require them for the play store at all)
But things like ccleaner, my emoji keyboard, a few other apps I can't think, of annoyingly claim to need these services to run... While I'm actively running them and using them just fine without.
On a device without the option "disable notifications for this app"either within the app itself, or within my older 4.0.4 device that runs just fine despite it being older... How can I get rid of these annoyances?
Play services are a huge battery and ram hog which I keep disabled unless needed. So any "just install play services" comments isn't exactly what I'm looking for...
I've looked around in disable service (the app) for these apps, unable to find anything looking relevant.
Any help would be appreciated
Play Services are often used for authentication reasons. Meaning the apps look if you have a genuine version. For freemium apps they check for any in app purchases you might have done.
Other common cases are for push notifications or location services etc. These are often only minor or optional features of apps. That's why they usually work nonetheless without having Play Services active.
The only easy option is to use an alternative app store like the Amazon App Store or F-Droid. All the apps over there are pretty much guaranteed to work without Play Services.
There are also some projects out there that aim for a system without Play Services. A quick search should yield quite some results.
If you are rooted and capable of using XPosed, then there is a module in the repo somewhere that does exactly what you are looking for - hiding the pop up.
Can't remember the name right now and don't know if it is still maintained, but searching the modules should provide it to you.
However, Google Play Service shouldn't be so much of a power drainer any more. Beginning with Android 6 / M the battery optimizations are quite enormous, even though the Play Services are excluded from the system wide optimization (because they take care of these optimizations). To further improve the footprint, you could disable the location services and wireless scanning services.

Alternate of Google services?

So there are news of Google collecting Location Even With GPS Turned Off. But I was really thinking to abort using google services not because of this location tracking but also battery draining from google's wakelock which a serious issue to me as no matter what rom am i using playstore will always drain battery ... So i am thinking to go different alternative service i need maps so obviously i use google maps alot but i need its alternate app and same follow with sync service ( i can adjust it to manual no problem ) but i need those services which will not drain my battery and seriously those secret tracking services. If you want to make fun go away. If any dev or group can make alternate google services pls response here . I could be beta tester.
There is already a project that goes along what you want. Search for microg (I think it's called) it limits the Google services and uses alternatives for others.
Here is the issue you will find. Android is made to use Google services and without it, a lot of things just will not work completely right. Like location based services.

Google Play Services reboots phone every midnight to push system update I don't want.

Ok, I've got a Blu Life One X3 with BLU_L0150WW_V7.0.04.13_GENERIC ROM, Android Nougat 7.0.04.13, rooted with TWRP as bootloader and Magisk as root. AFWall+ is the iptables firewall, and the systemless Xposed Framework is installed as a module in Magisk.
All syncing is turned off and disabled, most of the Google pre-installed apps have been removed from the phone. Only the following remain:
Google Services Framework
Google Play Store
Google Play Services
Google Partner Setup
Google Account Manager
Contacts
Google Phone (merely because I can't find contacts and dialer that properly hook into Android... I will eventually)
Removed:
Google Chrome (internet activity tracking)
Google Tag Manager (tag & pixel tracking)
Google Play Music (lifestyle demography)
Google Play Movies & TV (lifestyle demography)
Google Maps (location tracking)
Google - Quick Search Box (search tracking)
Google YouTube (lifestyle demography)
Google TalkBack / Android Accessibility Suite
Google Drive (lifestyle demography)
Google Duo (audiovisual demography)
Google Contacts Sync (association demography)
Google Backup Transport
Google Market Feedback Agent
Google Calculator
Google Calendar (lifestyle demography)
Google Gmail (lifestyle and association demography)
Google Text-To-Speech
Google Japanese Input
Google SMS - Messages (SMS tracking)
Google Photos (lifestyle demography)
Google Carrier Services
OK Google voice assistant (audio monitoring)
Work Profile Setup
GBoard Google Keyboard (keylogger tracking)
ASIDE:
----------
Yes, GBoard logs keystrokes... Google's own privacy statement about the keyboard reads: "Gboard will remember words you type to help you with spelling or to predict searches you might be interested in."
Maybe you trust that "spelling or to predict searches" is all Google is using their keylogger keyboard for, but I don't.
----------
I've been browsing through the phone's file system, doing a lot of research, and editing .xml files to disable all the jobs that Google starts when the phone boots, and to retract permissions that Google has taken the liberty of using... this reduces CPU utilization and increases battery life. The phone works beautifully, doing what I want it to do (and nothing more), and going for days before requiring a charge.
I've seen no adverse effects from this, save for the issue at hand... that of Google Play Services trying to push a new ROM (BLU_L0150WW_V7.0.04.14_GENERIC), despite me having disabled OTA updates and Google Play Store automatic updates. Google Play Services reboots my phone at midnight each night in attempting to install the update, against my will and without my express consent.
When Google becomes the data-filching malware you cannot turn off, it's time to put Google on a short leash.
Google Play Services downloads via WiFi a .zip file named update_s.zip to /cache, then reboots the phone at midnight. It expects to reboot to fastboot, but that no longer works because I've got TWRP as bootloader, so it boots to the main TWRP screen and just sits there until I reboot it. If the update_s.zip file is allowed to remain in /cache until the next night, Google Play Services won't re-download it, it'll simply reboot the phone in attempting to install it.
I've removed Scheduled Power On/Off (package:/system/vendor/app/SchedulePowerOnOff/SchedulePowerOnOff.apk=com.mediatek.schpwronoff), so it cannot be the cause of the reboots, it's definitely Google Play Services. I've watched system activity via adb logcat and can clearly see that the culprit is Google Play Services.
Even if the update could successfully execute, I wouldn't install it... why is Google pushing a phone manufacturer's ROM, and why are they doing so against my will and in contradiction to the disabled OTA and Google Play Store automatic updates? Why didn't Blu push the update? I suspect they're pushing the ROM to get their permissions back... I'm no longer a cash cow for them, and they desperately want to make money off my info.
I see no way of disabling this behavior, and I've certainly not authorized Google to push system updates to my phone, nor to reboot my phone... they must be brought to heel and forced (via litigation, if necessary) to respect personal property rights. This is illegal under California Penal Code 502(c), Comprehensive Computer Data Access and Fraud Act.
This is tantamount to a mechanic creeping into someone's garage at midnight each night and letting the air out of someone's car tires because that someone doesn't use that mechanic's services. This is tantamount to a refrigerator manufacturer sneaking into someone's home at midnight each night and unplugging the refrigerator because it's made by another manufacturer.
How do I disable this behavior?
So far, the only thing in the file system that I can find that pertains to this is:
/service_contexts
#Other Services
GoogleOtaBinder ubject_rta_agent_service:s0
Anyone know what this is? I can pull the file to the computer in TWRP Recovery Mode, comment out that line and push it back to the phone to see if that ends the behavior. Before I do so, though, I'm going to wait until tomorrow... tonight, I've deleted the /cache/update_s.zip file, and I'm keeping internet connections down (and, for good measure, the firewall in lockdown mode), to see how Google Play Services reacts.
I'm betting it'll do this when that line is commented out:
Code:
private boolean setInstallInfo(String strPkgPath, String strTarVer) {
Xlog.i(TAG, "onSetRebootRecoveryFlag");
try {
IBinder binder = ServiceManager.getService("GoogleOtaBinder");
SystemUpdateBinder agent = SystemUpdateBinder.Stub.asInterface(binder);
if (agent == null) {
Xlog.e(TAG, "agent is null");
return false;
The phone did not reboot last night with update_s.zip deleted from /cache and all internet connections down.
This means Google Play Services is performing unannounced, unsolicited and unwanted remote operations upon a computer system, while disregarding the 'Settings' > 'Developer Options' > 'Automatic System Updates' being disabled, a blatant violation of CA Penal Code 502(c). Anyone up for a class-action lawsuit?
Google Play Services / GoogleOtaBinder doesn't query the 'Automatic System Updates' setting prior to performing its above-described operations, and I have a hard time believing this was just an oversight on the part of Google... it would seem far more likely (given that they're a multi-billion dollar company which hires highly competent programmers, given that they have a financial incentive to regain deleted apps or retracted permissions which a knowledgeable user might delete / retract, given the unannounced nature of the operations they're attempting, given the midnight time at which they're attempting to perform those operations) that the bypassing of the 'Automatic System Updates' setting is quite intentional as means of Google surreptitiously regaining apps deleted or permissions retracted so they can continue to gather personal data via the phone.
Tonight I'm disabling the registration of the service context for GoogleOtaBinder... let's see what kind of fits Google Play Services throws. :silly:
{EDIT}
Hrmph... /service_contexts is written to during boot to register Google's service contexts... I'm going to have to dig a bit deeper to permanently disable GoogleOtaBinder.
Until then, I'm renaming /system/etc/security/otacerts.zip so GoogleOtaBinder cannot communicate with the OTA update server.
There remains the nagging questions:
- Why does Google's OTA system updater disregard user settings which disable automatic system updates?
- Why does Google reboot the phone unannounced?
- Why does Google reboot the phone unannounced, at midnight, when the phone is least likely to be monitored?
- Why does Google dynamically write GoogleOtaBinder into /service_contexts at boot, rather than hard-coding it in so it can easily be commented out, thereby disabling Google OTA updates?
- Why doesn't Google provide a user-interface-accessible means of turning off Google OTA updates?
Well, that did the trick. Renaming /system/etc/security/otacerts.zip so GoogleOtaBinder cannot communicate with the OTA update server does away with Google Play Services' attempts at forcing a system update.
Now to dig into the files and figure out where they're writing to /service_contexts from during boot. I'm going to pull every bit of the Google-weed out by the roots that I can.

Is non-root,google free android possible???

I have Samsung galaxy a50 ( a505f). I disable or removed all possible google products. I only use google play services and google play store. I do not use any google product. No gmail,youtube calender or sync android. If i also disable google play services and google play store + remove my google account from phone and instal apps from Amazon, appstore,appgalery or as apk from my browser. How will this affect my phone? And i do not know if apps i downloaded not from playstore gonna work normal and stabil. Notifications will work normal??? Are there any apps do not work without google play services? I know google cloud messaging is important. It looks like i only need google cloud messasing for now. How to replace gcm?? Without root.
Installing apps from outside of Google Play Store is a surefire way to put yourself in danger. By installing apps from third-party stores, you're bypassing security measures put in place to vet apps for malware threats, making it much easier for a hacker to infiltrate your device with an infected app .
Here on xda many people using root or open source apps. Let's say i bought a new phone and i did not add google account. I removed all possible google apps. I disabled all other google services i can not remove. I downloaded apps as apk files. Will apps update or send push notifications normally? That is all i need to learn. The apps i use are outlook,twitter,signal,telegram,duckduckgo,yandex navi,onedrive and samsung cloud for sync and back up. I do not use any google apps or facebook,whatsapp,instagram, messenger. I just do not know what will be effected with removing google account from phone and disabling google play services. I just need few apps keep sending notifications.
jwoegerbauer said:
Installing apps from outside of Google Play Store is a surefire way to put yourself in danger. By installing apps from third-party stores, you're bypassing security measures put in place to vet apps for malware threats, making it much easier for a hacker to infiltrate your device with an infected app .
Click to expand...
Click to collapse
^Truth^
At the very least scan any apks you intend to side load online with Virustotal. Just downloading them onto an Android without installing them isn't without risk. I side load only 2 or 3 apks from trusted sources.
You can download from Playstore then disable it, all apps will still function. I do this all the time.
Google Play Services* is needed for Playstore to run as well as some none Google apps.
You can then use ApkExport to copy your apps so you don't need to use Playstore next time you need to reload the OS. You save system apk updates as well so a full reload is possible with little or no internet connection. I store these on my SD card but a PC can be used.
Use Karma Firewall to block all the Google junk.
You can easily enable apks if needed.
It's freeware and uses very little battery.
*block Google Play Services with Karma Firewall when not using Playstore. A reboot will be needed after it's enabled for Playstore to work. GPS will waste battery by constantly connecting to the internet (4 times @ minute) if not firewall blocked.

Installation of google play services for a specific user profile

I wonder if I can create two (or more) user profiles on my android device, one of which I will use only open source stuff and everything else on the other.
As far as I know, it is possible to create several user profiles in Android that are isolated from each other.
I would probably install LineageOS for this as it doesn't have google play services pre-installed on it and it seems very "clean" in terms of these things (I have never used this system).
There is something like OpenGApps that allows you to install google play services but as far as I know it requires installation from twrp. So I suspect google play services will then be installed for all user profiles on the device.
So is there any possibility to install google services for one user only?
I also know that there is such a thing as microg (and Aurora stora). When I heard that there was such a thing as "LineageOS for microG" I thought it would be a very good option (on one android profile I just wouldn't use microg). But later I also found out that it is supposedly against the google policy and that they can ban my account for it, which I would prefer to avoid.
So I wanted to ask if the only option to do this is to install LineageOS, check what applications are installed by default, install OpenGApps to it and then disable all google related applications on one of the user profiles?
Does such disabling the application also ensure that Google will not be able to "work" on my device in any way? Does OpenGApps install any system level google stuff that will run in the background anyway?
And are OpenGApps not something that I should not install when I don't want to get a google ban?
You are confusing (Open)GApps - Google themselves call them Google Mobile Services (GMS) - and Google Play Services what are two completely different things.
Google Play Services is one of the most important parts of Android. It helps connect everything together and hold it all there. The Google Play Services are the interface to the Google Mobile Services as well as to the hardware functions of the Android device. Many of your apps use Google Play Services everyday.
GMS is a bunch of apps what includes
Google Play Store,
Google Now,
Google Play Music,
Google Maps,
Google+,
Gmail,
Google Photos,
Youtube
and the Android Device Manager.
Knowing the difference it should be clear that GMS can get installed on a per-user basis whereas Google Play Services not.
jwoegerbauer said:
You are confusing (Open)GApps - Google themselves call them Google Mobile Services (GMS) - and Google Play Services what are two completely different things.
Google Play Services is one of the most important parts of Android. It helps connect everything together and hold it all there. The Google Play Services are the interface to the Google Mobile Services as well as to the hardware functions of the Android device. Many of your apps use Google Play Services everyday.
GMS is a bunch of apps what includes
Google Play Store,
Google Now,
Google Play Music,
Google Maps,
Google+,
Gmail,
Google Photos,
Youtube
and the Android Device Manager.
Knowing the difference it should be clear that GMS can get installed on a per-user basis whereas Google Play Services not.
Click to expand...
Click to collapse
Thanks for the clarification, although I still don't really know what you meant. I thought that google play services is the name for all those components that are needed to run, for example, the google play store. If the google play store needs also other components (?), then when I wrote google play services, I meant all the components that are needed to run the play store.
In any case, I mean in practice whether I am able to install both the play store and the components needed for it only for one user in Android, but from what I understand it is not possible in your opinion.
The questions at the end of my post probably still remain the same. I can only clarify that I meant more general cases in these questions:
Does installing the play store (along with the necessary components) install any system-level Google stuff that will run in the background anyway even if I disable these apps?
And isn't installing the play store (along with the necessary components) by hand something that I shouldn't be doing when I want to avoid a Google ban?
Again:
Google Play Store simply is an ordinary user app as any other user app, too, nothing else. It itself installs , except some Android OS libraries, nothing. Only thing is it requires Google Play Services ( which are running in background ) to properly run. As already said: Google Play Services can only get installed once because it extends Android OS. And Android OS always is the same for all created users.
Don't understand what you mean with "Google ban".
Dani3I said:
I would probably install LineageOS for this as it doesn't have google play services pre-installed on it and it seems very "clean" in terms of these things (I have never used this system).
There is something like OpenGApps that allows you to install google play services but as far as I know it requires installation from twrp. So I suspect google play services will then be installed for all user profiles on the device.
So is there any possibility to install google services for one user only?
Click to expand...
Click to collapse
You can install those apps but you have to flash it via recovery. Also, you need to do that prior to booting into the os for the first time, which I think is related to encryption.
If you already booted into your os, you need to boot into recovery and perform a factory data reset, then flash those gapps (as far as I know dirty flashing those gapps will introduce instability to those gapps. That's why you need a factory data reset).
Keep in mind that factory reseting will delete all your person data.
After you flashed it, those gapps will be available for every user
Dani3I said:
I also know that there is such a thing as microg (and Aurora stora). When I heard that there was such a thing as "LineageOS for microG" I thought it would be a very good option (on one android profile I just wouldn't use microg). But later I also found out that it is supposedly against the google policy and that they can ban my account for it, which I would prefer to avoid.
Click to expand...
Click to collapse
Aurora Store provides an anonymous google account. It's data isn't linked to you which means they cannot ban your account.
Dani3I said:
So I wanted to ask if the only option to do this is to install LineageOS, check what applications are installed by default, install OpenGApps to it and then disable all google related applications on one of the user profiles?
Click to expand...
Click to collapse
LOS comes without any google apps preinstalled. So first flash LOS, then OpenGApps (follow their official guide. They describe it there).
And yes, after that you have to disable every google app you don't want to use for every new user profile.
Dani3I said:
Does such disabling the application also ensure that Google will not be able to "work" on my device in any way? Does OpenGApps install any system level google stuff that will run in the background anyway?
Click to expand...
Click to collapse
If you disable it for the current user, it won't run in any way, yes.
OpenGApps itself shouldn't install anything on system level. But those apps will be installed on system level since you flash them to the system (using your recovery). However, if you disable them they won't run in the background.
Dani3I said:
And are OpenGApps not something that I should not install when I don't want to get a google ban?
Click to expand...
Click to collapse
I don't know.
jwoegerbauer said:
You are confusing (Open)GApps - Google themselves call them Google Mobile Services (GMS) - and Google Play Services what are two completely different things.
Google Play Services is one of the most important parts of Android. It helps connect everything together and hold it all there. The Google Play Services are the interface to the Google Mobile Services as well as to the hardware functions of the Android device. Many of your apps use Google Play Services everyday.
GMS is a bunch of apps what includes
Google Play Store,
Google Now,
Google Play Music,
Google Maps,
Google+,
Gmail,
Google Photos,
Youtube
and the Android Device Manager.
Knowing the difference it should be clear that GMS can get installed on a per-user basis whereas Google Play Services not.
Click to expand...
Click to collapse
Yep that's absolutely correct

Categories

Resources