Install root with comandline only - SuperSU

I have a Nexus 5X on the Developer Preview 5 and twrp can't mount the data partition to flash SuperSu so could I flash SuperSu using the command line only

PKSYHR said:
I have a Nexus 5X on the Developer Preview 5 and twrp can't mount the data partition to flash SuperSu so could I flash SuperSu using the command line only
Click to expand...
Click to collapse
It can't mount the /data partition because your probably encrypted. I'd recommend unencrypting before proceeding on the N Previews as I constantly had problems encrypted.

Okay thanks I'll try that

So I would have to flash factory then root then disable encryption then return to the developer preview correct?

PKSYHR said:
So I would have to flash factory then root then disable encryption then return to the developer preview correct?
Click to expand...
Click to collapse
No you'd run fastboot format userdata which wipes your ENTIRE INTERNAL STORAGE beware. Make backups.

So the developer preview doesn't force encryption at boot?

Or would I format user data then flash supersu then boot into N 5

PKSYHR said:
Or would I format user data then flash supersu then boot into N 5
Click to expand...
Click to collapse
This.

Okay thank you very much for all the help

Related

Data partition F2FS on stock?

Hell, I've decided to restore stock on my Moto and sell it, as I'm pretty sure I'm going to settle with the OnePlus One I also got with their offers.
I think I recall while flashing ROMs for this device I had to reformat Data to EXT4, but now when I go to change the FS again I don't have option for F2FS.
Could one of you please load up recovery, go into Wipe > Advanced Wipe > check "Data" choose "Repair or Change File System" and verify what the line "current file system" says for you?
Would be much appreciated.
Shemploo said:
Hell, I've decided to restore stock on my Moto and sell it, as I'm pretty sure I'm going to settle with the OnePlus One I also got with their offers.
I think I recall while flashing ROMs for this device I had to reformat Data to EXT4, but now when I go to change the FS again I don't have option for F2FS.
Could one of you please load up recovery, go into Wipe > Advanced Wipe > check "Data" choose "Repair or Change File System" and verify what the line "current file system" says for you?
Would be much appreciated.
Click to expand...
Click to collapse
Mine says EXT4.
My data partition is on F2FS on stock lollipop.
sivarticus85 said:
Mine says EXT4.
Click to expand...
Click to collapse
Which partition did you check?
divergens said:
My data partition is on F2FS on stock lollipop.
Click to expand...
Click to collapse
I wonder why TWRP does not have option to change to F2FS, I'm using 2.8.4.1
Shemploo said:
I wonder why TWRP does not have option to change to F2FS, I'm using 2.8.4.1
Click to expand...
Click to collapse
I just tried booting TWRP 2.8.4.0 and I don't see an option for F2FS either. Was this available before in older versions of TWRP? I never bother to switch from the stock recovery to TWRP at any point.
Shemploo said:
Which partition did you check?
Click to expand...
Click to collapse
You asked for the Data partition.
I brought it up in the TWRP thread. Maybe someone there can answer this for us.
sivarticus85 said:
You asked for the Data partition.
I brought it up in the TWRP thread. Maybe someone there can answer this for us.
Click to expand...
Click to collapse
divergens said:
I just tried booting TWRP 2.8.4.0 and I don't see an option for F2FS either. Was this available before in older versions of TWRP? I never bother to switch from the stock recovery to TWRP at any point.
Click to expand...
Click to collapse
Yes, it was in a previous version, I remember changing partitions cause of ROM not working.
Its interesting that both of your partitions are different. Did neither of you change them?
Shemploo said:
Yes, it was in a previous version, I remember changing partitions cause of ROM not working.
Its interesting that both of your partitions are different. Did neither of you change them?
Click to expand...
Click to collapse
I never purposefully changed partitions via TWRP, in fact I never have used TWRP on my Moto X yet. All the flashing I have done was with fastboot.
Now that you mention it, I remember my data partition being EXT4 back in kitkat. I don't know if it changed because of lollipop. I did flash a lollipop image from motofirmware at one point. However, then I went back to kitkat using Motorola's official kitkat image and took the OTA to lollipop.
Yeah I never purposefully changed it either. Twrp just doesn't format it to f2fs like it should. I wonder if doing a factory reset from within the stock recovery will revert it back?
Edit: Yeah that did it. Stock recovery reverts it back to f2fs. Verified by checking it twrp again afterward. That's the only way to get back as of right now.
Ha! - I got the same thing, I booted the latest TWRP and checked the partition, it's listed as F2FS, it would seem that 4.4.x is EXT4 and the upgrade to Lollipop changes is to F2FS, very interesting.
UPDATE: It looks like the option to change FS to F2FS is there when you install a theme, I got it under TWRP Materiel theme, but it seems that this might just be a button designed in case the function is introduced as it actually does not convert the FS.
UPDATE2: After loading the Material theme to get the Change FS to F2FS, the log says "mkfs.f2fs binary not found, using rm -rf to wipe"
Seems something is missing from the latest TWRP release?
I think twrp don't have f2fs because its not really cross platform mountable. Ext4 can be mounted easily with windows, Linux or Mac so it makes things easier for "devs", " tweakers" to just have ext4 support.

