• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!
  • Fill out your device list and let everyone know which phones you have!    Edit Your Device Inventory

[BETA][2017.10.01] SuperSU v2.82 SR5

Search This thread

EvanVanVan

Senior Member
Jun 27, 2009
387
42
With the Systemless root #2, it says to tell "TWRP keep it read only if it offers."

Is there any problem with allowing it to make modifications? Or does it just negate some of the benefits of the "root without modifying /system"?
 
J

JustRootDontCustomRomIt

Guest
I did the reading and chainfire mentions it in post #3665, but i still don't understand... For the nexus 6p (stock, 6.0.1, 2.62.3), is system space an issue? I use Layers, adaway, busybox, and a bunch of xposed mods...
Should i follow these instructions :

If you have one of those devices that refuse to remount system r/w in Android such as the Nexus 6P, but you do want to do this, "echo FSTABSYSTEMRW=true>>/data/.supersu" in recovery root shell before a SuperSU ZIP flash will patch the boot image in such a way that remounting will work.

So is system space a problem for n6p and if the above quote is for something else, should i do the command anyway? I'll flash 2.62.3
 
Last edited:

FPSUsername

Senior Member
Jun 18, 2012
3,511
964
FPSUsername.ml
My rom came with v2.52 pre installed using xbin directory. How can I update to v2.62-3? Do I have to unroot (and how do I do that on xbin version) it first or can I upgrade directly?

Sent from my GT-I9505 using Tapatalk
 

dmantilal

Senior Member
Dec 31, 2012
94
21
My rom came with v2.52 pre installed using xbin directory. How can I update to v2.62-3? Do I have to unroot (and how do I do that on xbin version) it first or can I upgrade directly?

Sent from my GT-I9505 using Tapatalk

2.52 is the standard SuperSU, beta, that requires a custom boot.img to allow SELinux to run in Enforcing mode and modifies /system.

2.62 is an experimental beta that only modiufies the boot.img and tricks the OS to think files are on /system which actually are not, using overlays. Referred to as "systemless"

They are two separate projects. 2.62 is not tevhnically an upgrade to 2.52. There are loits of great Chainfire posts and FAQ threads in this sub-forum that you should read. Try not to brick your device... stay with 2.52 unless you are fully aware of 2.62's differences.


Read http://forum.xda-developers.com/app...arshmellow-t3219344/post64161125#post64161125 and the complete thread.
 

Ch3vr0n

Senior Member
May 6, 2009
1,693
668
38
@Chainfire I've been following this as you probably have noticed but I probably missed this out isn't fully clear to me. Say systemless becomes fully stable, I would using TB to remove some stock gapps result in /system getting remounted as rw and subsequently cause OTA's to fail?

Verstuurd vanaf mijn Nexus 5 met Tapatalk
 

Chainfire

Moderator Emeritus / Senior Recognized Developer
Oct 2, 2007
11,442
87,708
www.chainfire.eu
@Chainfire I've been following this as you probably have noticed but I probably missed this out isn't fully clear to me. Say systemless becomes fully stable, I would using TB to remove some stock gapps result in /system getting remounted as rw and subsequently cause OTA's to fail?

Definitely
 
  • Like
Reactions: viddy1355

Ch3vr0n

