How do I decrypt my 6p - Nexus 6P Q&A, Help & Troubleshooting

I flashed CM when it first arrived and encrypted my phone. How do I unencrypt it again? Thanks in advance.

jdub251 said:
I flashed CM when it first arrived and encrypted my phone. How do I unencrypt it again? Thanks in advance.
Click to expand...
Click to collapse
I don't think you can decrypt without formatting the area.

jdub251 said:
I flashed CM when it first arrived and encrypted my phone. How do I unencrypt it again? Thanks in advance.
Click to expand...
Click to collapse
You need a kernel that does not force encryption. I believe ex kernel is an option. I run benzo rom which does not force encryption. Make sure yo backup any data you want to keep. The process should go as follows:
Flash rom
Flash gapps
Flash kernel
Select wipe
Format data
Reboot Recovery
Reboot system

n.halepat said:
You need a kernel that does not force encryption. I believe ex kernel is an option. I run benzo rom which does not force encryption. Make sure yo backup any data you want to keep. The process should go as follows:
Flash rom
Flash gapps
Flash kernel
Select wipe
Format data
Reboot Recovery
Reboot system
Click to expand...
Click to collapse
Ok! Will try this! Thanks! I believe this will work!
Sent from my Nexus 6P using Tapatalk

jdub251 said:
Ok! Will try this! Thanks! I believe this will work!
Sent from my Nexus 6P using Tapatalk
Click to expand...
Click to collapse
Just make sure you format data, not wipe.

n.halepat said:
You need a kernel that does not force encryption. I believe ex kernel is an option. I run benzo rom which does not force encryption. Make sure yo backup any data you want to keep. The process should go as follows:
Flash rom
Flash gapps
Flash kernel
Select wipe
Format data
Reboot Recovery
Reboot system
Click to expand...
Click to collapse
Heisenberg said:
Just make sure you format data, not wipe.
Click to expand...
Click to collapse
Have you noticed any speed difference after decrypting?
Also is it possible to decrypt using a kernel that doesn't force encryption and then switch to a kernel that may not have that? I would still have to turn encryption on via Settings -> Encrypt is what I'm thinking.

exSD said:
Have you noticed any speed difference after decrypting?
Also is it possible to decrypt using a kernel that doesn't force encryption and then switch to a kernel that may not have that? I would still have to turn encryption on via Settings -> Encrypt is what I'm thinking.
Click to expand...
Click to collapse
I've seen some testing regarding encrypted vs decrypted, the performance gain is so small it's negligible. If you switch to a kernel that forces encryption, it'll encrypt automatically on boot.

Heisenberg said:
I've seen some testing regarding encrypted vs decrypted, the performance gain is so small it's negligible. If you switch to a kernel that forces encryption, it'll encrypt automatically on boot.
Click to expand...
Click to collapse
Have you read http://www.anandtech.com/show/9820/the-google-nexus-6p-review ?
The difference in storage speeds is drastic.
Encrypted: 75.7MB/s seq read, 40.6MB/s seq write, 7.4MB/s rand read, 1.0MB/s rand write.
Unencrypted: 179.7MB/s seq read, 52MB/s seq write, 14.73MB/s rand read, 6.3MB/s rand write.

exSD said:
Have you read http://www.anandtech.com/show/9820/the-google-nexus-6p-review ?
The difference in storage speeds is drastic.
Encrypted: 75.7MB/s seq read, 40.6MB/s seq write, 7.4MB/s rand read, 1.0MB/s rand write.
Unencrypted: 179.7MB/s seq read, 52MB/s seq write, 14.73MB/s rand read, 6.3MB/s rand write.
Click to expand...
Click to collapse
No I hadn't seen that particular article. I guess the results must vary, the results I saw showed performance gains in the order of less than a percent.

Heisenberg said:
No I hadn't seen that particular article. I guess the results must vary, the results I saw showed performance gains in the order of less than a percent.
Click to expand...
Click to collapse
In terms of power consumption, the CPU is processing an extra step for every instruction it has passed to it. I would think that with the inefficient chip the 810 already is that this would impact battery life more than real world opening apps type speed.
I think I'll decrypt to see if I can notice any power differences.

so if i copy all my files to my PC before following these steps, I would still be able to use them afterwards? ie pictures, sounds, images, and titanium backup files? i'm wanting to try benzorom and it sounds like it doesn't get along with encryption very well.

