For anyone suffering from huge battery drain since latest Google Play update (a few weeks ago) caused by System Update Service, here is a fix that worked for me.
NOTE: all credit goes to effgee at OnePlus One forums (I can't post links yet, so you'll have to google it)
This fix REQUIRES root
1. Install Script Manager (SManager) from Play Store
2. Enter Advanced > Configuration and enable Browse as Root
3. From SManager, create a New Script in /data/local/ called startsysupservice
4. Tap the script you just created and tap Edit, the Arguments field should be blank
5. If it tells you do not have access permission over this file, tap Create copy
6. Below the line #!/system/bin/sh add the following line:
su -c "pm enable com.google.android.gms/.update.SystemUpdateService"
7. Save the script (top right corner) and mark the following options: Su, Boot, Bg
8. Hit Save
9. Run the script make sure it runs correctly.
After creating this script, can Script Manager be uninstalled and will the script continue to run on its own? Or does Script Manager needs to be installed permanently in order to start at boot and then run the script at boot?
Related
Today i read from droidforum.net and i see this one, and try to bring it here
source from droidforum and credit by SGMD1
All tutorials below are working as of February 2011. You will only need one file to root, which is included at the bottom of this post.
ROOT/UNROOT TUTORIAL (Courtesy of RyanZA on xdadevelopers)
1. Download and extract the z4root.zip file and copy the .apk directly to /sdcard.
2. Go to Settings -> Applications and make sure "Unknown sources - Allow installation of non-Market applications" is checked. Then click "Development" on the same page and make sure "USB debugging" is checked.
3. Open the "Files" app, navigate to the z4root location and install.
4. Launch z4root and select the Permanent Root option. Give it a minute to do its thing and reboot. If it spends more than two minutes on the message "'Running exploit in order to obtain root access" then you'll want to restart the app; this happens sometimes. Just exit the app by pressing the Home key, kill the app via a task killer (or Settings -> Applications -> Manage Applications -> z4root -> Force stop) and run z4root again. Voila, you're rooted! (You can also use z4root to unroot.)
5. Wireless Tether is a good first app to download if you're rooted. Download the most recent version of Wireless Tether (v2.0.6 as of 1/09/11) to test if you're rooted properly here
MANUAL UNROOT TUTORIAL (Use only if you previously rooted using the terminal emulator method, NOT z4root)
1. Download and install "Android Terminal Emulator" by Jack Palevich from the Market.
2. At the "$" symbol, type the following lines of code (press Enter after each line):
su (you should now see the "#" symbol)
mount -o rw,remount -t ext3 /dev/block/mmcblk1p21 /system
rm /system/app/Superuser.apk
rm /system/bin/su
rm /system/bin/busybox
mount -o ro,remount -t ext3 /dev/block/mmcblk1p21 /system
3. Exit the terminal emulator and reboot your phone. You will no longer have root.
CUSTOM RECOVERY TUTORIAL (Courtesy of Koushik Dutta aka Koush)
1. Download the Droid2Bootstrap.zip file at the bottom of this post, extract the .apk file and place it on /sdcard.
2. Go to the "Files" app, locate the Droid2Bootstrap.apk on /sdcard, install it, and open it. (Select "allow" when asked whether to grant the app superuser permissions)
3. Click "Bootstrap Recovery" and wait for the "success" notification. Then click "Reboot Recovery" and you're done! This will boot you into recovery where you can make nandroid backups, install from .zips, etc (do a search on the forums for more about custom recovery if you aren't familiar with it)
4. DO NOT delete the Droid 2 Bootstrap app once you have completed step 2, as this is the only surefire way to access the custom recovery. Holding "X" + "Power" will take you into the normal recovery.
SIM UNLOCK TUTORIAL
1. Make sure your phone line has been active and had no late payment history for at least six months. If it hasn't, VZW will not unlock your SIM.
2. Call VZW Global Support at 1-800-711-8300 and ask the representative for your phone's SIM unlock code.
3. To test it, you will need a non-VZW SIM. Once you insert it and power your D2 Global back on, it will ask for the unlock code.
NOTE: It appears that Verizon has put a carrier lock on the device for US GSM carriers. Therefore until someone figures out a workaround, you will not be able to use this device on AT&T or T-Mobile in its current state, even if SIM unlocked. The good news is that devs on various boards seem to be close to a workaround so as soon as one becomes available I will add it here.
Not the same phone.
That was very confusing for a second... lol
Sent from my ADR6350 using XDA App
Diferent exploit on droid2 than for incredible 2. Wish it could be that easy though.
Sent from my SCH-I500 using XDA Premium App
Thread closed since you are in the wrong forum.
Been working on a couple fix ideas for this since UltraCfg is no longer working in the UCLD2 leak.
From what I can tell, UltraCfg made an entry in settings.db which can be enabled or disabled. This entry is TETHERING_ALWAYS_ON_MODE = enabled/disabled. Steps to manually do this are shown in post #2.
Also: Tethering Manager & UltraCfg were active; and WifiDirect, Wifi Sharing, and Wifi Sharing Manager are frozen.
Please let me know if any of this works and we can continue to improve this. I'm not sure how stable it is.
Known Issues & Limitations:
1. Only tested by me so far.
2. Not sure if it stable yet. I've had issues keeping wifi tethering active.
3. Any time you connect phone to PC via USB, it disables Debugging and activates Tethering.
4. USB Debugging is disabled on reboot.
5. Not an easy patch for the novice.
I used sqllite editor which is $2.99 in the market. If you dont want to pay and you can survive some terminal shell grinding, here's a free method using sqlite3. For whatever reason, it's not installed by default in our ROMs.
1. Download sqlite3.zip attached. Unzip and put it in /system/bin.
-- quickest method is to unzip. then use adb.
Code:
adb mount
adb push sqlite3 /system/bin
adb chmod 771 /system/bin/sqlite3
2. Next we are going to make a copy of our settings.db file as settings.dbx. Again, in adb.
Code:
adb shell
>su
>cd /data/data/com.android.providers.settings/databases
>cp settings.db settings.dbx
3. Dont close your terminal. Now that we have a copy, we will now edit it with sqlite3. Assuming you did a clean data wipe when you first installed the UCLD2 rom do this:
Code:
echo "insert into system (name, value) values('TETHER_ALWAYS_ON_MODE','enabled');"|sqlite3 settings.dbx
4. Now we have inserted the new tethering setting! Now we need to backup your original settings and replace it with this modified one.
Code:
mv settings.db settings.bak
mv settings.dbx settings.db
5. DONE! Now you may need to reboot.
Code:
reboot
Now, I'm not 100% sure this will work, but I never wiped my data from the UCAL4 ROMs to this new one, so my settings never changed. You will also need Tethering Manager. The one issue with having this mode on is that you will get automatically switched to usb tethering when you connect your phone to computer.
If you ever want to disable, follow steps above except use this command in step 3:
Code:
echo "update system set value = 'disabled' where name = 'TETHERING_ALWAYS_ON_MODE';"|sqlite3 /settings.dbx
I followed the steps ending in a boot loop
PLEASE NOTE: This should work on any and every rooted device, but as always, there is a risk when modifying your devices.
First, I must explain what this guide will do and what you will need.
What we're doing.
1. We will delete the update.zip (if one already exists).
2. We will make a dummy update.zip that will not be replaceable or modifiable, even by the root user (unless the changes are reversed). This fake update file will prevent a legitimate update from downloading and installing.
3. [OPTIONAL] We will remove the annoying update notification.
What we're going to need.
1. Root. [duh...]
2. File explorer with root privileges a.k.a. a "root explorer". (If you need one, I personally recommend the free yet feature packed ES File Explorer.)
3. A proper BusyBox installation.
4. A terminal emulator.
5. A few minutes of your time.
***AS ALWAYS, I, XDA, XDA MODERATORS, XDA MEMBERS, AND EVERYONE ELSE ARE NOT RESPONSIBLE FOR THE CONSEQUENCES OF FOLLOWING THIS GUIDE. THE DEVICE YOU HOLD IS YOURS AND ANYTHING THAT HAPPENS TO IT IS YOUR FAULT. YOU HAVE BEEN WARNED!***
The procedure.
-Part 1. (Only required if an update is already present. If an update is not already present, go to part 2.)
1. Open your root explorer and make sure that it has root privileges.
2. Navigate to /cache (a.k.a. the "cache" partition)
3. Delete the update.zip file.
-Part 2.
4. Make a new .zip file with nothing in it and save it as update.zip (make sure it is saved to "/cache" and nowhere else, not even in a folder inside "/cache"!)
5. From here move on to your terminal emulator.
6. Once inside the terminal emulator, type the following commands.
Code:
su
cd /cache
ls
chattr +i update.zip
From here I recommend that you check that it worked by typing in
Code:
lsattr update.zip
If the command works you will see a lowercase 'i' amongst a string of letters and/or dashes.
-Part 3. [Optional]
The annoying update notifications are actually Google Play Services fault. All you have to do is go to "Settings > Apps" and find Google play services and disable the apps ability to show you notifications.
That's pretty much it. Now I must tell you that you will still receive notifications saying an update was downloaded, verified, and is ready to install, assuming that you did not go through with part 3. All you have to do is click the install button, and let it restart to install the bogus update. The update process will error and all you have to do now is restart the phone. Nothing will have changed as the update file we created is empty and therefore will not change anything on your device. I have been doing this myself for a while now and have not had a single issue.
I hope that you find this useful and happy modding! :victory::highfive:
Message to Moderators: If this is in the wrong area, I apologize. Please feel free to relocate it to the appropriate area of XDA.
If you wish to undo this process, go into the terminal emulator and enter
Code:
su
cd /cache
chattr -i update.zip
From here you can check that it worked by entering
Code:
lsattr update.zip
At this point you can easily delete the file and allow your device to download your OTA.
Thanks, this will work until you wipe /cache so I created a more permanent solution HERE
Here's a guide to help you make the most out of your phone
Guides below can be followed by both rooted and unrooted users
Debloat list: https://paste.rs/OLC
Debloating guide:
1) Download Google platform-tools (ADB and fastboot) from here for the operating system you are using on your computer, I will be using Windows for this guide, and extract the zip file to the root directory of your drive in its own folder (For example, C:\platform-tools, inside of the platform-tools folder you should see ADB and fastboot executables as well as other files).
2) On Windows, download and install the Samsung USB Drivers from here, I don't believe other OSes have to do this.
3) On your phone, go to Settings > About phone > Software information and tap Build number 7 or 8 times until you get a pop-up notification saying "Developer options have been enabled."
4) Go back out to the main Settings menu where you will notice a new option called "Developer options". Tap it and scroll down a little bit until you find USB Debugging, turn this option on and keep your phone unlocked (don't turn off the screen).
5) Plug your phone into your computer and open Command Prompt or Terminal and type cd C:\platform-tools and press Enter (Command will differ for the OS you're using).
6) Type ADB devices, give it a few moments, and check your phone for an ADB connection authorization prompt, check the box that says "always allow..." so you don't have to do this every time you want to use ADB.
7) Type ADB shell, the prompt should change from "C:\platform-tools\>" to something like "<phoneserialnumber>:/"
8) Either highlight all of these commands and paste them into the Command Prompt by right-clicking or highlight one command at a time and paste them in one by one
*************************************
Apps:
1)Naptime(Better Battery Life)
2)Galaxy Max HZ(Helps you change the refresh rate of your phone's display)
------------------------------------------------------------------------------------------------------------------------------------------
For rooted/Unlocked Devices only:
Twrp for Exynos
Kernel for Exynos
Remove Bootloader Warning(Exynos only)
Twrp for Snapdragon
Kernel for Snapdragon
*************************************
Magisk Modules:
Nuked Script: This module includes some scripts that will disable some services on all the apps on your device in order to avoid substantial wake-lock battery drain because your apps send some useless usage and information to GOOGLE and this amazing module will stop that.
Download
SAMSUNG GENERAL PATCHER: This Lets you use most Samsung apps on rooted devices
Download
Universal GMS Doze: Optimizes Google Play services.
Download
Safetynet-fix: fixes the SafetyNet.Install riru and enable magisk hide before installing this module
Download
NFS-Injector: This module aims to improve kernel/ram management between efficiency and energy-aware. Using a complex algorithm, determine the most optimal settings between battery and performance for your device.
Download
Telegram Group link if you need help: http://t.me/S20FeModding
Hey, I want to share how I was able to mount OneDrive into the file system, so it appears as a regular local storage (albeit a bit slow, lol).
This is a great option to expand storage in the absence of microSD card support on our phones. My guess it's applicable virtually to any Android phone, but of course I only tested this on my OP 9 Pro.
Prerequisites:
1. Magisk
2. My Magisk module (see attached)
3. Tasker (or any other tool that can automatically execute a root command at boot)
Here are the steps:
1. Download and install the Magisk module. It installs rclone and fusermount binaries (from this thread) into /system/bin systemlessly.
2. Reboot your phone.
3. Using any terminal run this command:
Code:
/system/bin/rclone config --config=/sdcard/rclone.conf
4. Follow prompts. You can find specific instructions for your cloud storage on: https://rclone.org/docs/
5. In Tasker create a new profile: Event -> System -> Device Boot.
6. Create new task and link it to this profile.
7. In this task create two actions:
* Run Shell: Enter the following command (modify names and paths as needed), and check "root" option:
Code:
nsenter -t 1 -m -- rclone mount OneDrive: /mnt/user/0/emulated/0/OneDrive --daemon --config=/sdcard/rclone.conf --gid 9997 --dir-perms 0771 --file-perms 0660 --umask=0 --allow-other --cache-dir /storage/emulated/0/.cache --vfs-cache-mode full --vfs-cache-max-age 2h0m0s --vfs-cache-poll-interval 5m0s
* Wait: 30 seconds
8. In the task config set "Collision Handling" to "Abort new task".
9. Reboot you phone.
10. Enjoy!
Credits:
Big thanks to user MountainX on https://android.stackexchange.com for their post.
tried ur method but it dose not mount folders on android 11
Works great in a Xiaomi Mi 10T with Custom Android 13 ROM!
I have to update the rclone binary in the ZIP with the Linux ARM64 in the rclone site to have support for SMB servers.