[Q] Forced encryption question

Hi,
I have a few questions about the forced encryption on the nexus 6. I have an unlocked bootloader, and have cm12.1 installed. SELinux is Enforcing and I have no password/pin on the lockscreen.
How do I know if it is encrypted?
If it is how can I decrypt?
If I decrypt will it erase my files?
What about updating to the latest CM nightly?
Thanks
kevkid said:
Hi,
I have a few questions about the forced encryption on the nexus 6. I have an unlocked bootloader, and have cm12.1 installed. SELinux is Enforcing and I have no password/pin on the lockscreen.
How do I know if it is encrypted?
If it is how can I decrypt?
If I decrypt will it erase my files?
What about updating to the latest CM nightly?
Thanks
Click to expand...
Click to collapse
first off, the n6 encrypts at first boot. you can go into your main settings, security, and see that its encrypted. you can decrypt by flaahing a kernel that allows for decryption, and then format your storage. this will delete everything in your storage, so make a backup. this kernel has to be cm compatible, or cm wont boot up with it. after, you can update in recovery, by flashing the update, gapps, and that same kernel.
kevkid said:
Hi,
I have a few questions about the forced encryption on the nexus 6. I have an unlocked bootloader, and have cm12.1 installed. SELinux is Enforcing and I have no password/pin on the lockscreen.
How do I know if it is encrypted?
If it is how can I decrypt?
If I decrypt will it erase my files?
What about updating to the latest CM nightly?
Thanks
Click to expand...
Click to collapse
Like @simms22 already said, you need to find a kernel that doesn't force encryption and is CM compatible. Once you've found that, here's what you need to do:
1) Connect your device to your PC
2) Backup anything and everything you are not willing to erase
3) Reboot to recovery
4) Format Data in recovery
5) Reboot back into recovery
6) Flash ROM
7) Flash Gapps
8) Flash SuperSu (if you need it)
9) Flash Kernel
10) Reboot system
At this point if you navigate to the security options in your settings, you should have the option to encrypt rather than it saying the device is encrypted.
You mentioned SELinux set to enforcing. While this won't cause any issues at all with decrypting the device, it can cause issues with some apps. If you'd like to change it, get a terminal emulator from the playstore and type the following:
Code:
su 0 setenforce 0
Or get the SELinus ModeChanger app from here http://forum.xda-developers.com/showthread.php?t=2524485 to change selinux from enforcing to permissive.
when you format Data in recovery does this mean it will erase ALL files in internal storage? if yes does that mean the rom in Download will be delete as well?
kalali said:
when you format Data in recovery does this mean it will erase ALL files in internal storage? if yes does that mean the rom in Download will be delete as well?
Click to expand...
Click to collapse
everything in your storage gets deleted. it wont discriminate, and save your rom. itll just clear everything out. thats why you should flash the rom, gapps, and the kernel BEFORE you format storage.
simms22 said:
everything in your storage gets deleted. it wont discriminate, and save your rom. itll just clear everything out. thats why you should flash the rom, gapps, and the kernel BEFORE you format storage.
Click to expand...
Click to collapse
thanks for quick reply but my question is if it delete everything then i have to transfer rom, gapps kernel from computer to phone again before i can follow step 6 as PryorDaniel posted above.
1) Connect your device to your PC
2) Backup anything and everything you are not willing to erase
3) Reboot to recovery
4) Format Data in recovery
5) Reboot back into recovery
6) Flash ROM
7) Flash Gapps
8) Flash SuperSu (if you need it)
9) Flash Kernel
10) Reboot system
kalali said:
thanks for quick reply but my question is if it delete everything then i have to transfer rom, gapps kernel from computer to phone again before i can follow step 6 as PryorDaniel posted above.
1) Connect your device to your PC
2) Backup anything and everything you are not willing to erase
3) Reboot to recovery
4) Format Data in recovery
5) Reboot back into recovery
6) Flash ROM
7) Flash Gapps
8) Flash SuperSu (if you need it)
9) Flash Kernel
10) Reboot system
Click to expand...
Click to collapse
if you follow that way, youll have to push everything to your phone after. or, you can flash the rom, gapps, supersu, and the kernel then format your storage after, then boot up. either way, both work except youd have to push it all to your phone then flash.
i would prefer your way better. i didn't know we can format the storage/data after flashing rom, gapps, kernel and it will boot up.
thanks again.
kalali said:
i would prefer your way better. i didn't know we can format the storage/data after flashing rom, gapps, kernel and it will boot up.
thanks again.
Click to expand...
Click to collapse
yea, you can. i know others have done it this way, but my device is still encrypted. formatting your storage actually wont remove your rom(gapps, supersu, and kernel), so youll be alright. what id do is flash everything, then boot up to make sure it boots, then go back and format your storage.
---------- Post added at 06:38 PM ---------- Previous post was at 06:36 PM ----------
if, in the worst case scenario it wont boot, then id go back and push everything to the phone and flash again. but thats just a worst case scenario.
simms22 said:
yea, you can. i know others have done it this way, but my device is still encrypted. formatting your storage actually wont remove your rom(gapps, supersu, and kernel), so youll be alright. what id do is flash everything, then boot up to make sure it boots, then go back and format your storage.
---------- Post added at 06:38 PM ---------- Previous post was at 06:36 PM ----------
if, in the worst case scenario it wont boot, then id go back and push everything to the phone and flash again. but thats just a worst case scenario.
Click to expand...
Click to collapse
I can assure you that this does work.
You can use simms22 way, and to be honest that's how I'd prefer to do it. My device just didn't play nice when I initially tried decrypting that way :/
Hence how/why I went with the other more tedious route.
PryorDaniel said:
You can use simms22 way, and to be honest that's how I'd prefer to do it. My device just didn't play nice when I initially tried decrypting that way :/
Hence how/why I went with the other more tedious route.
Click to expand...
Click to collapse
more tedious, i wont really call it that. as it takes a few extra seconds to adb push it to the phone(or other ways). id just say its another option instead
Thank you very much. Worked perfectly
simms22 said:
more tedious, i wont really call it that. as it takes a few extra seconds to adb push it to the phone(or other ways). id just say its another option instead
Click to expand...
Click to collapse
Funny thing i read is that users spend an hour to decrypt and setup the phone and then flash CM12.1 wich encrypts the phone again