glhelinski said:
so if i copy all my files to my PC before following these steps, I would still be able to use them afterwards? ie pictures, sounds, images, and titanium backup files? i'm wanting to try benzorom and it sounds like it doesn't get along with encryption very well.
Click to expand...
Click to collapse
Yeah, as long as you back up everything to your PC you can just transfer them all back to your phone after you do this.

if i do a nandroid backup (from TWRP) of an encrypted system then create backup of /sdcard, wipe userdata than restore /sdcard and restore backup with a non forcing kernel will i get a decrypted device with all data restored?

answering my own question:
- twrp backup data
- copy /sdcard to pc
- fastboot format userdata
- copy from pc to /sdcard
- restore data in twrp
are the needed steps to decrypt without losing any data.

A bit of a necro, so I apologize for that.
@ratson: I am attempting to do exactly what you have mentioned here, although I am not an experienced user. Can I get some clarification on the following:
TWRP backup: Done. It keeps wanting to restrict my permissions on this folder, but I was able to get it off the device (Nexus6p Huawei) and backed up onto my PC.
copy the /sdcard to the PC. Man, what a problem I am having with this. First off, when it gets to a folder called /kick it fails because it says it's not a directory. It does this on some long hex named file that actually isn't a directory, but it seems to want to recognize it as one anyway, and then fail the pull because of this.
So, I cut the entire /kick folder through ES Explorer, and temporarily pasted it into my dropbox. Restarted the adb pull through my shell. It seemed to be working ok, until it got to the TWRP folder. While backing that up (I already did this, but it is still on the device as I only copied it. Should I be deleting this before backing up the rest of the /sdcard?) it fails because it says permission denied when it tries to pull some of the backup files.
At this point I've restarted the pull, and tried different things for several hours. Before I continue to bang my head against the wall, I'd like to get some advice.
How do you pull the /sdcard to your pc? what method? what commands? do you do it from TWRP recovery mode, from the system? Pretend I'm an android toddler (I kind of am). Is there anyway to not start from scratch every time the pull fails? Is there ways to pre-empt the failures?
Once this is complete, when you restore the data, can you please also list the commands for that?
I greatly appreciate your, or anyone elses help to reads this.
Thanks,

For the record:
Make sure battery is charged!
On PC: adb reboot recovery
In TWRP: select BACKUP, select DATA, swipe
When finished
On PC:
mkdir DATA-BACKUP
adb pull /data/media/0/TWRP/BACKUPS
fastboot reboot bootloader
fastboot format userdata
On Phone:
arrow down to select recovery, power to enter
cd DATA-BACKUP
adb push * /data/media/TWRP/BACKUPS
When finished
In TWRP: Restore, select the backup, swipe

rchtk said:
For the record:
Make sure battery is charged!
On PC: adb reboot recovery
In TWRP: select BACKUP, select DATA, swipe
When finished
On PC:
mkdir DATA-BACKUP
adb pull /data/media/0/TWRP/BACKUPS
fastboot reboot bootloader
fastboot format userdata
On Phone:
arrow down to select recovery, power to enter
cd DATA-BACKUP
adb push * /data/media/TWRP/BACKUPS
When finished
In TWRP: Restore, select the backup, swipe
Click to expand...
Click to collapse
This will backup and restore the nandroid backup, but not the sdcard, correct? Or am i getting it wrong?

Kalamos said:
This will backup and restore the nandroid backup, but not the sdcard, correct? Or am i getting it wrong?
Click to expand...
Click to collapse
It will restore what you backed up: the complete data partition: app settings, contacts, media,.. All your datas..

rchtk said:
It will restore what you backed up: the complete data partition: app settings, contacts, media,.. All your datas..
Click to expand...
Click to collapse
I was under the impression that a nandroid backup didnnot include apps, user settings, etc. Otherwise, what is the use of Titanium Backup? Perhaps I'm jist confused.

I'm curious if 7.1 still has a huge performance hit with encrypted partitions.
Anyone know of a good app for checking performance of the data partition? All I've seen is internal/external storage.
Thanks.

Related

couldn't find directory... No files found?

