Related
I'm using the most recent version of TWRP for the 5x. I usually check boot, system, data which I believe are the default items that are checked for making an nandroid. I also use enable compression to try and shrink the file. The last few times I have made a nandroid then tried to restore it, there have been issues. One time it wiped out all my text messages, another time it asked me in the beginning for my start up pattern to unlock the phone and kept error despite it being correct. I've never had these issues before making and restoring nandroids on my Nexus 6. Is anyone else having these issues ? Do I need to backup the vendor image as well ?
I'm backing up directly to a USB Thumbdrive from OTG if that matters
You need to back up vendor also.
Also you should use the unofficial TWRP 3.0.2-3 as 3.0.2-2 has bug with larger partitions.
So I decided to take my first steps to rooting, custom recoveries and ROMs and followed a stickied thread on the OnePlus forums here.
I firstly downgraded from Nougat to Marshmallow using the official Stock ROM. Afterwards, I flashed the recovery.img for TWRP from the official TWRP site. All is good.
I boot into TWRP and it asks me for a decryption password, I enter it and get "Incorrect Password". I try to boot normally and the same thing happens - weird. One member on another forum, from another question, suggested to wipe data through TWRP, and so I did. This cleared the decryption message through TWRP but then I got a boot loop with a simple message of "Decryption Unsuccessful". I press reset and the phone repeats everything.
Anywho, I flashed stock recovery and a fresh Marshmallow ROM which sorted my phone back to safeland.
Question is, how can I bypass all this? I followed the guide to the tee but no mention of this. I'm a n00b to flashing and only really know as far as the instructions on the OnePlus support page for flashing a stock ROM.
Use TWRP 3.0.4-1, it has decryption support.
If you are planning on rooting with SuperSU, use v2.79, not the first one that pops up when you Google "SuperSU". Not sure why, but the first link that pops up on Google directs you to an older version on Chainfire's site, which causes bootloops if you flash it on Nougat.
Other than the versions of the above files, the steps in rooting are the same as in the original guide.
I personally keep my phone decrypted, since I don't have anything super important on it. Not only do I not run into any encryption issues, the phone boots faster is decrypted. Decrypting does have its downsides though (you have to wipe your phone, also less security), so I would recommend that you research about it some more prior to deciding. There are methods of decrypting without losing all data though.
Anova's Origin said:
Use TWRP 3.0.4-1, it has decryption support.
If you are planning on rooting with SuperSU, use v2.79, not the first one that pops up when you Google "SuperSU". Not sure why, but the first link that pops up on Google directs you to an older version on Chainfire's site, which causes bootloops if you flash it on Nougat.
Other than the versions of the above files, the steps in rooting are the same as in the original guide.
I personally keep my phone decrypted, since I don't have anything super important on it. Not only do I not run into any encryption issues, the phone boots faster is decrypted. Decrypting does have its downsides though (you have to wipe your phone, also less security), so I would recommend that you research about it some more prior to deciding. There are methods of decrypting without losing all data though.
Click to expand...
Click to collapse
Thanks for the reply. I agree with you, I'm not fussed about Encryption and would rather have my device decrypted, the problem is I'm not sure how to decrypt it, or if it would be possible to revert and re-encrypt afterwards. As far as I know, Encryption is enabled by default on anything Marshmallow. In addition whether Decrypting would cause further issues down the line.
My reasoning for reverting to Marshmallow was Xposed and is the main reason I'd like to root with the possibility of flashing a new ROM.
In reply to your other points, I used the official TWRP from here if that makes a difference or should I be using the build you provided, surely if I can decrypt my device it makes it pointless for something with decryption support, yes?
Nonetheless, appreciate the reply!
The TWRP build from the official site is a little outdated, it is known to have decryption issues. Try the one from the XDA page.
To decrypt, you have to either root or flash a dm-verity-no-encrypt.zip that is floating somewhere around on XDA, there's probably a copy of it in the root guide in your first post. If you have no data on your phone that you mind losing (after saving a copy somewhere off your phone), the easiest way to decrypt is to go into TWRP and wipe your /data partition. If your phone is rooted or flashed with the no-encrypt.zip, the /data partition will not be encrypted the next time you boot.
There is a way to decrypt while maintaining your data, you can follow this guide. It involved saving a nandroid (saves all info in /data partition except /data/media, where all your media files and certain app data is stored). You can then save anything in /data/media by transferring it to your computer prior to wipe. You can actually restore a nandroid from an encrypted phone onto the same decrypted phone without having all your files encrypted. You can then transfer all your files from the /data/media folder back to your phone, though you'll need to give all the files and folders the proper permissions.
Once decrypted, you phone will remain decrypted until you flash OOS again, such as when updating. To prevent the phone from automatically encrypting its /data partition, you'll have to flash SuperSU or the no-encrypt.zip immediately after flashing an OOS ROM everytime you flash it.
If at some point down the road, you'd like to encrypt your phone again, that's really easy. You can go into the settings app -> secuity -> scroll to bottom to "encrypt". Clicking that option will encrypt your phone without data loss.
I personally have not had any issues after decrypting my phone. I can't speak for others though.
Anova's Origin said:
The TWRP build from the official site is a little outdated, it is known to have decryption issues. Try the one from the XDA page.
To decrypt, you have to either root or flash a dm-verity-no-encrypt.zip that is floating somewhere around on XDA, there's probably a copy of it in the root guide in your first post. If you have no data on your phone that you mind losing (after saving a copy somewhere off your phone), the easiest way to decrypt is to go into TWRP and wipe your /data partition. If your phone is rooted or flashed with the no-encrypt.zip, the /data partition will not be encrypted the next time you boot.
There is a way to decrypt while maintaining your data, you can follow this guide. It involved saving a nandroid (saves all info in /data partition except /data/media, where all your media files and certain app data is stored). You can then save anything in /data/media by transferring it to your computer prior to wipe. You can actually restore a nandroid from an encrypted phone onto the same decrypted phone without having all your files encrypted. You can then transfer all your files from the /data/media folder back to your phone, though you'll need to give all the files and folders the proper permissions.
Once decrypted, you phone will remain decrypted until you flash OOS again, such as when updating. To prevent the phone from automatically encrypting its /data partition, you'll have to flash SuperSU or the no-encrypt.zip immediately after flashing an OOS ROM everytime you flash it.
If at some point down the road, you'd like to encrypt your phone again, that's really easy. You can go into the settings app -> secuity -> scroll to bottom to "encrypt". Clicking that option will encrypt your phone without data loss.
I personally have not had any issues after decrypting my phone. I can't speak for others though.
Click to expand...
Click to collapse
Brilliant. On a side note, I'm sure I did a /data wipe, which caused the boot loop I was having - weird. Anywho, I'll try the TWRP build you mentioned and see how I get on. I did watch one video which suggested to use the fastboot erase userdata as another way of unencrypting the phone.
Either way I'll give it all a try!
Anova's Origin said:
The TWRP build from the official site is a little outdated, it is known to have decryption issues. Try the one from the XDA page.
To decrypt, you have to either root or flash a dm-verity-no-encrypt.zip that is floating somewhere around on XDA, there's probably a copy of it in the root guide in your first post. If you have no data on your phone that you mind losing (after saving a copy somewhere off your phone), the easiest way to decrypt is to go into TWRP and wipe your /data partition. If your phone is rooted or flashed with the no-encrypt.zip, the /data partition will not be encrypted the next time you boot.
There is a way to decrypt while maintaining your data, you can follow this guide. It involved saving a nandroid (saves all info in /data partition except /data/media, where all your media files and certain app data is stored). You can then save anything in /data/media by transferring it to your computer prior to wipe. You can actually restore a nandroid from an encrypted phone onto the same decrypted phone without having all your files encrypted. You can then transfer all your files from the /data/media folder back to your phone, though you'll need to give all the files and folders the proper permissions.
Once decrypted, you phone will remain decrypted until you flash OOS again, such as when updating. To prevent the phone from automatically encrypting its /data partition, you'll have to flash SuperSU or the no-encrypt.zip immediately after flashing an OOS ROM everytime you flash it.
If at some point down the road, you'd like to encrypt your phone again, that's really easy. You can go into the settings app -> secuity -> scroll to bottom to "encrypt". Clicking that option will encrypt your phone without data loss.
I personally have not had any issues after decrypting my phone. I can't speak for others though.
Click to expand...
Click to collapse
Thought I'd post a little update, I managed to install TWRP and Root. I used fastboot erase userdata which fixed my decryption issue - everything was working! Back to stock Nougat now but am going to be trying Magisk.
createTarFork() process ended with ERROR=255
First, make sure you disable finger print and change security to swipe or none. Also, make sure you are not encrypting your backup. I don't think that feature is working, at least it's not for me.
Download terminal emulator, then type
su
pm remove-user 999
That will delete all 999 folders which causes issues with TWRP, its a parallel app issues, so as long as u don't use parallel apps u r fine
the solution to this was to boot to your previous rom that u have made nandroid backup with and then setting up the same password/pin in settings > security. When you then boot into twrp it will ask you for the pin/password to decrypt your data partition and then you can flash the nandroid backup(you have to have the same password there). here it is obvious that you are trying to flash data partition that uses different encryption password (in case of stock rom there is non) and this obviously wont happen.
I sometimes have this issue if the TWRP backup gets stuck at the end of backing up /data. The only solution for me is fo abort and start the backup again. After 2 to 5 times it works.
Hello
This is a TWRP recovery for Motorola Moto G5 Cedric for arm64 ROMS, with encryption support, backup support for persist and efs partitions and possibility to flash/backup logo boot image.
I need review and test, especially for the storage decryption and/with LineageOS fingers-crossed. I was able to test it on my device (XT1676 3Go).
It is my first ROM so it is possible that there are bugs.
- Be carefull, there are problems with the backup system :
Just wish to come here and tell you guys to AVOID using this recovery, it seems to have a serious bug.
I just backed up my entire data partition (and enable digest verification) and restored the partition afterwards and the phone didn't boot.
Then I tried restoring it with verification enabled and the hashes didn't match.
In other words, for some reason, the generated backup was corrupt.
- freeZbies
Click to expand...
Click to collapse
Changelog
TWRP 3.2.3-2
add sdcardfs
add FB2PNG for screenshot
fix brightness path and define it at 160
fix time zone error
fix incorrect lun path for USB
You can download it here :
TWRP 3.2.3-2 (md5: 0dbd3846593ae907d3391596876c1f35)
TWRP 3.2.3-1 (md5: 404b54d27653b5a1ec5b59023f53d3cb)
TWRP 3.2.3-0
Sources :
https://github.com/Akipe/twrp_android_device_motorola_cedric
https://github.com/Akipe/twrp_android_device_motorola_msm8937-common
Manifest :
https://github.com/Akipe/android_development_manifest
Would it be possible for you to compile a version capable of backing up all partition, including persist and efs? see here: https://forum.xda-developers.com/showpost.php?p=78695191&postcount=95
Guttergorm said:
Would it be possible for you to compile a version capable of backing up all partition, including persist and efs? see here: https://forum.xda-developers.com/showpost.php?p=78695191&postcount=95
Click to expand...
Click to collapse
Hi!
Sorry for the delay, I added the functions you wanted. Can you try and tell me if everything is ok?
Hi,
tested your recovery image with my installed LOS 15.1. (32bit) Device: XT1676 16GB P5
- storage decryption: OK
- backup support for persist and efs partitions and possibility to flash/backup logo boot image: OK
nice work, thx for you effort
mikefive said:
Hi,
tested your recovery image with my installed LOS 15.1. (32bit) Device: XT1676 16GB P5
- storage decryption: OK
- backup support for persist and efs partitions and possibility to flash/backup logo boot image: OK
nice work, thx for you effort
Click to expand...
Click to collapse
Thx for testing :good:
Akipe can u help us to build treble rom for cedric???
Works nicely, thanks.
I just tested it and it decrypts my internal storage normally.
Just wish to come here and tell you guys to AVOID using this recovery, it seems to have a serious bug.
I just backed up my entire data partition (and enable digest verification) and restored the partition afterwards and the phone didn't boot.
Then I tried restoring it with verification enabled and the hashes didn't match.
In other words, for some reason, the generated backup was corrupt.
Of course I could make another test but it'll take just a long time to backup everything again, so if anyone wants to test it, feel free, but beware, you could have a hell of a headache finding out the backups you made were useless.
freeZbies said:
Just wish to come here and tell you guys to AVOID using this recovery, it seems to have a serious bug.
I just backed up my entire data partition (and enable digest verification) and restored the partition afterwards and the phone didn't boot.
Then I tried restoring it with verification enabled and the hashes didn't match.
In other words, for some reason, the generated backup was corrupt.
Of course I could make another test but it'll take just a long time to backup everything again, so if anyone wants to test it, feel free, but beware, you could have a hell of a headache finding out the backups you made were useless.
Click to expand...
Click to collapse
Hello ! Thank you for your test and sorry for your backup
I will test the backup system and add a warning
freeZbies said:
Just wish to come here and tell you guys to AVOID using this recovery, it seems to have a serious bug.
I just backed up my entire data partition (and enable digest verification) and restored the partition afterwards and the phone didn't boot.
Then I tried restoring it with verification enabled and the hashes didn't match.
In other words, for some reason, the generated backup was corrupt.
Of course I could make another test but it'll take just a long time to backup everything again, so if anyone wants to test it, feel free, but beware, you could have a hell of a headache finding out the backups you made were useless.
Click to expand...
Click to collapse
I have backup up data partition from my TWRP, reboot one time to recovery, restore the data backup with digest verification, and reboot to LineageOS, with no problem (my rom is LineageOS 16.0 without encryption.)
I think there may be 2 errors (maybe more) :
1) There is a problem with data restore when encryption is enable. I can not test this scenario for now, but i will do it as soon as i can
2) Was your backup stored on your SD card? if so, it is possible that the sd card may be damaged, because it is too old or of poor quality (more info here : https://photo.stackexchange.com/questions/40489/what-causes-an-sd-card-to-go-corrupt )
if you have other information or other ideas, do not hesitate to share it!
if people want to participate, try to save the data partition and restore it, especially with the encrypted partition :good::good:
be careful, make a backup of your data before test
Akipe said:
I have backup up data partition from my TWRP, reboot one time to recovery, restore the data backup with digest verification, and reboot to LineageOS, with no problem (my rom is LineageOS 16.0 without encryption.)
I think there may be 2 errors (maybe more) :
1) There is a problem with data restore when encryption is enable. I can not test this scenario for now, but i will do it as soon as i can
2) Was your backup stored on your SD card? if so, it is possible that the sd card may be damaged, because it is too old or of poor quality (more info here : https://photo.stackexchange.com/questions/40489/what-causes-an-sd-card-to-go-corrupt )
if you have other information or other ideas, do not hesitate to share it!
if people want to participate, try to save the data partition and restore it, especially with the encrypted partition :good::good:
be careful, make a backup of your data before test
Click to expand...
Click to collapse
I agree it may be any of the 2 problems.
My data partition was indeed encrypted, and yes, my SD card is not what I would call genuine, though I think that's not the case since the card is relatively new and I never had any problem related to data corruption.
Anyways, thanks for your effort.
freeZbies said:
I agree it may be any of the 2 problems.
My data partition was indeed encrypted, and yes, my SD card is not what I would call genuine, though I think that's not the case since the card is relatively new and I never had any problem related to data corruption.
Anyways, thanks for your effort.
Click to expand...
Click to collapse
I have test backup the data partition with encryption on LineageOS 16 (arm64), backup and restore work without issue
What ROM did you use when you made the backup, and with what arch (arm or arm64) ?
Akipe said:
I have test backup the data partition with encryption on LineageOS 16 (arm64), backup and restore work without issue
What ROM did you use when you made the backup, and with what arch (arm or arm64) ?
Click to expand...
Click to collapse
I was on stock oreo, so its arm, not arm64
freeZbies said:
I was on stock oreo, so its arm, not arm64
Click to expand...
Click to collapse
Oh ok, there are chances that's why the backup did not work .
This recovery is mainly intended for arm64 rom !
Just wanted to say that everything worked well for me in backing up and restoring the OmniROM, on both decrypted and encrypted phone.
Thanks @Akipe for the great job
Can you update it to latest TWRP?
Sent from my cedric using XDA Labs
forgot password to decrypt??
hi,
first, sorry if this is the wrong place to post this. right now, when i install the 64 bit twrp i am asked for a password to decrypt my data. i have tried some passwords i think i would have used, but those don't work and i get a message also saying that the default password didn't work - i haven't typed a default password, though, so i assume there is a default one that twrp tries automatically. in the past, i did try a rom requiring 64 bit twrp and i am guessing i set a password other then the default to encrypt/decrypt, but i went back to stock without issues so have not thought about the password and cannot remember what i would have used. i wanted to try dotos on my phone, which i assume requires 64 twrp because i got error 255 when i tried to flash without twrp64. so i installed twrp64 but cannot get any further. so here are my questions:
is there any way to decrypt the data if i forgot my password?
if not, can i format the data while encrypted to install the new rom? if i can do that, what should i back up? i have pictures and other necessary files backed up, so i am not worried about completely wiping the phone to start over. however, should i back anything else up before formatting? do i need to worry about losing imei or losing any partitions that would make phone inoperable or not have any signal? should i back up with twrp64 or the non-64 bit twrp currently installed? any help or point in the right direction is greatly appreciated.
tia,
nurvus
nurvus said:
hi,
first, sorry if this is the wrong place to post this. right now, when i install the 64 bit twrp i am asked for a password to decrypt my data. i have tried some passwords i think i would have used, but those don't work and i get a message also saying that the default password didn't work - i haven't typed a default password, though, so i assume there is a default one that twrp tries automatically. in the past, i did try a rom requiring 64 bit twrp and i am guessing i set a password other then the default to encrypt/decrypt, but i went back to stock without issues so have not thought about the password and cannot remember what i would have used. i wanted to try dotos on my phone, which i assume requires 64 twrp because i got error 255 when i tried to flash without twrp64. so i installed twrp64 but cannot get any further. so here are my questions:
is there any way to decrypt the data if i forgot my password?
if not, can i format the data while encrypted to install the new rom? if i can do that, what should i back up? i have pictures and other necessary files backed up, so i am not worried about completely wiping the phone to start over. however, should i back anything else up before formatting? do i need to worry about losing imei or losing any partitions that would make phone inoperable or not have any signal? should i back up with twrp64 or the non-64 bit twrp currently installed? any help or point in the right direction is greatly appreciated.
tia,
nurvus
Click to expand...
Click to collapse
You need to format data
Push back button when it asks for decrypt
Goto wipe and select the option on the right to format data
This will erase everything on internal storage so copy any files you want to keep to pc first (pictures music etc)
Once formatted data restart back to recovery to check encryption has been removed and data partition is mountable
TWRP backups do not save personal files (pictures music etc) They only backup data and system files (and other named partitions)
Once you have flashed a new rom you can encrypt again if you want to via the security settings menu in phone settings
TheFixItMan said:
You need to format data
Push back button when it asks for decrypt
Goto wipe and select the option on the right to format data
This will erase everything on internal storage so copy any files you want to keep to pc first (pictures music etc)
Once formatted data restart back to recovery to check encryption has been removed and data partition is mountable
TWRP backups do not save personal files (pictures music etc) They only backup data and system files (and other named partitions)
Once you have flashed a new rom you can encrypt again if you want to via the security settings menu in phone settings
Click to expand...
Click to collapse
thanks for the quick response! and just for clarification and for me to be sure, should i back up any partitions before formatting? right now i have 32 (or non64 i guess) bit twrp installed, stock rom and bootloader unlocked. do i need to take any precautions with data/imei/signal before reinstalling twrp64, formatting data, and installing a new rom? if it matters any i have the international version of the moto g5. thanks again!!
nurvus
nurvus said:
thanks for the quick response! and just for clarification and for me to be sure, should i back up any partitions before formatting? right now i have 32 (or non64 i guess) bit twrp installed, stock rom and bootloader unlocked. do i need to take any precautions with data/imei/signal before reinstalling twrp64, formatting data, and installing a new rom? if it matters any i have the international version of the moto g5. thanks again!!
nurvus
Click to expand...
Click to collapse
Backup efs if you want to preserve your current emei state or need to restore it in future
I got a new device by RMA and now I want to copy my nandroid backup made with TWRP to the new one.
Which partitions do I have to copy?
Most of the partitions are system based, so don't touch them. All you would want to copy is data, but I am not even sure that would work, without a boot loop? I keep all my data backed up with Titanium. And Google drive would restore most of what you had on your phone as long as you were allowing setting>system>backup.
Sui77 said:
I got a new device by RMA and now I want to copy my nandroid backup made with TWRP to the new one.
Which partitions do I have to copy?
Click to expand...
Click to collapse
Data, as it is the one where your settings and app updates are stored. Just be sure the new device is running the same version of Android as the old.
Droid_Nut said:
Most of the partitions are system based, so don't touch them. All you would want to copy is data, but I am not even sure that would work, without a boot loop? I keep all my data backed up with Titanium. And Google drive would restore most of what you had on your phone as long as you were allowing setting>system>backup.
Click to expand...
Click to collapse
Restoring a nandroid backup of the data partition to another, identical, device will work without causing a bootloop given the precautions I describe above. Do note however that Google's backup only restores items acquired through the Play Store. Alternative app stores such as Amazon will not be restored, apps acquired through Amazon will not be restored, and any apps sideloaded will not be restored. Since Google's restore function doesn't restore everything, any backup solution - like a nandroid backup - is going to be a better alternative.
Strephon Alkhalikoi said:
Data, as it is the one where your settings and app updates are stored. Just be sure the new device is running the same version of Android as the old.
Restoring a nandroid backup of the data partition to another, identical, device will work without causing a bootloop given the precautions I describe above. Do note however that Google's backup only restores items acquired through the Play Store. Alternative app stores such as Amazon will not be restored, apps acquired through Amazon will not be restored, and any apps sideloaded will not be restored. Since Google's restore function doesn't restore everything, any backup solution - like a nandroid backup - is going to be a better alternative.
Click to expand...
Click to collapse
Thanks for the clarification that you can restore data as long as you are on the same version, does it have to be at the same security update level as well?
That is why I use Titanium for apps I got off of Fdroid and other sources. I will make sure I try the Nandroid data backup next time.
Security level shouldn't make a difference, but that is not something I have attempted. The pair of identical tablets I have here are running the same security update.
Thanks, data did the trick.
I had to delete 2 files due to a non working finger printer by using TWRP files explorer, but now the phone is fine.
Last thing pending are customer ringtones, but this is a nasty one.
Any idea how to do it?
Sui77 said:
Thanks, data did the trick.
I had to delete 2 files due to a non working finger printer by using TWRP files explorer, but now the phone is fine.
Last thing pending are customer ringtones, but this is a nasty one.
Any idea how to do it?
Click to expand...
Click to collapse
I am having the same problem with the fingerprint reader after restoring data from one phone to another, what files did you delete in TWRP file manager?
Solution for fingerprinter:
1. Boot into TWRP
2. Go to advanced>filemanager to acces the files in your phone.
3. Enter the folder /data/system/user/0
4. Delete following files: ./fpdata/user.db, settings_fingerprint.xml
5. Reboot to system and set up new fingerprints with the fingerprint wizard
6. Everything should work normal
Was not easy to find, but it's easy to do
Sui77 said:
Solution for fingerprinter:
1. Boot into TWRP
2. Go to advanced>filemanager to acces the files in your phone.
3. Enter the folder /data/system/user/0
4. Delete following files: ./fpdata/user.db, settings_fingerprint.xml
5. Reboot to system and set up new fingerprints with the fingerprint wizard
6. Everything should work normal
Was not easy to find, but it's easy to do
Click to expand...
Click to collapse
I didn't think it would be easy to find, but thanks for the tips. :good:
I am just putting this phone online with Q Beta 3 today, I have no notifications for text, and all options are greyed out?
Droid_Nut said:
I am just putting this phone online with Q Beta 3 today, I have no notifications for text, and all options are greyed out?
Click to expand...
Click to collapse
Turns out this is a bug in Android Q. With Pie there were some many notifications that I set my sound to none, so I just set my sound to Gibbon Call, and now I get text notifications. :good: