1. Are you ready for the Galaxy S20? Here is everything we know so far!

Phone unroots itself

Discussion in 'Android Devices' started by Deusolux, Aug 20, 2018.

  1. Deusolux

    Deusolux Lurker
    Thread Starter

    I have a ZTE Quartz z797c jelly bean 4.3. I used the app "KingRoot" (not KingoRoot) to root my phone and checked it with a root checker app. I've been able to access su from terminal and backup my device with Titanium backup. But somehow, my phone unroots itself and I am not able to grant su privileges to any app. So I went back to the root checker and it said that I was unrooted. I went back to the KingRoot app and it still said I was rooted. After that I tried terminal. Couldn't access su. To get root back, I reboot my phone so KingRoot will notice that it's unrooted. Then I root it again. But like 20 minutes later my phone will unroot itself again. So, whatever it is i want to do, I have about a 20 minute window before I have to reboot and reroot to continue. Can you guys help? Also, I've tried switching the SU Binary from KingRoot to SuperSU but it fails everytime. I've also downloaded a shell script from youtube that removes KingRoot and replaces it with SuperSU, but when I try to "update the binary" it always says "installation failed." That was one of my troubleshooting attempts, trying to see if it was the KingRoot app itself or if it was just my phone. Also, i researched my phone and everywhere on the internet says my phone can't be rooted... but i did... kind of... In another one of my attempts to fix this, I went to terminal and tried mounting /system as rw. It returned "mount: read only file system." I tried it again using my laptop. These are the commands.

    adb devices --> (mine was listed, forgot the name)
    adb root --> (no issues after rooting with KingRoot)
    adb shell --> (went to shell)
    mount -o rw,remount /system --> "mount: read only file system"

    So, it failed again. In my next attempt, I tried linking /system/bin with a /data/data/ folder (rw) so I could try to add a /system/bin/su folder, but it said that the path was read only. So, I'm unsure of what to do next. Even if you don't have an answer, I'll accept any troubleshooting suggestions. Now, I don't much about androids or linux commands (everything i've done so far has been either youtube or commands from xda forums) so you will probably have to explain each step in detail (an explanation of each step is nice so i know why to do it and what it's doing. I don't like following steps blindly, but its what ive done so far.)

    Also, I'd like to know how to root my device on my own so i don't have to use a one-click app (i don't think they are safe). I'll do a factory reset to clear out everything that KingRoot "put" in my phone, then i'll root it again. So if you know how to root, I'd appreciate it if you tell me. (I can't flash a custom rom on my phone because my recovery won't allow it and i can't get a custom recovery because twrp and cwm don't support my phone model.)

    Thanks for your time, Tyler
     

    Advertisement

  2. Hadron

    Hadron Smoke me a kipper...
    VIP Member

    Root methods are phone specific, but if there is no custom recovery for this phone then the main approach to rooting without using one of these dodgy apps is not available to you. Because the generic approach to rooting is "unlock bootloader, flash custom recovery, use that to flash the superuser package", and if there's no custom recovery that breaks at step 2 (assuming that step 1 is available, which it isn't always).

    I should warn you though that a factory reset won't remove everything that Kingroot put on your phone. A "factory reset" is really a "factory data reset", i.e. it wipes the /data partition, removing all of your apps and data and resetting settings to defaults, but it doesn't do anything at all to the system partition. So any modifications that Kingroot has made to your system will still be present after a reset. Though if it's "unrooting" after 20 minutes maybe it's not able to modify /system, and it's just "temp rooting" the running OS.

    Trying to do things using ADB that require root access, such as mounting /system rw (read/write), is of course only going to work if the phone is rooted. If you think the "adb root"/Kingroot thing has worked, then you could try to run your adb command as superuser, e.g.

    adb shell "su -c 'mount -o rw,remount /system'"

    You could try a variant, such as:

    adb shell
    su -c 'mount -o rw,remount /system'

    or even

    adb shell
    su
    mount -o rw,remount /system

    These are all variants on a theme: "su" is a command to raise your privileges to superuser level, which is needed for the mount command to work. If the phone isn't rooted the su command won't be accepted.

    If you are really unfamiliar with adb, android and linux shell commands I'd be very careful trying to do things this way. If you gain rw access to /system you have the ability to remove or overwrite things that will prevent the phone from booting. If you make a mistake like that, and have no custom recovery, you'll need to have a way of reflashing the phone's software completely to get it going again (and I don't know about doing that with ZTE phones).
     
    lunatic59 and Jfalls63 like this.
  3. Deusolux

    Deusolux Lurker
    Thread Starter

    Thank you for your input! These are the results
     

    Attached Files:

  4. Deusolux

    Deusolux Lurker
    Thread Starter

    Here is proof that my phone was rooted:
     

    Attached Files:

  5. bcrichster

    bcrichster ROMinator
    Moderator

    OK, You need to disable Write protection (change RO to RW).. Immediately after Rooting, open a terminal and enter:
    su
    reboot disemmcwp

    After phone reboots, try to Root again. This is a common issue with Rooting ZTE devices and what I suggested above is our normal workaround for that, thanks to @hroark13 for finding it .. Hope it helps
     
    #5 bcrichster, Aug 20, 2018
    Last edited: Aug 20, 2018
    Deusolux and Hadron like this.
  6. Deusolux

    Deusolux Lurker
    Thread Starter

    Ok thanks man, and if I create a /system/bin/su directory (because my phone doesn't have one) and run these commands, will supersu stay on my phone as the main su binary?

    adb push su /system/bin/su

    adb shell chmod 6755 /system/bin/su

    adb shell chown root:root /system/bin/su

    adb push SuperSU.apk /system/app/SuperSU.apk

    adb shell chmod 644 /system/app/SuperSU.apk

    adb shell chown root:root /system/app/SuperSU.apk

    adb reboot
     
    #6 Deusolux, Aug 20, 2018
    Last edited: Aug 20, 2018
  7. bcrichster

    bcrichster ROMinator
    Moderator

    Rooting the device itself will add its own su binary..

    Edit: Changing from KingRoot to SuperSu isn't easy at all. In fact, nearly impossible. BUT you can use King-o-Root instead and that allows su changeovers easily
     
    Jfalls63 likes this.
  8. Deusolux

    Deusolux Lurker
    Thread Starter

    yeah, i've tried king-o-root but it said my device wasn't compatible. There i a guy on youtube that switched from KingRoot to SuperSU with a shell script, he had it in the description. I downloaded it and tried it. It did uninstall KingRoot and installed SuperSU, but when I ran the app I had to update the binaries; however, it failed.

    Results from your earlier suggestion:
    Image #1 Not rooted
    Image #2 Rooted with KingoRoot
    Image #3 su reboot disemmcwp
    Image #4 Not rooted
    Image #5 Rooted again with KingoRoot
    Image #6 su reboot emmcwpenab
    Image #7 Not rooted

    Conclusion: rooting after disabling emmc write protection failed
     

    Attached Files:

    #8 Deusolux, Aug 20, 2018
    Last edited: Aug 20, 2018
  9. bcrichster

    bcrichster ROMinator
    Moderator

    Uhh.. Don't do reboot emmcwpenab cmd unless you intentionally want to enable write protection, which will prevent any Rooting. Try again and only do the cmd I gave ya the 1st time, then try Root app again

    Also.. To transfer su managers, ya need to install the new one and allow su perms before uninstalling the other
     
  10. Deusolux

    Deusolux Lurker
    Thread Starter

    ok ill try it in a little bit. ill update you with the results. Thanks for taking the time to help! You're awesome

    EDIT: It didn't work. Rooted, su reboot disemmcwp, rooted again, rebooted, checked root
    EDIT2: It keeps saying "Unfortunately, the process <multiple processes> has stopped." after I rooted it again.
     
    #10 Deusolux, Aug 20, 2018
    Last edited: Aug 20, 2018
  11. Deusolux

    Deusolux Lurker
    Thread Starter

    It stopped after reboot. tried running kingo root. apk failed. downloaded kingo.exe and tethered to pc. pc kingo said it rooted but it failed to install any su binary or app to manage it.

    EDIT: Just found this on KingoRoot website.

    "Device with locked bootloader always have some form of internal memory write protection. It will prevent unauthorized user from modifying device system. During the process of gaining root access on a device the write-protected memory, the initial root access is temporary due to the complexities of unlocking memory write access. Any unofficial files (including the most important file "su binary" and "superuser.apk" installed on system partition to root access) will be removed by cycling power, such as rebooting."

    So, i guess that's why the root wasn't sticking. Do you guys know how to unlock the bootloader? :)
     
    #11 Deusolux, Aug 20, 2018
    Last edited: Aug 20, 2018
Loading...

Share This Page

Loading...