Trying to restore a NAND in CWM but it says "couldn't find directory, no files found" when I click "restore"
So i did a backup, and it shows up when I then hit "restore" in sdcard/clockworkmod/backup (listed at top of recovery screen) but when I boot and look on my sdcard, it shows the old backups I made in the folder listed, not the one I just made. I can't find the one I just made, even though if I reboot into recovery, it still shows it (the latest) and only it.
Any idea where the newest one is, and why I cant restore the older ones?
Are you running CWM 6.0.1.9?
Also, take a look at http://forum.xda-developers.com/showthread.php?t=1991657.
I am running v6.0.1.9 and the link you posted seems to say that this should be an issue resolved with this version. Though it did tell where to find the new backup.
It lists some adb commands to move the old backups to the new directory, can I just do that in rootexplorer with copy/paste?
TheAtheistReverend said:
I am running v6.0.1.9 and the link you posted seems to say that this should be an issue resolved with this version. Though it did tell where to find the new backup.
It lists some adb commands to move the old backups to the new directory, can I just do that in rootexplorer with copy/paste?
Click to expand...
Click to collapse
I don't see why you couldn't move the files with rootexplorer. Give it a try!
They moved fine
They are seen by recovery, and now I just switched to TeamWin recovery. We'll see if that sees them too.
Are we confident that wiping doesn't clear this location? I'm a little worried that a factory reset or something might wipe the data folder
TheAtheistReverend said:
They moved fine
They are seen by recovery, and now I just switched to TeamWin recovery. We'll see if that sees them too.
Are we confident that wiping doesn't clear this location? I'm a little worried that a factory reset or something might wipe the data folder
Click to expand...
Click to collapse
Please read the following
http://forum.xda-developers.com/showthread.php?p=34794673
If you are worried about losing the backups, copy them to your pc or onto OTG storage. I use cwm and my backups are now in /data/media/clockwork. If you activate multi-user, I think they go to /data/media/0/clockwork, but I can't test. Not sure about the TW recovery.
scott_doyland said:
Please read the following
http://forum.xda-developers.com/showthread.php?p=34794673
Click to expand...
Click to collapse
Confusing But the info is there. I don't like how complicated it ahs gotten to wipe, restore, recover, and flash. It used to be so simple...:silly:

[Q] CWM touch issues...

Hi!
So, I flashed the official cwm touch 6.0.3.3 from http://www.clockworkmod.com/rommanager, for Nexus 4.
When I perform a backup, it successfully completes.
However, when I boot back into system, the /sdcard/clockworkmod directory is empty.
When I try an adb pull, it's still empty.
But, when I reboot into cwm touch recovery, it clearly shows an available backup, in the same directory (/sdcard/clockworkmod/backup)
And, an adb pull, while in recovery works perfectly.
Any reason why it's not showing up, when I've booted up into Android?
Thanks!
arvindch said:
Hi!
So, I flashed the official cwm touch 6.0.3.3 from http://www.clockworkmod.com/rommanager, for Nexus 4.
When I perform a backup, it successfully completes.
However, when I boot back into system, the /sdcard/clockworkmod directory is empty.
When I try an adb pull, it's still empty.
But, when I reboot into cwm touch recovery, it clearly shows an available backup, in the same directory (/sdcard/clockworkmod/backup)
And, an adb pull, while in recovery works perfectly.
Any reason why it's not showing up, when I've booted up into Android?
Thanks!
Click to expand...
Click to collapse
/data/media/clockworkmod/backup
And there it is!
abaaaabbbb63 said:
/data/media/clockworkmod/backup
And there it is!
Click to expand...
Click to collapse
Thanks!
Why is the directory listing different on System boot?
arvindch said:
Thanks!
Why is the directory listing different on System boot?
Click to expand...
Click to collapse
To protect the backup from accidental deletion.
abaaaabbbb63 said:
To protect the backup from accidental deletion.
Click to expand...
Click to collapse
OK... But, it makes accessing the backup, to copy it to my PC, confusing...
How does this directory listing change work? symlink?
Also, what does the make .img file option, in backup&restore do?
When I tap on it, it just resets the page...
arvindch said:
OK... But, it makes accessing the backup, to copy it to my PC, confusing...
How does this directory listing change work? symlink?
Also, what does the make .img file option, in backup&restore do?
When I tap on it, it just resets the page...
Click to expand...
Click to collapse
Yes, vanilla JB uses a lot of symlinks.
I have no ideea about the make img.
abaaaabbbb63 said:
Yes, vanilla JB uses a lot of symlinks.
I have no ideea about the make img.
Click to expand...
Click to collapse
Oh..
Yeah, it's a weird option.