TWRP - E:failed to mount /system (Invalid argument ) - but OOS still boots fine.

I just restored a TWRP backup which seemed to work properly
(OS boots and works as normal) but in TWRP I can't mount system
from the mount menu and when I try to reboot it warns me - no
OS installed, I'd understand if it wouldn't boot but it does, do I
need to wipe like a TWRP cache or something?
the-blind-bandit said:
I just restored a TWRP backup which seemed to work properly
(OS boots and works as normal) but in TWRP I can't mount system
from the mount menu and when I try to reboot it warns me - no
OS installed, I'd understand if it wouldn't boot but it does, do I
need to wipe like a TWRP cache or something?
Click to expand...
Click to collapse
Flash SuperSU or magisk and the kernel all should be good
genuine55 said:
Flash SuperSU or magisk and the kernel all should be good
Click to expand...
Click to collapse
I already had supersu installed and ive just reflashed the kernel which made no difference apart from tripping dm-verity again (ugh).
Any other ideas?
Create a backup if you didn't. Wipe System (only system nothing else), then click on repair FAT. Mount system check box should be ok now...then restore System (only system) from your backup.
One question. Is it for the encryption system? Does it decrypt it?

How to go from OOS 5.0 to Stock Nouga

How to go from OOS 5.0 to Stock Nouga
Since you've made the spelling error twice, its Nougat, not "Nouga.".
I think the best way you could do it is flash the special Open Beta build on the Open Beta thread and then flash the stable build zip.
Whichever way you do the reversion, you will lose partial data, as N and O do not support each others app installations.
Z.boy said:
How to go from OOS 5.0 to Stock Nougat
Click to expand...
Click to collapse
If you are unlocked bootloader, flash twrp 3.1.1-2 and clear dalvik data cache and system, and just flash them through twrp
dont use twrp 3.2.0-0 because you cant install magisk, it shows installed but magisk doesnt seem to be recognized in apps
I've just done that, and everything seems working flawlessly
Pls do hit thanks if i help you
izukamikain said:
If you are unlocked bootloader, flash twrp 3.1.1-2 and clear dalvik data cache and system, and just flash them through twrp
dont use twrp 3.2.0-0 because you cant install magisk, it shows installed but magisk doesnt seem to be recognized in apps
I've just done that, and everything seems working flawlessly
Pls do hit thanks if i help you
Click to expand...
Click to collapse
Does your solution avoid erasing internal storage? Because that's the part that's preventing me as it can take too long getting my backups into the phone again.
rebelpixel said:
Does your solution avoid erasing internal storage? Because that's the part that's preventing me as it can take too long getting my backups into the phone again.
Click to expand...
Click to collapse
i never format my internal sdcard partition
it's taking too long time to backup and restore it again
as i said, only format dalvik cache data and system thru twrp and you're good to go
download special edition nougat revert zip file and flash it via recovery
http://oneplusroms.s3.amazonaws.com...337224&Signature=BEA4IHd/rVFqoPd2gh7EvwaoSeg=
notes :
The build will wipe app and cache data, but Internal Storage will be saved (ie: pictures and files)
Users who revert their device back to the special build can still OTA update the device to Android O build at a later date.
Steps to revert:
Download special build
Copy to Internal storage
Reboot to recovery Mode to install
Choose “Install from Local”
Choose the downloaded build to install

