• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

[GUIDE] Modify your System partition WITHOUT Root

Search This thread

denk

Senior Member
Mar 23, 2009
81
31
Intro

This is a guide for people who want to make some modifications to config files, or other files, on System partition but do not want to root their phone or install custom recovery in order to keep OTAs and some apps, which don't play nicely with rooted phones, working. Examples of those config mods could be changing DPI or changing volume levels etc, which you would only do once and forget about it.

While root allows you to do those kinds of changes from within android, this methods would require a PC.

If you are familiar with temporary booting into a custom recovery, skip to step 5.

The usual i am not responsible for any of your actions / bricked phones disclaimer applies.


Prerequisites

- A working adb / fastboot environment. Please use Android SDK, if you installed your adb and fastboot using other tools, things might not work, so please just install SDK, install Google USB Driver from SDK manager, install Platform-Tools from SDK manager (should be installed by default) and then add your sdk platform-tools path to your PATH environment variable to have it available in cmd in every path.
- Unlocked bootloader
- TWRP image for you phone (.img) https://twrp.me/devices/huaweinexus6p.html

Follow the [GUIDE] Unlock/Root/Flash for Nexus 6P for that.


Instructions

Here is an example of modifying DPI. I prefer build.prop method of modifying DPI because using the adb wm density command usually caused some issues for me, but modifying via build.prop didn't.

1 - With you phone ON, connect it to the PC and make sure adb is working by running
Code:
adb devices
and making sure that device is listed

2 - Reboot into bootloader. and make sure fastboot is good to go too. Run commands one at a time:
Code:
adb reboot bootloader
fastboot devices

3 - Place your TWRP image file in some easily accessible folder, for the sake of this example i will use C:\Mods.

4 - Temporary boot into TWRP (we are not flashing it here at all).
Code:
fastboot boot c:\Mods\twrp-2.8.7.0-angler.img
Here is where things may not work. If you don't see your phone boot into TWRP then either your adb / fastboot environment not setup correctly (installed via a tool instead of SDK) or your img file is corrupt.
One thing that works for me when TWRP refuses to boot is to restart cmd and issue the command again this closes and reopens adb/fastboot daemon.

5 - Once TWRP is up on your phone it may display a warning saying "TWRP has detected an unmounted system partition". Swipe to allow modifications at the bottom. This screen may not come up at all.
6 - Go to Mount >>> Tick System >>> Make sure "Only Mount System Read Only" is unticked >>> Press Back button
7 - Back on your PC check if your device is listed
Code:
adb devices

8 - Pull the file you need to modify from system partition to your PC. Please note the direction of the slashes:
Code:
adb pull /system/build.prop c:/Mods

9 - Now you should see build.prop in your c:\Mods folder. Use Notepad++ or something like that to edit the file. Find the line with lcd_density= and change it's value to whatever you need and save the file.

10 - Push the file back to your phone:
Code:
adb push c:/Mods/build.prop /system

11 - Reboot
Code:
adb reboot

12 - Profit.

Hope this will help anyone who is looking to do some mods without installing custom recovery and rooting your phone.

Cheers.
 
Last edited:

denk

Senior Member
Mar 23, 2009
81
31
Yes it will. What's the line again I was looking for it the other day and couldn't find it...
 

r0cafella

Senior Member
Apr 15, 2011
830
301
Works are per OP's original post, tested and boosted the headphone volume without a problem.

Headphone path is /system/etc/mixer_paths.xml

So as per OP's example to pull: adb pull /system/etc/mixer_paths.xml c:/Mods

push: adb push c:/Mods/mixer_paths.xml /system/etc

I'm using the OP's "Mods" folder to demonstrate the file path but this may vary on your PC.
 

denk

Senior Member
Mar 23, 2009
81
31
Can I use this to push SuperSU / etc to my device without having to permanently flash TWRP?