[Q] how to recover data from a phone that will not boot

I have jamal2367's [AOSP] official 4.4.2 - S4 Google Edition ROM installed (final R1.2) a SGH-1337M.
The other day it started getting stuck on boot; the blue, red, yellow, green circles just continually go in and out without anything else happening. I have booted into CWM Recovery (v6.0.4.4) and done a wipe cache partition and wipe dalvik cache but it did not help.
Can anyone provide advice/steps on how to copy the data (mostly pics and WhatsApp history) off this phone? SMS history would also be nice but not necessary.
toggly said:
I have jamal2367's [AOSP] official 4.4.2 - S4 Google Edition ROM installed (final R1.2) a SGH-1337M.
The other day it started getting stuck on boot; the blue, red, yellow, green circles just continually go in and out without anything else happening. I have booted into CWM Recovery (v6.0.4.4) and done a wipe cache partition and wipe dalvik cache but it did not help.
Can anyone provide advice/steps on how to copy the data (mostly pics and WhatsApp history) off this phone? SMS history would also be nice but not necessary.
Click to expand...
Click to collapse
I would make a backup in your recovery and then flash the rom you had installed. See if that helps.
Edit: You didn't try to update. I changed my comment saying you had tried.
1. Download Aroma File Manager
2. Put a external sd into your phone.
3. Boot into the custom recovery and flash the Aroma file.
4. It will boot into a file browser and you can copy all the files from internal to your external.
ps it's possible that your custom recovery already has a filemanager build in. Then all these steps are obsolete.
I boot into AROMA Filemanager but I can't see anything on the internal SD card (see attachment).
Any ideas? Does that folder icon mean the "sdcard" folder is encrypted?
toggly said:
I boot into AROMA Filemanager but I can't see anything on the internal SD card (see attachment).
Any ideas? Does that folder icon mean the "sdcard" folder is encrypted?
Click to expand...
Click to collapse
Is it encrypted? Then probably it won't work. In that case just reflash the rom you are on without wiping.
toggly said:
Does that folder icon mean the "sdcard" folder is encrypted?
Click to expand...
Click to collapse
Lennyz1988 said:
Is it encrypted? Then probably it won't work. In that case just reflash the rom you are on without wiping.
Click to expand...
Click to collapse
I don't know, that's why I am asking what that icon means?
You say CWM is working, so you can just adb pull everything you need. Applications usually save data in a directory under /data/data or /sdcard/Android/data.
You should find the directories you want with adb shell, then you can adb pull them, then if you reflash your rom you can adb push them back into the same locations. Also, depending where they are saved, your pictures will most likely not be deleted when you reflash your rom. Better safe than sorry though.
If you don't have adb you'll have to download the binary, or you can install the entire Android SDK. Which operating system do you use?
toggly said:
I don't know, that's why I am asking what that icon means?
Click to expand...
Click to collapse
The icons means that it's symlinked. If it's not encrypted then you should find the data. It can be in an other place then where you are looking. Try looking in /data/media or some other maps in /data
Or just flash the rom you are currently on without wiping.
soldier9599 said:
You say CWM is working, so you can just adb pull everything you need. Applications usually save data in a directory under /data/data or /sdcard/Android/data.
You should find the directories you want with adb shell, then you can adb pull them, then if you reflash your rom you can adb push them back into the same locations. Also, depending where they are saved, your pictures will most likely not be deleted when you reflash your rom. Better safe than sorry though.
If you don't have adb you'll have to download the binary, or you can install the entire Android SDK. Which operating system do you use?
Click to expand...
Click to collapse
Adb won't work unless he already has authorized adb when his device was booted.
toggly said:
I boot into AROMA Filemanager but I can't see anything on the internal SD card (see attachment).
Any ideas? Does that folder icon mean the "sdcard" folder is encrypted?
Click to expand...
Click to collapse
You need to mount partitions to see the contents.. Go to Aroma File Manager Settings and check the option "Moumt automatically partition on boot".. then restart your recovery and flash again the Aroma File Manager
Lennyz1988 said:
Adb won't work unless he already has authorized adb when his device was booted.
Click to expand...
Click to collapse
I've had devices where the first thing I did with them was unlock bootloader, fastboot flash recovery, and then go into recovery and adb sideload, all without booting the system.
peppe130 said:
You need to mount partitions to see the contents.. Go to Aroma File Manager Settings and check the option "Moumt automatically partition on boot".. then restart your recovery and flash again the Aroma File Manager
Click to expand...
Click to collapse
That did the trick, thanks!!
Nothing
soldier9599 said:
I've had devices where the first thing I did with them was unlock bootloader, fastboot flash recovery, and then go into recovery and adb sideload, all without booting the system.
Click to expand...
Click to collapse
Yes and I believe that. But from version 4.2.2 android forces rsa encryption. So you need to boot into your rom and enable it. Unless the custom rom/kernel has disabled it, but I haven't seen any that have.