Remove Magisk without formatting data

I got a new phone two days ago with zui rom installed
This rom uses forced encryption that can't be decrypted through twrp recovery.
Yesterday i went through an issue with a module that froze android after boot and couldn't unlock it to remove the module!
Data partition is encrypted under recovery and i can't remove the module manually through file manager and the only option i had is to format data partition which result in a loss of all files.
For future if i went through such issue; is there a way i could remove or disable magisk through recovery without mounting data partition?
allouh said:
I got a new phone two days ago with zui rom installed
This rom uses forced encryption that can't be decrypted through twrp recovery.
Yesterday i went through an issue with a module that froze android after boot and couldn't unlock it to remove the module!
Data partition is encrypted under recovery and i can't remove the module manually through file manager and the only option i had is to format data partition which result in a loss of all files.
For future if i went through such issue; is there a way i could remove or disable magisk through recovery without mounting data partition?
Click to expand...
Click to collapse
You should be able to just flash the boot.img
Sent from my Moto E (4) using Tapatalk
sd_shadow said:
You should be able to just flash the boot.img
Sent from my Moto E (4) using Tapatalk
Click to expand...
Click to collapse
I tested this while writing this post , i flashed boot.img through fastboot but it gave me Red Boot screen error (Device Corrupt) and when device run magisk still working

Categories

Resources