You can certainly push the files to system partition and they will retain there after reboot. So if you know which files have to be pushed for SuperSU then give that a go. It shouldn't break anything.

I haven't tried pushing SuperSU files to system partition before so I can't guarantee that OTAs will work after this. The only way to find out is to try it i guess...
 
Last edited:
  • Like
Reactions: jmsunlimited

locolbd

Senior Member
Apr 3, 2011
236
50
www.reggae141.com
I will say thanks now and try it later. These are the type of tweaks I would like to make to my phone. Do you know if changing the DPI cause any stock applications to show up broken like they do on the Samsung phones?
 

denk

Senior Member
Mar 23, 2009
81
31
I will say thanks now and try it later. These are the type of tweaks I would like to make to my phone. Do you know if changing the DPI cause any stock applications to show up broken like they do on the Samsung phones?

I've never had a problem with changing DPI using this method on a nexus phone if that helps.
 
  • Like
Reactions: locolbd

locolbd

Senior Member
Apr 3, 2011
236
50
www.reggae141.com
okay so after i did this i get the following during boot up
"Your device is corrupt. It can't be trusted and may not work properly". Does this mean i will not get Securty Updates any more? I saw i had an update before i performed this however, now i do not see that update notifications any more.
 
Last edited:

binglejellsx2

Senior Member
Dec 29, 2009
150
21
okay so after i did this i get the following during boot up
"Your device is corrupt. It can't be trusted and may not work properly". Does this mean i will not get Securty Updates any more? I saw i had an update before i performed this however, now i do not see that update notifications any more.

I got this too when I flashed MOAB via adb sideload. I'm just wondering if the same warning appears with the adb push method. Also, the file's permissions don't need to be set after adb push?

My main concern is if Android Pay still works with the red triangle warning. Anyone?

FYI Flashing back to stock is no issue for me.
 

denk

Senior Member
Mar 23, 2009
81
31
Can you run nandroids backups from TWRP by just booting into it?

I think if you get the latest TWRP which supports decryption of data partition (where all your stuff is) you should be able to back it up.

Edit: backup works on nexus 5 with temporary TWRP boot. Sorry I'm still waiting for my 6p to arrive.
 
Last edited:

denk

Senior Member
Mar 23, 2009
81
31
okay so after i did this i get the following during boot up
"Your device is corrupt. It can't be trusted and may not work properly". Does this mean i will not get Securty Updates any more? I saw i had an update before i performed this however, now i do not see that update notifications any more.

Thanks for trying it out! Sometimes OTA notifications take a little while to come up after reboot. But based on the warning Im afraid that they might be disabled now. It looks like it runs some sort of a check on the system partition to verify its legitimacy. So modifying files would be fine on it using this method but looks like adding them won't work.

TWRP just released their recovery with decryption support so you can just follow the standard procedure or just temporary booting into TWRP and rooting from there which works as well.
 
Last edited:

NCguy

Senior Member
Jul 4, 2010
1,658
227
NC
I think if you get the latest TWRP which supports decryption of data partition (where all your stuff is) you should be able to back it up.

Edit: backup works on nexus 5 with temporary TWRP boot. Sorry I'm still waiting for my 6p to arrive.
On your Nexus5 I assume you are also unrooted? And have you tried a Nandroid restore, booted TWRP, no root?
 

Top Liked Posts

  • There are no posts matching your filters.
  • 17
    Intro

    This is a guide for people who want to make some modifications to config files, or other files, on System partition but do not want to root their phone or install custom recovery in order to keep OTAs and some apps, which don't play nicely with rooted phones, working. Examples of those config mods could be changing DPI or changing volume levels etc, which you would only do once and forget about it.

    While root allows you to do those kinds of changes from within android, this methods would require a PC.

    If you are familiar with temporary booting into a custom recovery, skip to step 5.

    The usual i am not responsible for any of your actions / bricked phones disclaimer applies.


    Prerequisites

    - A working adb / fastboot environment. Please use Android SDK, if you installed your adb and fastboot using other tools, things might not work, so please just install SDK, install Google USB Driver from SDK manager, install Platform-Tools from SDK manager (should be installed by default) and then add your sdk platform-tools path to your PATH environment variable to have it available in cmd in every path.
    - Unlocked bootloader
    - TWRP image for you phone (.img) https://twrp.me/devices/huaweinexus6p.html

    Follow the [GUIDE] Unlock/Root/Flash for Nexus 6P for that.


    Instructions

    Here is an example of modifying DPI. I prefer build.prop method of modifying DPI because using the adb wm density command usually caused some issues for me, but modifying via build.prop didn't.

    1 - With you phone ON, connect it to the PC and make sure adb is working by running
    Code:
    adb devices
    and making sure that device is listed

    2 - Reboot into bootloader. and make sure fastboot is good to go too. Run commands one at a time:
    Code:
    adb reboot bootloader
    fastboot devices

    3 - Place your TWRP image file in some easily accessible folder, for the sake of this example i will use C:\Mods.

    4 - Temporary boot into TWRP (we are not flashing it here at all).
    Code:
    fastboot boot c:\Mods\twrp-2.8.7.0-angler.img
    Here is where things may not work. If you don't see your phone boot into TWRP then either your adb / fastboot environment not setup correctly (installed via a tool instead of SDK) or your img file is corrupt.
    One thing that works for me when TWRP refuses to boot is to restart cmd and issue the command again this closes and reopens adb/fastboot daemon.

    5 - Once TWRP is up on your phone it may display a warning saying "TWRP has detected an unmounted system partition". Swipe to allow modifications at the bottom. This screen may not come up at all.
    6 - Go to Mount >>> Tick System >>> Make sure "Only Mount System Read Only" is unticked >>> Press Back button
    7 - Back on your PC check if your device is listed
    Code:
    adb devices

    8 - Pull the file you need to modify from system partition to your PC. Please note the direction of the slashes:
    Code:
    adb pull /system/build.prop c:/Mods

    9 - Now you should see build.prop in your c:\Mods folder. Use Notepad++ or something like that to edit the file. Find the line with lcd_density= and change it's value to whatever you need and save the file.

    10 - Push the file back to your phone:
    Code:
    adb push c:/Mods/build.prop /system

    11 - Reboot
    Code:
    adb reboot

    12 - Profit.

    Hope this will help anyone who is looking to do some mods without installing custom recovery and rooting your phone.

    Cheers.
    2
    Yes it will. What's the line again I was looking for it the other day and couldn't find it...

    I believe it's this:

    Add the following line to the bottom of build.prop file: net.tethering.noprovisioning=true
    1
    Can I use this to push SuperSU / etc to my device without having to permanently flash TWRP?

    You can certainly push the files to system partition and they will retain there after reboot. So if you know which files have to be pushed for SuperSU then give that a go. It shouldn't break anything.

    I haven't tried pushing SuperSU files to system partition before so I can't guarantee that OTAs will work after this. The only way to find out is to try it i guess...
    1
    I will say thanks now and try it later. These are the type of tweaks I would like to make to my phone. Do you know if changing the DPI cause any stock applications to show up broken like they do on the Samsung phones?

    I've never had a problem with changing DPI using this method on a nexus phone if that helps.
    1
    getting the following error with the May image.... any help??

    C:\SDK\android-sdk-windows\platform-tools>fastboot boot C:\SDK\android-sdk-windows\platform-tools\twrp-3.0.2-0-angler.img
    downloading 'boot.img'...
    OKAY [ 0.635s]
    booting...
    FAILED (remote: unlock device to use this command)
    finished. total time: 0.664s

    For anyone that intends to help, this user has posted for help here...

    http://forum.xda-developers.com/nexus-6p/help/help-using-adb-t3382737/post66938865#post66938865