Forgotten pattern - how to unlock phone without loosing data

Don't ask me how, but I somehow set pattern and forgot it in one hour. I use face rec. as well but after reboot I need to unlock with pattern.
For last 10h I tried all methods how to unlock phone, but no success.
I'm using original, ROM, my G6 model is H870, running Pie, unlocked bootloader, so I can use TWRP. I spent most of my time and knowledge to unlock phone with adb/twrp. Best option I found is to delete gesture.key file which is located under /data/system.
Problem is, that /data is encrypted ...
Is there anyone who managed to remove pattern/lock without loosing data?
Thank you for your time!
akulp said:
Don't ask me how, but I somehow set pattern and forgot it in one hour. I use face rec. as well but after reboot I need to unlock with pattern.
For last 10h I tried all methods how to unlock phone, but no success.
I'm using original, ROM, my G6 model is H870, running Pie, unlocked bootloader, so I can use TWRP. I spent most of my time and knowledge to unlock phone with adb/twrp. Best option I found is to delete gesture.key file which is located under /data/system.
Problem is, that /data is encrypted ...
Is there anyone who managed to remove pattern/lock without loosing data?
Thank you for your time!
Click to expand...
Click to collapse
Maybe this will work: https://************/delete-android-security-pin/
Edit: link gets truncated... Just search 'Remove pin twrp' on Google and click the first result.
krilok said:
Maybe this will work: https://************/delete-android-security-pin/
Edit: link gets truncated... Just search 'Remove pin twrp' on Google and click the first result.
Click to expand...
Click to collapse
Non of this solutions work.
This is pretty the same as I said. My problem is that /data is encrypted and I can't find/see any .key files.
Also I can't do "su" command inside adb shell because of "insuff. privileges" ...
I tried all this solutions:
https://forum.xda-developers.com/showthread.php?p=49666433#post49666433
For method 1 -5 there is a problem with .key files which are not seen to my TWRP/Aroma browser. I don't know If I'm doing anything wrong in method 7, but also after mount I can't access /data/system (/data is empty).
In method 6 I'm stucked on
"Run pull settings.db.cmd inside By-pass security Hacks folder to pull out the setting file out of your phone." step.
I get "insuff. privileges" error.
akulp said:
Non of this solutions work.
This is pretty the same as I said. My problem is that /data is encrypted and I can't find/see any .key files.
Also I can't do "su" command inside adb shell because of "insuff. privileges" ...
I tried all this solutions:
https://forum.xda-developers.com/showthread.php?p=49666433#post49666433
For method 1 -5 there is a problem with .key files which are not seen to my TWRP/Aroma browser. I don't know If I'm doing anything wrong in method 7, but also after mount I can't access /data/system (/data is empty).
In method 6 I'm stucked on
"Run pull settings.db.cmd inside By-pass security Hacks folder to pull out the setting file out of your phone." step.
I get "insuff. privileges" error.
Click to expand...
Click to collapse
Have you tried this?
https://forum.xda-developers.com/android/software-hacking/remove-lockscreen-recovery-t3530008
Basically, the files you have to delete in the /data/system folder in TWRP are:
password.key
pattern.key
locksettings.db
locksettings.db-shm
locksettings.db-wal
It happened to me a while ago and I didn't have any '.key' files either; I just deleted the rest and when I booted up, I had no lock screen security PIN nor registered fingerprints but could re-set them again through security settings. I didn't need to flash any files nor fiddle around with adb commands, and all my data remained untouched...
If you can't find all those five files or the '.key' files, just delete the ones you can find and it should work. Otherwise, you'll probably have to do a full reset and reinstall...
krilok said:
Have you tried this?
https://forum.xda-developers.com/android/software-hacking/remove-lockscreen-recovery-t3530008
Basically, the files you have to delete in the /data/system folder in TWRP are:
password.key
pattern.key
locksettings.db
locksettings.db-shm
locksettings.db-wal
It happened to me a while ago and I didn't have any '.key' files either; I just deleted the rest and when I booted up, I had no lock screen security PIN nor registered fingerprints but could re-set them again through security settings. I didn't need to flash any files nor fiddle around with adb commands, and all my data remained untouched...
If you can't find all those five files or the '.key' files, just delete the ones you can find and it should work. Otherwise, you'll probably have to do a full reset and reinstall...
Click to expand...
Click to collapse
Problem is, that I don't have any files/folders at all in my /data. I even don't see system folder inside data.
akulp said:
Problem is, that I don't have any files/folders at all in my /data. I even don't see system folder inside data.
Click to expand...
Click to collapse
Sounds like your data folder is not mounted when you boot to TWRP... Have you checked? Reboot to TWRP, select the Mount option; data should be ticked by default. It it isn't, select it, go back to TWRP file manager, and see if you can now browse folders and files...
krilok said:
Sounds like your data folder is not mounted when you boot to TWRP... Have you checked? Reboot to TWRP, select the Mount option; data should be ticked by default. It it isn't, select it, go back to TWRP file manager, and see if you can now browse folders and files...
Click to expand...
Click to collapse
Unfortunately it's checked ... It's seems from this post:
https://forum.xda-developers.com/android/software-hacking/remove-lockscreen-recovery-t3530008/page12
nobody managed to get to (encrypted) /data on Pie.
akulp said:
Unfortunately it's checked ... It's seems from this post:
https://forum.xda-developers.com/android/software-hacking/remove-lockscreen-recovery-t3530008/page12
nobody managed to get to (encrypted) /data on Pie.
Click to expand...
Click to collapse
Last comment on that thread says the solution also works on Havoc Os 2.9, which is based on Pie... Maybe that person wasn't encrypted to begin with, but, if it doesn't work for you, I guess then the only way to go is a full reset... Good luck!
krilok said:
Last comment on that thread says the solution also works on Havoc Os 2.9, which is based on Pie... Maybe that person wasn't encrypted to begin with, but, if it doesn't work for you, I guess then the only way to go is a full reset... Good luck!
Click to expand...
Click to collapse
Yep, I saw that post ... I relly don't have any more ideas. Should be inside "mount modul" in TWRP /data listed?
I only have System, Cache and SD ... and i can check System only if i check bottom "mount system partition read-only" option.
But that's nothing to do with /data.
akulp said:
Yep, I saw that post ... I relly don't have any more ideas. Should be inside "mount modul" in TWRP /data listed?
I only have System, Cache and SD ... and i can check System only if i check bottom "mount system partition read-only" option.
But that's nothing to do with /data.
Click to expand...
Click to collapse
Data option should show. At least it does on mine... You can maybe try updating Twrp version?
I'm on last TWRP.... Meantime I already made full reset ....
If you have encrypted data partition, you're pretty much banned from messing with it, unless you manage to exploit your way through the adb, which requires you to have it enabled and in trust relation with your PC to begin with.
The way I'd go around this is to place an "always yes su" binary and perform pattern removal process through init.d or similar solution. In case if su commands are restricted, kernel with permissive SELinux needs to be flashed.
On a side note, isn't this Q&A?
I also had a problem with data folder not being mounted when booting to TWRP. I tried a full reset and immediately i have access to the Data folder (but theres nothing left inside so this is kinda useless). Then later when i did a reboot into the TWRP it happened again, couldnt access to anything even when the "mount Data" option is ticked, only until i did the full reset again that it could finally work.
It turned out the problem is with the TWRP itself, i flashed another custom recovery (OrangeFox-R10-Stable-h870, which is btw a better recovery than TWRP in my opinion) and the problem never occurred again.
So either try out that new Recovery or a different version of TWRP and see if it solves the problem. And always, ALWAYS, make a full backup of all your data before messing with anything (i had to learn that the hard way so trust me).
Do this,
- you should know that I am using "orange fox recovery" not "twrp",and stock "pie"
- reboot to recovery and go to system/data
- delete this files:
gatekeeper.password.key
gatekeeper.pattern.key
locksettings.db
-reboot the phone and that's it.

