Encryption process interrupted - recover data? - Nexus 5X Q&A, Help & Troubleshooting

Hi guys
Had my unlocked N5x running on latest stock 6.0.1 as base but running francos kernel, xposed, twrp etc etc, the usual suspects
In a weak moment just now I dirty flashed the N preview and due to the absence of useful kernels let it boot with stock boot.img flashed. The boot took unusually long and after a couple minutes and the device running a little warmish/hot I got impatient and decided to interrupt the boot and try again.
Little did I know the device wasn't hanging or bootlooping but in the process of (without any obvious feedback) encrypting my data. With the force-shutdown, the encryption was interrupted of course and thus all my data is lost. F***.
I already formatted internal data etc etc so the data is probably gone for good. Since I couldn't ever be bothered with device encryption in the last 8 years of using Android, my knowledge there is virtually nonexistent and thus I ask: would there have been a way to decrypt the unsuccessfully encrypted data partition? Or to recover files now after the factory reset?

schaggo said:
Hi guys
Had my unlocked N5x running on latest stock 6.0.1 as base but running francos kernel, xposed, twrp etc etc, the usual suspects
In a weak moment just now I dirty flashed the N preview and due to the absence of useful kernels let it boot with stock boot.img flashed. The boot took unusually long and after a couple minutes and the device running a little warmish/hot I got impatient and decided to interrupt the boot and try again.
Little did I know the device wasn't hanging or bootlooping but in the process of (without any obvious feedback) encrypting my data. With the force-shutdown, the encryption was interrupted of course and thus all my data is lost. F***.
I already formatted internal data etc etc so the data is probably gone for good. Since I couldn't ever be bothered with device encryption in the last 8 years of using Android, my knowledge there is virtually nonexistent and thus I ask: would there have been a way to decrypt the unsuccessfully encrypted data partition? Or to recover files now after the factory reset?
Click to expand...
Click to collapse
Strong possibly its gone.
Try booting to recovery, mounting data and connecting to the computer and see whats there.
You maybe able to run a recovery program while connected.

Related

Be warned: Encrypting your device can be dangerous

Hello,
As Google has decided to turn encryption on as a standard in the upcoming Android 5.0, I thought I would give it a test on my CosmicCM 5.4.
I started the encryption and it prompts you that you for a passcode that will be used from now on, so far no problem.
It started encrypting my device and it was running for some time(I left it alone for an hour) and reboots a couple of times.
After he's finished the annoyance came.
first you will have to type twice your password with a reboot, one time do decrypt your device the second time to enter your device.
Be aware that performance can be slowed through encryption, and it can negatively impact battery life too.
So I decide to go back.
The Problem: Once encrypted, you can't decrypt it easily.
When encrypting the phone android will tell you you can only decrypt it using a factory reset. Naturally you assume it's talking about the "Factory Data Reset" option found in Settings --> Backup and Reset and this works.
Now I wanted to try a rom (TW 4.2.2 based) and see how this worked and after installing and booting.
I got prompted to enter the decryption and of course this didn’t work anymore as there is no data for the password.
So I assumed you can wipe everything from your custom recovery mod (CWM, TWRP, or one of those).
Wrong! You'll get beautiful "can't mount /data" messages and more.
After some hard time I got everything working again, by flashing CosmicCM again.
The phone booted al clean again without asking for encryption and when you check the menu it also mentioned encryption is deactivated.
Trying the previous rom again just triggerd the encryption again.
So It seems that there is still somewhere a hidden encrypted protection that will be activated when I flash a different rom.
So be warned and don’t play with encrypting your device as you could brick it.
Didn't have time to investigate further on how I can remove it completely, but my guess is I have to redo all the partitions.
I was on the same boat a month ago
akiratoriyama said:
I was on the same boat a month ago
Click to expand...
Click to collapse
I wish you told me sooner
Did you redo all the partitions to get the encryption completely removed?
RichyE said:
I wish you told me sooner
Did you redo all the partitions to get the encryption completely removed?
Click to expand...
Click to collapse
I think I had to wipe my data via Philz, CWM and stock to remove encryption.
akiratoriyama said:
I think I had to wipe my data via Philz, CWM and stock to remove encryption.
Click to expand...
Click to collapse
Thanks for the info, will try to flash stock this week and see if this helps

Set up 5x as new Device or from Previous backup? (to best improve poor performance)

Hello,
My 5x became more less unusable so I had to factory reset it. Will setting it up as new device be more advantageous in terms of performance? Or should I stick with the backup and save my self a lot of time downloading everything?
I had this phone since it came out and I think I will be getting rid of it. It became laggy as hell and 2gb of ram just does not cut it, and now since I just upgraded from 6.0 to 6.0.1 my build number is MTC19V and for the life of me I cant find a way to decrypt it. Encrypted 5x is even worse (I've done both so had a feel for it with and without it)
neopl666 said:
Hello,
My 5x became more less unusable so I had to factory reset it. Will setting it up as new device be more advantageous in terms of performance? Or should I stick with the backup and save my self a lot of time downloading everything?
I had this phone since it came out and I think I will be getting rid of it. It became laggy as hell and 2gb of ram just does not cut it, and now since I just upgraded from 6.0 to 6.0.1 my build number is MTC19V and for the life of me I cant find a way to decrypt it. Encrypted 5x is even worse (I've done both so had a feel for it with and without it)
Click to expand...
Click to collapse
Check out this thread
https://www.reddit.com/r/nexus5x/comments/4nayhm/to_those_of_you_with_lag_force_closes_etc/
factory reset and set up as new google account to experiment and see if there is still lag. Just load up a couple of your most used apps to start.
I've run encrypted and unencrypted side by side on 2 5xs on same build with same exact software loaded and there was no noticeable difference within Android. I doubt your lag is because of encryption.
Also if you are running out of memory it just takes a little longer to switch to an app, it doesn't lag all the time. If it is lagging all the time, that is caused by something else.
Any chance you were running low on storage space? 2GB or less free? If so, there's a decent chance that was causing lag as EMMC drives don't perform well when they start getting full.
The way you run decrypted on MTC19V is the same as on previous releases. It hasn't changed.
Use TWRP to install SuperSU then boot into bootloader
fastboot erase user
fastboot format user
If you need root, boot into TWRP and reinstall SuperSU as last two steps will overwrite SuperSU.
sfhub said:
Check out this thread
https://www.reddit.com/r/nexus5x/comments/4nayhm/to_those_of_you_with_lag_force_closes_etc/
factory reset and set up as new google account to experiment and see if there is still lag. Just load up a couple of your most used apps to start.
I've run encrypted and unencrypted side by side on 2 5xs on same build with same exact software loaded and there was no noticeable difference within Android. I doubt your lag is because of encryption.
Also if you are running out of memory it just takes a little longer to switch to an app, it doesn't lag all the time. If it is lagging all the time, that is caused by something else.
Any chance you were running low on storage space? 2GB or less free? If so, there's a decent chance that was causing lag as EMMC drives don't perform well when they start getting full.
The way you run decrypted on MTC19V is the same as on previous releases. It hasn't changed.
Use TWRP to install SuperSU then boot into bootloader
fastboot erase user
fastboot format user
If you need root, boot into TWRP and reinstall SuperSU as last two steps will overwrite SuperSU.
Click to expand...
Click to collapse
Thank you for your post. I think the issue with my phone is that overtime it just became increasingly slower. I always kept at least 6gb of free space as I am aware of the issue of not doing so. Taking off encryption soon after I purchased the phone when it came out did make it more responsive. I now wiped it and loaded 6.0.1 and can say that the phone came back to life. But for how long? This time around I will try to not tweak the hell out of it and to not load too many things through xposed as those were probably the culprits of poor performance over the months.
I will try the commands you recommend to remove encryption, what I did before that failed to work was format the data partition through TWRP. Will my phone remain unencrypted if I side load the next OTA, or will side loading the OTA encrypt it back up? Thanks again!
PS. I am considering OnePlus 3 but the (incredibly timely) review on Anandtech states that the color calibration of the screen is some of the worse out there, and that may just be the deal breaker. It is a shame really as otherwise it is looking like a one fine device.
neopl666 said:
Thank you for your post. I think the issue with my phone is that overtime it just became increasingly slower. I always kept at least 6gb of free space as I am aware of the issue of not doing so. Taking off encryption soon after I purchased the phone when it came out did make it more responsive. I now wiped it and loaded 6.0.1 and can say that the phone came back to life. But for how long?
Click to expand...
Click to collapse
I tested starting with April release. It is possible with earlier releases encryption was slower, but with April release side-by-side comparison with encrypted vs unencrypted there was no noticeable difference. I loaded reasonably large games, offline GPS maps, web browsing, etc.
Sometimes it is hard to tell if unencrypting is the reason the phone is faster, because as part of unencrypting, you essentially do a factory reset when your user partition gets wiped/reformatted. It is possible your phone could have been faster just by the factory reset with no decryption.
neopl666 said:
I will try the commands you recommend to remove encryption, what I did before that failed to work was format the data partition through TWRP. Will my phone remain unencrypted if I side load the next OTA, or will side loading the OTA encrypt it back up? Thanks again!
Click to expand...
Click to collapse
The critical step is *never* boot using a factory boot.img. Then you can remain decrypted.
If you sideload an OTA, immediately boot into bootloader when done, then to recovery. I say boot into bootloader, because sometimes you can mistime the boot into recovery, and boot into android by mistake. I don't remember if sideload immediately reboots when done or gives you some time, but you need to get into bootloader (or TWRP recovery, either directly or via bootloader menu option) prior to initial boot with the stock boot.img, otherwise it will reencrypt.
From TWRP you'll need to flash the SuperSU install zip and that will patch your boot.img to remove foreced encryption. From that point on you are safe.
Honestly, I ran for a month decrypted even though I found no difference in performance between encrypted and unencrypted, just in case there were long term differences. It wasn't until I found a separate issue with my SIM card and visual voicemail that only occurred on decrypted sytems that I switch back.
It's been a few weeks and there have been no noticeable slowdowns for my usage, but I don't have 2 units to run side-by-side right now, so I can't say with as much surety as I could when I literally ran them side-by-side and pressed on the same apps and did the same actions.

Does Encryption NEVER work in ROMS

So I kind of like the fact encryption is turned on automatically by Nextbit (and I did figure out how to get out of my encryption loop)
And I have tried to encrypt the disk with
-Pacman ROM
-Reserrection ROM
-Paranoid Android
and all of them bootloop and never actuall boot up once you press "encrypt".... so is it impossible to encrypt once you have an unlocked bootloader and recovery installed? I get its detrimental to the whole process of flashing incessantly but still
Grrrrrrr
Can sum1 confirm
tlxxxsracer said:
If you unlock the bootloader,that alone won't cause encryption issues. You have to flash a specific boot.img or zip that will disable encryption.
Don't unencrypt and should be fine.
Not sure why you'd want to encrypt if your BL is unlocked. Encryption only hurts performance
Click to expand...
Click to collapse
thanks for the reply
I wanted to encrypt my current ROM to just get the extra protection from theft or lost device.
I really like the current ROM im using and dont need to flash anymore currentlty, so i would be fine locking it down with encryption
But i cant get ANY of the ROMS to encrypt like they normally do say compared to the G3
So there is a solution to this. Basically, when you encrypt the file system on one rom, even when you wipe the data certain things are still tied to the old file system. That's why when you go to encrypt the encryption fails, because the remnant stuff from the other rom is in the way. The solution is to completely reformat the data partition (using TWRP, select format data, or change the data file system to F2FS and then back to ext4.). This will clear the conflicts causing encryption to bootloop. However, this process will need to be repeated every single time you switch roms (updating a rom is fine).
I believe Cyanogenmod supports encryption, though I have never tried it.
yanowman said:
So I kind of like the fact encryption is turned on automatically by Nextbit (and I did figure out how to get out of my encryption loop)
And I have tried to encrypt the disk with
-Pacman ROM
-Reserrection ROM
-Paranoid Android
and all of them bootloop and never actuall boot up once you press "encrypt".... so is it impossible to encrypt once you have an unlocked bootloader and recovery installed? I get its detrimental to the whole process of flashing incessantly but still
Click to expand...
Click to collapse
If you flashed the custom boot image, you CANNOT re encrypt your phone. Won't work.

I think I kinda Bricked my phone (SOLVED)

Hello everyone sorry to bother. So I was flashing a custom rom for my op5t and followed the usual steps : wipe system data cache and flashed the rom+gapps+magisk. And when I tried to boot the device it got stuck at the oneplus logo it didn't even got into bootloop. So I decided to flash rom again and wiped the data again but there I saw all the files were encrypted. I don't know how did it happen I wasn't encrypted in the beginning and now I can't install anything, the phone does not have any OS so it can't boot up. I don't want to lose my data is there anything I can do without locking the bootloader?
No need to lock your bootloader, but I think your data is lost.
Format data, and flash system again.
Yup. Don't lock your bootloader or you really will be screwed. Your data is lost at this point. Live, learn and remember to back up you data.
crakerjac said:
Yup. Don't lock your bootloader or you really will be screwed. Your data is lost at this point. Live, learn and remember to back up you data.
Click to expand...
Click to collapse
I did get a backup but since all the files are encrypted now i cannot access my backup folder or data also.
antarax23 said:
I did get a backup but since all the files are encrypted now i cannot access my backup folder or data also.
Click to expand...
Click to collapse
Not that it helps you now, but typically backup data does not mean to the device you are messing with. You want to backup data to another device (like your PC). What would help at this point, is knowing exactly what you flashed. (What were you on, and what did you flash)
It sounds like you flashed two ROMs with different types of encryption, and the reason you can no longer read your data. Sometimes, and I mean sometimes, if you are lucky, you can go back to the ROM that you originally on and your data would still be readable. I've been able to salvage data this way before, sometimes just with the correct TWRP on some devices.
OhioYJ said:
Not that it helps you now, but typically backup data does not mean to the device you are messing with. You want to backup data to another device (like your PC). What would help at this point, is knowing exactly what you flashed. (What were you on, and what did you flash)
It sounds like you flashed two ROMs with different types of encryption, and the reason you can no longer read your data. Sometimes, and I mean sometimes, if you are lucky, you can go back to the ROM that you originally on and your data would still be readable. I've been able to salvage data this way before, sometimes just with the correct TWRP on some devices.
Click to expand...
Click to collapse
I solved the problem but it cost me my data after all. I had access to TWRP and fastboot but it couldn't read any of the data neither transfer anything from pc so I wiped all the device via TWRP and mounted into my pc and could finally transferred necessary files to flash. After all I did not lock the bootloader but lose my data

Tinkering with Redmi Note 5, flashing TWRP, trying to enable Camera2, bootloop...

Hello there,
I've recently received my Redmi Note 5 back from warranty service. As much as I like the phone, one thing I always found really disappointing about it is that for whatever reason, it is, as far as I know, the only phone from the Redmi Note series that has Camera2 disabled by default, preventing me from installing GCam. Fortunately, I have found multiple tutorials on how to activate it. Since I've wiped my data before sending it, now was the best time to do some tinkering.
I've used my friend's laptop to unlock its bootloader and install TWRP (it refused to work on my desktop for some reason). the official TWRP web page warned me that the phone uses dm-verity, which is something none of the tutorials mentioned. After some further digging, I found out that should I mess with it, the phone would simply revert any changes, and to prevent this, I needed to flash a dm-verity disabler, such as LazyFlasher
Thinking nothing would go wrong, I decided to try flashing TWRP and deal with the system replacing it with the stock recovery later. All went as planned, and the phone booted into the custom recovery with no issues. It asked me for a password to decrypt the internal storage, which I don't know, so I skipped this step. The first thing I did was creating a backup.
I then tried rebooting, just to see if it would really revert the changes. It did, but it didn't go as smoothly as I had hoped. The system became laggy to the point where it was basically unusable, often freezing for more than 30 seconds after just opening an app. Not knowing what to do, I flashed TWRP back, this time with the dm-verity disabler. A tutorial on how to do this that I found recommended I wipe the cache after flashing the tool. I tried doing that, but the process failed immediately. I rebooted the phone, and the next thing you know, I'm in a bootloop. I've let it sit for a while, but even after some time, the system wouldn't start. Fortunately, I was still able to get back into TWRP.
I restored the backup I created earlier. This, for the most part, solved my issues, the system works fine-ish again (aside from an occasional lag, but it's not nearly as bad as it was) and isn't trying to replace TWRP with the stock recovery anymore, but I'm kinda afraid to tinker with it again. I'd really hate having to buy a new phone just because I bricked the one I have (and I didn't even get to flash the tool that was meant to enable Camera2).
What did I do wrong? Should I've formated the internal storage to gain access to it first? Did flashing TWRP without dm-verity disabled somehow mess up the system? Would flashing a custom ROM bypass having to disable it? I'm confused...

Categories

Resources