Senior Member
May 6, 2009
1,693
668
38
Follow-up. Leaving stock apps, but simply using TB to make backups (Which is it's main purpose) would that cause a remount and ota fail? If yes, what's the added benefit of systemless over the current system method?

Verstuurd vanaf mijn Nexus 5 met Tapatalk
 

yelupic

Senior Member
Jan 2, 2014
185
79
This was mentioned a few pages back, specifically for Nexis 6. Apparently Google's system image fills almost the entire partition so much that some apps see 0 bytes free. So Adaway can't modify the hosts file. It was suggested to remove some system apps for it function properly and modify the hosts file. Search the thread to be sure as I am sure that is how someone got it to work.

Ah, yes I did see that but I hadn't put 2'n'2 together, but that probably explains it. I'll report it to the AdAway developer so they are aware.

AdAway provides a customizing symlink option to a hosts file wherever you want it to point to (i. e. /data/local/"). - Doesn't this work?
 

shaggyskunk

Recognized Contributor
Nov 22, 2011
19,427
15,803
IDK
r u on sony device? Must i clear cache and dalvik after flash? Tnx mate waitimg for the answer.
No as per my Signature - Samsung Galaxy Note 4 - And - No you don't have to wipe or clear anything.

Have a Nandroid Backup of your current Rom - Boot into Recovery and just Flash the SuperSu zip - Reboot ?

Sent From My SM-N910W8 Running SlimRemix V5.3
 
  • Like
Reactions: 2WhiteWolves

Rapper_skull

Senior Member
Apr 21, 2011
282
161
Naples
@Chainfire I flashed 2.62 over 2.61, but first I removed /system/bin/su and /system/xbin/su I previously created. Now I see there's /system/xbin/su that is a symlink to /su/bin/su. Is it virtual or something actually got written to /system?

Inviato dal mio Nexus 5 utilizzando Tapatalk
 

Top Liked Posts

  • There are no posts matching your filters.
  • 2527
    This thread is for SuperSU releases that are still in testing, and are not yet available through the Play store. The main thread for stable SuperSU releases is located here: https://forum.xda-developers.com/apps/supersu/stable-2016-09-01supersu-v2-78-release-t3452703. The changelogs are in the old release thread.

    Please keep track of the version numbers in the thread titles, as the latest test release may not always be newer than the latest stable release.

    The latest test release is:
    SR5-SuperSU-v2.82-SR5-20171001224502.zip
    RELEASE NOTES
    That is a recovery flashable ZIP (I recommend FlashFire or TWRP). If you want to install via APK, it is also present inside the ZIP, in the common folder.
    614
    unSU Script zip -- Unroot with ease!

    Originally this was a little zip to help with uninstalling the old system-modifying version of SuperSU. It properly restores all the original files the SuperSU installer backed up (so, file-based OTA friendly!) and removes any files added by the installer/app. I figured other people might find it handy as well so it's attached below. Be aware, if you flashed SuperSU twice mistakenly, the SuperSU installer wasn't written to recognize that and so you've lost your originals; a system.img flash WILL be necessary in your case.

    Due to popular demand by the custom ROM community using this to unroot and pass SafetyNet checks/use Android Pay, etc., the script has been expanded to unroot Koush's SuperUser, ROM su binaries, as well as SuperSU Systemless (su.img and BINDSBIN), phh's Superuser (which is also systemless), and now Magisk and LineageOS addonsu.

    Note: To completely remove all traces of the systemless roots, you still need to flash a different, unrooted boot.img, likely the default one that came with the ROM. You can extract it from the ROM zip (or a /data/stock*.gz backup from your root solution before flashing unSU) and flash it using TWRP's awesome "Flash Image" functionality, or, "dirty flashing" the ROM zip should also work.

    My development work on my many projects comes out of my free time, so if you enjoy this project or anything else I've done on xda, please consider sponsoring my ongoing work using my GitHub Sponsors profile. For a one-time donation you can hit the donate link from my profile. Thank you for your support!

    P.S. If you found this handy then please check out my Odds and Ends thread for more flashable goodness. :D

    Previous download counts: 58944; 158506; 59850; 226692
    578
    f2fs with Android story is always complicated.

    So why is SuperSU broken with many custom ROMs:
    systemless SuperSU saves a raw ext4 image in /data/su.img and mounts it as a loopback device and to various locations upon boot.
    The problem with f2fs, is that most kernels included in custom ROMs have issues with managing loopback devices.
    This is not SuperSU issue, rather, kernel developers has to incorporate the necessary fix for f2fs.

    This “fix” is rather dumb :
    https://git.kernel.org/cgit/linux/k...y&id=0d5ed69805ee57d7b416c4a6b47c3b67284db105

    The f2fs head, Kim Jaegeuk forgot to add those pointer to post-4.10 versions of f2fs backports.
    (The stock OnePlus 3T’s kernel source code seems to already have this fix. This explains why OxygenOS didn’t have any issues with SuperSU.)
    So you have 2 choices :
    A. Cherry-pick that fix separately
    B. Merge f2fs version all the way up to 4.10(latest f2fs-stable.git is updated to 4.10)


    But there are more stories to be told, unfortunately.
    Both 2 methods introduce a new problem : breaks all previous f2fs versions to read the data.
    There is no on-disk-format change introduced by the new “fix”, but it turns out that older versions of f2fs has an issue which is exploited only when newer version of f2fs is used to write data.

    You need this additional fix, if you have no intention to update f2fs to the latest 4.10 version :
    https://git.kernel.org/cgit/linux/k...y&id=7a895023cc2c06c08a6cccb71e112255eb0837ee

    Without this fix, the kernel will panic upon reading any data.


    So we took care of the method A.
    However, there is still an issue with method B : deadlock.

    As noted in https://review.lineageos.org/#/c/95316/ , there are deadlocks present on the latest version of f2fs(from 4.8, iirc).
    It took about a month to bisect it, and I got the culprit commit :
    https://git.kernel.org/cgit/linux/k...y&id=de62dad6f502c67fd01b5c0b1f7f242836ce90d0

    I’m still yet to hear from the upstream developers, but I can confirm that reverting that commit fixes the deadlock.
    Our internal AOSPA builds are running on 4.10 f2fs with that commit reverted.


    TL;DR
    It’s not @Chainfire 's fault.
    You have to ask the kernel developer to fix the issue.
    2 methods for the kernel developers

    A. Incorporate only the necessary 2 fixes to fix loopback images :
    https://git.kernel.org/cgit/linux/k...y&id=0d5ed69805ee57d7b416c4a6b47c3b67284db105
    https://git.kernel.org/cgit/linux/k...y&id=7a895023cc2c06c08a6cccb71e112255eb0837ee

    B. If you want to upstream f2fs to the latest 4.10, revert this to avoid deadlock :
    https://git.kernel.org/cgit/linux/k...y&id=de62dad6f502c67fd01b5c0b1f7f242836ce90d0
    (A little credit would be appreciated, as it took me a frustrating month to bisect this)

    Thanks.
    348
    --- reserved ---
    189
    @ everyone

    This post is likely an important one going forward, it could be the answer to various issues people have on 6.0 related to /system.

    The conversation below pertains specifically to Nexus 6 @ 6.0.1, which has an almost full /system, but I'll bet the issue exists on all Nexus devices.

    Do you mean that there's even less space than on 6.0?
    Titanium Backup reports that there 15.6 MB free. Shouldn't this be enough for a very small mod such as an edit to build. prop?

    So after some further investigation, something pretty odd is going on.

    ext4 (the filesystem) has various types of reserved blocks.

    I suspect the tools on booted Android do not count one type of reserved block. Indeed, when you use "df" utility (both toolbox and toybox), it shows 15mb or so free. Using the same "df" utility in recovery (busybox) shows 0b free. It does show that not all blocks are in use, but the remainder is likely reserved.

    If you use a root shell on either booted Android or in recovery, trying to write contents to a new file in /system will fail. To make matters worse, file creation succeeds, but writing content does not, so you end up with a 0 byte file. You need to delete a few extra megabytes of files, before you are able to write even 1 byte to a new file!

    Many editing tools remove the old file and write a new file at the same spot rather than truly editing a file. I'm not sure if the latter has any chance of succeeding, but the former would definitely fail in this scenario.

    While the issue is understandable technically, it is likely to trip up a lot of tools, as the error is generated at the least expected moment.

    This issue is a magnet for file corruption and bootloops. Beware this issue when modifying anything on /system!

    DEVS Immediate hunch is that the difference is explained by usage of struct statfs's bfree vs bavail member.

    TL;DR Yes, even though TiBu and whatever other tool are showing you megabytes free, adding/modifying files is likely to give unexpected results on a (near-)full /system partition, and an unlucky edit can definitely prevent the device from booting! Can't give you exact numbers right now, but before modifying files or adding files to /system, I would recommend deleting files until you have at least 30-ish mb free.