How to do full system backup to PC?

Before I handing in my OnePlus 6T for repair, I want to create a full system backup and reset the phone to factory defaults. Afterwards, I want to restore the original state. My phone is rooted with Magisk.
How do I do a full system backup?
What I tried:
adb backup -apk -obb -shared -all -system: This finishes, but at 5.5GB, even if compressed, the backup file is suspiciously small. According to the settings app, my phone uses 55GB of storage, so ten times that!
OK, so I thought adb root needs to be run before. However, that doesn't work: adbd cannot run as root in production builds
So I installed the adb_root module. But now when I run the above backup command, then it simply quits. No backup is created.
feklee said:
Before I handing in my OnePlus 6T for repair, I want to create a full system backup and reset the phone to factory defaults. Afterwards, I want to restore the original state. My phone is rooted with Magisk.
How do I do a full system backup?
What I tried:
adb backup -apk -obb -shared -all -system: This finishes, but at 5.5GB, even if compressed, the backup file is suspiciously small. According to the settings app, my phone uses 55GB of storage, so ten times that!
OK, so I thought adb root needs to be run before. However, that doesn't work: adbd cannot run as root in production builds
So I installed the adb_root module. But now when I run the above backup command, then it simply quits. No backup is created.
Click to expand...
Click to collapse
Do you have TWRP on your device? If so, just backup everything with it and copy the TWRP backup folder elsewhere.
ALSO (with the help of PC) copy the /sdcard (emulated sdcard; media storage). TWRP itself does not do that.
Done.
The reinstall TWRP in your device and restore everything. And copy back /sdcard
By the way, this is not Magisk related. For more information, better ask in your device specific section.
wilsonhlacerda said:
Do you have TWRP on your device? If so, just backup everything with it and copy the TWRP backup folder elsewhere.
Click to expand...
Click to collapse
Thanks for pointing me in the right direction! Here's how I proceeded in the end:
Downloaded TWRP for my device.
Rebooted the phone into fastboot mode by pressing volume down plus the power button and following the menu displayed on the phone. Note the process of entering fastboot mode varies from phone to phone.
Connected the phone to the PC, then booted TWRP from the Windows command line (cmd.exe):
Code:
fastboot boot twrp-3.4.0-0-fajita.img
I installed fastboot as part of the Chocolatey package adb.
In TWRP, I entered my password, then selected Backup.
Backed up all partitions to internal storage. See also the TWRP FAQ: What should I back up in TWRP?
Note that not all partitions need to be backed up, and in fact, according to the TWRP FAQ, it may be a bad idea to restore certain partitions. Still, it doesn’t hurt to have the backup of all of them.
Not included is /data/media (internal storage). This needs to be backed up separately. See the TWRP FAQ: What is EXCLUDED from a TWRP backup?
With TWRP running, I connected the phone via USB to my PC. Then I moved the following folder to my PC, which contains the TWRP backup of the phone:
Code:
This PC\OnePlus A6013\Internal Storage\TWRP
This step is not strictly necessary as in the following step I did back up the entire internal storage. However, it makes the next step execute faster as less data needs to be copied. The next step does not give feedback about progress.
For backing up internal storage I decided on the method found in Tadej Janež’s article Backing up Android's /data/media (i.e. internal storage) using adb and TWRP. From the Windows command line I ran:
Code:
adb exec-out "tar --create data/media/0 2>/backup-errors.txt | gzip" >internal_storage.tar.gz
After completion, to check for errors, I ran (no errors):
Code:
adb shell cat /backup-errors.txt
To leave TWRP, I rebooted the phone. Note that it is not necessary to install TWRP.
Restoration still needs to be tested.
By the way, this is not Magisk related. For more information, better ask in your device specific section.
Click to expand...
Click to collapse
I thought there was a Magisk way of doing a full system backup, making use of root privileges. Now I know better.
you can also try Migrator of vr25.
{Mod Edit: TG link removed}
https://github.com/VR-25/migrator
Just use Migrate
End of story.....
datsoy said:
you can also try Migrator of vr25.
{Mod Edit: TG link removed}
https://github.com/VR-25/migrator
Click to expand...
Click to collapse
Thanks! This looks nice, but I already backed up with TWRP. The idea was to get a 1:1 binary backup, and the backup did work. However, I am running into issues during restore of the Data partition: Error 255 when trying to restore Data

Categories

Resources