Best way to create and re-flash userdata image on latest N (ryu-nrd91n) - Pixel C Q&A, Help & Troubleshooting

First of all, thanks so much to everyone for all the hard work creating and updating utilities for the Pixel C.
I have a rooted (but otherwise stock) Pixel C running the November update of Android 7/N (ryu-nrd91n) and am trying to:
1. Create an image of the userdata partition
2. Read/modify files
3. Re-flash the modified partition back to the Pixel C
So far I've been able to create a 24.8 GB image file using 'dd' but the file is unreadable, probably due to encryption.
I don't see any Developer Settings option to remove encryption or otherwise unencrypt the data partition.
What is the best approach?

jason_hanley said:
First of all, thanks so much to everyone for all the hard work creating and updating utilities for the Pixel C.
I have a rooted (but otherwise stock) Pixel C running the November update of Android 7/N (ryu-nrd91n) and am trying to:
1. Create an image of the userdata partition
2. Read/modify files
3. Re-flash the modified partition back to the Pixel C
So far I've been able to create a 24.8 GB image file using 'dd' but the file is unreadable, probably due to encryption.
I don't see any Developer Settings option to remove encryption or otherwise unencrypt the data partition.
What is the best approach?
Click to expand...
Click to collapse
Do you want to get rid of your encrypted data partition ?
- Format data (inside TWRP - and do not boot into system in between)
- Flash stock boot.img
- Install SuperSU.zip / or flash antother boot.img - with "encryptable" flag.
If you flash stock boot.img and boot into system your are encrypted again - automatically.
yes, "dd" will dump the complete partition including encryption ..
you may can "tar" the complete file system while decrypted .. similar to TWRP backup function.
Why do you want to "backup - modify - restore" at all ?
Why you don´t modify your files directly on data using root-explorer ?
Cheers

followmsi said:
Do you want to get rid of your encrypted data partition ?
- Format data (inside TWRP - and do not boot into system in between)
- Flash stock boot.img
- Install SuperSU.zip / or flash antother boot.img - with "encryptable" flag.
If you flash stock boot.img and boot into system your are encrypted again - automatically.
...
Why do you want to "backup - modify - restore" at all ?
Why you don´t modify your files directly on data using root-explorer ?
Click to expand...
Click to collapse
Thanks so much for the follow-up. The main goal is actually simply to be able to create images, and re-flash them reliably on a different Pixel C (replicating the exact system state). The modification step is simply to verify that it's working.
I was able to unencrypt /data using the method above -- Thanks, that's extremely helpful!
However, I'm still unable to mount/read the file produced by "dd if=/dev/block/mmcblk0p7"
Is there a better way you can recommend to make an image of the userdata partition?

How do you mount the unencrypted dd dump of data ?
mount -o loop dumped.data.img /mnt/data
As well you can untar all twrp backup files into one new data.img file.
Or tar the complete /data partition ... etc.
It's an ext4 partition ..
Of course, you can use the twrp backup files directly to restore on another pixel c device.
There is no modification needed at all.
Good luck!
Sent from my Nexus 10 using Tapatalk

That whole boot.img step.. is that why I always get stuck in a weird misplaced bootloop whenever I modify anything in TWRP? I just flash original boot.img in fastboot?

gnome9er said:
That whole boot.img step.. is that why I always get stuck in a weird misplaced bootloop whenever I modify anything in TWRP? I just flash original boot.img in fastboot?
Click to expand...
Click to collapse
The boot.img step to decrypt data ?
It's a one time task.
Once decrypted you always need to root after new boot.img flash.
If you don't root or don't use encryptable flag boot.img you will get encrypted.
Not really related to bootloops.
What are you changing when you are using TWRP ?

If I use backup then restore it loops. If I flash twrp it just boots to recovery. Now that i think about it i never did root this thing properly. Well i did with a toolkit but that doesnt count. I went beta then hated it lost root on restore then when i tried to do it again i kept running into bootloops. It says in the forums here that its common ans to just fastboot reboot but that dont work. I cant wait for the new nexus 7

gnome9er said:
If I use backup then restore it loops. If I flash twrp it just boots to recovery. Now that i think about it i never did root this thing properly. Well i did with a toolkit but that doesnt count. I went beta then hated it lost root on restore then when i tried to do it again i kept running into bootloops. It says in the forums here that its common ans to just fastboot reboot but that dont work. I cant wait for the new nexus 7
Click to expand...
Click to collapse
Depends what are you restoring
Do you backup / restore other partitions except the data partition ?
Pls don't
In general .. pls backup data partition only !
All other .img files should be taken freshly from image.
In systemless rooting world the su.img is placed on data.
You may have an older version inside your backup.
If you restore boot.img from backup, supersu ramdisk modifications will fail.
Flash what ever system.img, vendor.img and install twrp as recovery.
If you flash a boot.img, it should have stock ramdisk, to be able to let supersu.zip do the work for proper rooting.
At the same time the su.img on data will be refreshed too.
To summarize .. if you change something always install a fresh copy of your boot.img and run SuperSu.zip inside TWRP afterwards!
Hope this helps ..

followmsi said:
Depends what are you restoring
Do you backup / restore other partitions except the data partition ?
Pls don't
In general .. pls backup data partition only !
Click to expand...
Click to collapse
In this case, we're only looking to backup and restore the data partition.
Once we have the raw image created by dd, what would you say is the most reliable way to convert it to something that can be flashed by fastboot?
I've tried several different utilities to convert it to a "sparse image" but flashing it just erases data and doesn't copy anything from the image.

jason_hanley said:
In this case, we're only looking to backup and restore the data partition.
Once we have the raw image created by dd, what would you say is the most reliable way to convert it to something that can be flashed by fastboot?
I've tried several different utilities to convert it to a "sparse image" but flashing it just erases data and doesn't copy anything from the image.
Click to expand...
Click to collapse
Did you test img2simg as well ?
I use simg2img to convert the sparse to raw image, the other way around.
Or something like this below .. "s" defines sparse image.
make_ext4fs -s -l xxxxxxxx -a data data.img
Sorry, can't help you better now ..

followmsi said:
Did you test img2simg as well ?
Click to expand...
Click to collapse
Yes, unfortunately we've tried everything.
First we created the file data.dd using
Code:
dd if=/dev/block/mmcblk0p7
, which can be read as an ext4 image.
Then we tried using SparseConverter, ext2simg and img2simg to convert the raw image to a sparse image.
They all produce files of different lengths, and none of those files seem to flash successfully
They go through the flash process and report being successful, but the data isn't there.
Is there any way to debug this and figure out what's going wrong?

followmsi said:
Do you backup / restore other partitions except the data partition ?
Pls don't
In general .. pls backup data partition only !
Click to expand...
Click to collapse
Why should other partitions not be backed up? Is it not possible to flash the /data partition if you flash other partitions at the same time?

jason_hanley said:
Yes, unfortunately we've tried everything.
First we created the file data.dd using
Code:
dd if=/dev/block/mmcblk0p7
, which can be read as an ext4 image.
Then we tried using SparseConverter, ext2simg and img2simg to convert the raw image to a sparse image.
They all produce files of different lengths, and none of those files seem to flash successfully
They go through the flash process and report being successful, but the data isn't there.
Is there any way to debug this and figure out what's going wrong?
Click to expand...
Click to collapse
If you don´t get an error message from fastboot the sparse image seems to be valid.
How do you verify data partition after flashing ?
Are you able to mount and check ?
Also from recovery .. e.g. before you boot into system ?
For example on Nexus 7 flo there is still a userdata.img inside factory rom (6.0.1), but not for Pixel C anymore.
Maybe some permissions are required (file_contexts) - like on Nexus 7 flo too.
Sorry, no idea whats going wrong for you ..
---------- Post added at 12:49 PM ---------- Previous post was at 12:35 PM ----------
jogrimst said:
Why should other partitions not be backed up? Is it not possible to flash the /data partition if you flash other partitions at the same time?
Click to expand...
Click to collapse
You can backup all partitions you want .. but you should know the possible impact if you restore them.
And Yes - you can flash all partitions at the same time .. but normally you don´t flash data partition via fastboot - not on Pixel C.
In times of systemless rooting and monthly security releases there is no need for system.img backup anymore.
Unless you have special modifications inside your system.img.
If you were rooted before I recommend to use fresh boot.img and reinstall supersu.zip after change.
Just to prevent issues ...

followmsi said:
And Yes - you can flash all partitions at the same time .. but normally you don´t flash data partition via fastboot - not on Pixel C.
Click to expand...
Click to collapse
Why is userdata.img normally not flashed via fastboot on Pixel C?

jogrimst said:
Why is userdata.img normally not flashed via fastboot on Pixel C?
Click to expand...
Click to collapse
Because it will wipe your device.

cam30era said:
Because it will wipe your device.
Click to expand...
Click to collapse
Ok. Do you recommend creating a flashable ZIP file instead?

jogrimst said:
Ok. Do you recommend creating a flashable ZIP file instead?
Click to expand...
Click to collapse
Yep, pls use flashable zip for your purpose.

Related

Flashing Nandroid backups

Hi
Would it be possible for me to do the above without having to connect my phone to my laptop every time?
I know I have would have to load the boot.img first from a cmd window whenever i wanted to try a new rom, but was just wondering if I'd have to do that with it already on the internal sd card.
Any help would be appreciated.
Wiggo
Unless the backup you're restoring uses the same boot.img as the one you're using you will need to flash the one from your backup (using fastboot) when you restore it.
Recovery doesn't have permission to write to the boot partition; this means whether you're flashing a ROM or a backup from recovery the boot.img won't be written and you'll have to do it manually.
hopscotchjunkie said:
Unless the backup you're restoring uses the same boot.img as the one you're using you will need to flash the one from your backup (using fastboot) when you restore it.
Recovery doesn't have permission to write to the boot partition; this means whether you're flashing a ROM or a backup from recovery the boot.img won't be written and you'll have to do it manually.
Click to expand...
Click to collapse
That makes sense. Thanks very much for your help

Please xt1675 stock fastbboot firmware

HELLO TO ALL
i'found impossible to find it anywehere
thanks
Do you mean you want the software/drivers for your PC so that you can do fastboot commands? fastboot is part of the system partition.
I'm thinking your maybe after adb tool that can do adb and fastboot. See https://forum.xda-developers.com/showthread.php?t=2588979
THANKS
trotter2000 said:
Do you mean you want the software/drivers for your PC so that you can do fastboot commands? fastboot is part of the system partition.
I'm thinking your maybe after adb tool that can do adb and fastboot. See https://forum.xda-developers.com/showthread.php?t=2588979
Click to expand...
Click to collapse
no i allready installed adb minimal setup, and flashed correctly aicp rom... what i need is lenovo/motorola original firmware image for my G5 xt1675 sku
franco_b75 said:
no i allready installed adb minimal setup, and flashed correctly aicp rom... what i need is lenovo/motorola original firmware image for my G5 xt1675 sku
Click to expand...
Click to collapse
What are the specs of that variant?
matmutant said:
What are the specs of that variant?
Click to expand...
Click to collapse
The specs of the XT1675 if it's the same as mine
16gb storage
2gb ram
Single sim
TheFixItMan said:
The specs of the XT1675 if it's the same as mine
16gb storage
2gb ram
Single sim
Click to expand...
Click to collapse
Then, maybe the only difference is radio/RIL, and gpt and such can be same.
If you have a firmware of your device to compare that could be cool;
I could only compare with the firmwares I had under the hand : https://forum.xda-developers.com/showpost.php?p=74299135&postcount=25
Thanks
matmutant said:
What are the specs of that variant?
Click to expand...
Click to collapse
Mine is 2gb ram 16 Rom.. Single sim.. I tried to flash firmware of other sku, but security patches are very outdated, (January 2017) and of course.. Firmware update checker says that are no updates, probably because firmware is not made for my sku..
franco_b75 said:
Mine is 2gb ram 16 Rom.. Single sim.. I tried to flash firmware of other sku, but security patches are very outdated, (January 2017) and of course.. Firmware update checker says that are no updates, probably because firmware is not made for my sku..
Click to expand...
Click to collapse
Did you get a firmware for your specific device at some point (even outdated, so we can check against similar firmware for 1676)?
Nope..
I was never able to find it anywhere.. I have tried to make nandroid backup, but once reflashed it does not work.. I suspect for early immature state of twrp ported recovery..
Lenovo made a toll for resque firmware "Lenovo smart assistant, but doesn't find firmware for any g5 2017 models.. What a shame..
matmutant said:
Did you get a firmware for your specific device at some point (even outdated, so we can check against similar firmware for 1676)?
Click to expand...
Click to collapse
As far as I'm aware this firmware hasn't been released/leaked
franco_b75 said:
I was never able to find it anywhere.. I have tried to make nandroid backup, but once reflashed it does not work.. I suspect for early immature state of twrp ported recovery..
Lenovo made a toll for resque firmware "Lenovo smart assistant, but doesn't find firmware for any g5 2017 models.. What a shame..
Click to expand...
Click to collapse
If you have made a nandroid backup whilst your phone was working but it doesn't restore data (I can't remember what the error is) do the following
Both options give same result - backup anything on internal storage as it will be erased eg downloads pictures documents etc
Option 1
In fastboot mode in a terminal type the following
Code:
fastboot erase userdata
Option 2
Go into twrp recovery
Goto wipe
Advance wipe
Change format of partition
Select data partition
Select ext4
Now do the same as above but format data back to f2fs
Note a simple wipe of data will format data but not format user data hence why you need to wipe this way
Now restore your twrp backup & it should work
If it doesn't restore system you can try the same trick with wiping system although system is ext4
But then if you can still get into recovery mode the other option is to do the above but flash a custom rom zip instead of restoring backup
TheFixItMan said:
As far as I'm aware this firmware hasn't been released/leaked
If you have made a nandroid backup whilst your phone was working but it doesn't restore data (I can't remember what the error is) do the following
Both options give same result - backup anything on internal storage as it will be erased eg downloads pictures documents etc
Option 1
In fastboot mode in a terminal type the following
Option 2
Go into twrp recovery
Goto wipe
Advance wipe
Change format of partition
Select data partition
Select ext4
Now do the same as above but format data back to f2fs
Note a simple wipe of data will format data but not format user data hence why you need to wipe this way
Now restore your twrp backup & it should work
If it doesn't restore system you can try the same trick with wiping system although system is ext4
But then if you can still get into recovery mode the other option is to do the above but flash a custom rom zip instead of restoring backup
Click to expand...
Click to collapse
Thank you so much.. Y made the bad mistake to delete my nandroid backup.. I think the only solution remain to stay with custom Rom, and wait a good heart leak a fastboot firmware for my sku..
TheFixItMan said:
As far as I'm aware this firmware hasn't been released/leaked
If you have made a nandroid backup whilst your phone was working but it doesn't restore data (I can't remember what the error is) do the following
Both options give same result - backup anything on internal storage as it will be erased eg downloads pictures documents etc
Option 1
In fastboot mode in a terminal type the following
Code:
fastboot erase userdata
Option 2
Go into twrp recovery
Goto wipe
Advance wipe
Change format of partition
Select data partition
Select ext4
Now do the same as above but format data back to f2fs
Note a simple wipe of data will format data but not format user data hence why you need to wipe this way
Now restore your twrp backup & it should work
If it doesn't restore system you can try the same trick with wiping system although system is ext4
But then if you can still get into recovery mode the other option is to do the above but flash a custom rom zip instead of restoring backup
Click to expand...
Click to collapse
@Marie74, maybe the above can help with you weird issue too..
@TheFixItMan : may I link this in my WIP FAQ?
matmutant said:
As far as I'm aware this firmware hasn't been released/leaked
If you have made a nandroid backup whilst your phone was working but it doesn't restore data (I can't remember what the error is) do the following
Both options give same result - backup anything on internal storage as it will be erased eg downloads pictures documents etc
Option 1
In fastboot mode in a terminal type the following
@Marie74, maybe the above can help with you weird issue too..
@TheFixItMan : may I link this in my WIP FAQ?
Click to expand...
Click to collapse
Thanks a lot!! ?
matmutant said:
@TheFixItMan : may I link this in my WIP FAQ?
Click to expand...
Click to collapse
Yes - Of course you can
I also have a similar problem with firmware xt1675 2 gb ram 16 gb memory, single sim after installing rom mod does not reboot more in system or recowery, it always goes to bootloader and need to confirm with power key. I think the it has caused the TWRP recowery I have installed and I'm now waiting for the motorola (lenovo) to release stock firmware to install and restore.
masterdex said:
I also have a similar problem with firmware xt1675 2 gb ram 16 gb memory, single sim after installing rom mod does not reboot more in system or recowery, it always goes to bootloader and need to confirm with power key. I think the it has caused the TWRP recowery I have installed and I'm now waiting for the motorola (lenovo) to release stock firmware to install and restore.
Click to expand...
Click to collapse
It's not a recovery problem - its your misc partition
See
https://forum.xda-developers.com/showpost.php?p=74342154&postcount=184
For fix
TheFixItMan said:
It's not a recovery problem - its your misc partition
See
https://forum.xda-developers.com/showpost.php?p=74342154&postcount=184
For fix
Click to expand...
Click to collapse
Done thanks works perfectly.:good:
I'm waiting for Lenovo (Motorola) to release the Firmware for XT1675.
masterdex said:
Done thanks works perfectly.:good:
I'm waiting for Lenovo (Motorola) to release the Firmware for XT1675.
Click to expand...
Click to collapse
This is the rom stock Xt1675 Tim Italy:https://www.youtube.com/watch?v=EMyaDv1lcYg
TheFixItMan said:
Option 2
Go into twrp recovery
Goto wipe
Advance wipe
Change format of partition
Select data partition
Select ext4
Now do the same as above but format data back to f2fs
Note a simple wipe of data will format data but not format user data hence why you need to wipe this way
Now restore your twrp backup & it should work
Click to expand...
Click to collapse
thank you, @TheFixItMan, you've saved my beef re: https://forum.xda-developers.com/android/apps-games/apps2sd-partition-sd-card-link-apps-to-t3122919/page443
franco_b75 said:
HELLO TO ALL
i'found impossible to find it anywehere
thanks
Click to expand...
Click to collapse
This comment is the one that got me looking into it
I got the stock firmware for you
NPP25.137-15 1st Jan 2017 for XT1675
I made a guide on how to install it through fastboot ( bootloader also able to be re-locked )
I am working on a flashable twrp version for easier install but obviously bootloader sill has to be locked through pc
here is my guide:
click me

How to factory reset OP 3 with PC?

Hello,
it seems to be that sth went wrong today. I wanted to factory reset my OP3 but right now nothing is working.
The initial set up was the following:
Unlocked bootloader with TWRP installed. Oxygen OS + several custom ROMs installed
What I did:
I deleted the data from system partition since I thought that they Oxygen OS system data will be deleted.
Problem:
Right now I get a encryption hint without the possibiity to factory reset my OP3 since I don´t get access to the data partition in order to upload a Oxygen OS .zip on my OP 3 from my PC.
What can I do in oder to factory reset my OP3 with the help of my PC? I want to install the OnePlus 3 OxygenOS Open Beta 28.
Search mega unbrick guide method 2 and then flash the last OnePlus recovery and then flash OB28
I managed to flash the most current Oxygen OS on my OP3 by doing a factory reset within TWRP and flashing the Oxygen OS .zip and Magisk 4.5.
BUT after rebooting, the file system seems to be encrypted again in TWRP (even allowing explicitly file modifications!). This means that I am not able to flash another .zip.
How can I manage that the file system remains decrypted also in TWRP?
I don't have access in TWRP to my files in oder to flash an OS Update and so on. It seems to be encrypted in TWRP. How can I manage to have access to all my files located in the internal flash?
king0r said:
I don't have access in TWRP to my files in oder to flash an OS Update and so on. It seems to be encrypted in TWRP. How can I manage to have access to all my files located in the internal flash?
Click to expand...
Click to collapse
If you boot OOS without any force encryption disabling mod them it will encrypt. It's not a problem at all if you use the right TWRP. Pick the TWRP from the Bluspark thread and you should be fine.
king0r said:
I don't have access in TWRP to my files in oder to flash an OS Update and so on. It seems to be encrypted in TWRP. How can I manage to have access to all my files located in the internal flash?
Click to expand...
Click to collapse
Well, there is a way to decrypt the device, but you'll lose everything. Reboot do fastboot and connect to pc, then type from CMD "fastboot erase userdata" or "fastboot format userdata"
Puddi_Puddin said:
If you boot OOS without any force encryption disabling mod them it will encrypt. It's not a problem at all if you use the right TWRP. Pick the TWRP from the Bluspark thread and you should be fine.
Click to expand...
Click to collapse
Please send me a link to the thread. I can't find it.
king0r said:
Please send me a link to the thread. I can't find it.
Click to expand...
Click to collapse
http://lmgtfy.com/?iie=1&q=Bluspark+oneplus+3t
If you pay attention, it also explains how searching in the internet works. It's littery the first result if you google "Oneplus 3 Bluspark".
I was already using
twrp-3.2.1-x_blu_spark_v8.61-op3_op3t.img !!!
BUT nevertheless I don't have access to any file (e.g. .zip) even using the newest version of the Bluspark TWRP. Every directory is listed with 0 Bytes.
When accessing TWRP an Error message comes up but I can allow file modifications. But this doesn't help to get access to any file.
Flash the stock recovery
http://oxygenos.oneplus.net.s3.amazonaws.com/recovery_op3.img
Then after flash stock recovery boot to recovery all wipe (internal storage will be deleted). Done!
Flash official or Blu spark twrp. Go to Mount>check the internal storage.
madsponge26 said:
Flash the stock recovery
http://oxygenos.oneplus.net.s3.amazonaws.com/recovery_op3.img
Then after flash stock recovery boot to recovery all wipe (internal storage will be deleted). Done!
Flash official or Blu spark twrp. Go to Mount>check the internal storage.
Click to expand...
Click to collapse
Thanks, but this means that I will lose all my data located on my phone??
Will at least the already installed OOS remain?
king0r said:
Thanks, but this means that I will lose all my data located on my phone??
Will at least the already installed OOS remain?
Click to expand...
Click to collapse
Well, if you can't access your data with TWRP then you are ****ed any way.
I can only not access the data in Recovery! In OOS no peoblems at all!!
I don't understand why in Recovery nö data access is possible.

[Guide] Flashing Treble images and going back to EMUI

Index
Booting fastboot
-- Software way via Android Debug Bridge
Connect your phone to your computer and issue command:
Code:
adb reboot bootloader
-- Hardware way via bootloader function
Hold volume down button. Connect the USB-C cable.
Flashing images
Issue commands while on fastboot:
For recovery images (ex. eRecovery, TWRP):
Code:
fastboot flash recovery_ramdisk [I]recoveryimage.img[/I]
For system images (ex. EMUI 8, Pixel Experience):
Code:
fastboot flash system [I]systemimage.img[/I]
Booting recovery
-- Software way via Android Debug Bridge
Connect your phone to your computer and issue command:
Code:
adb reboot recovery_ramdisk
-- Hardware way via bootloader function
Hold volume up button while the phone is booting. Make sure cable isn't plugged in.
Backup EMUI data partition
This is important as without this, you won't be able to go back to EMUI.
Flash kilroystyx's TWRP via fastboot
Boot to recovery
Backup data partition (Backup > Tick Data, Swipe to backup)
Copy the backup to your computer after the backup finishes
(from the TWRP folder on the root of internal storage)
Installing a Treble based ROM
Flash stock recovery via fastboot
Wipe data and cache via eRecovery
Flash the ROM image to system via fastboot
Reboot to system
Going back to EMUI
• Via the backup you have done
Flash EMUI system
Flash stock recovery
Boot to recovery
Touch Wipe data/factory reset
Touch Wipe cache partition
Touch Reboot to system
Without letting it boot to system, boot to fastboot
Flash kilroystyx's TWRP
Reboot to system, let it boot completely
Reboot to recovery
Copy backed up EMUI data to internal storage
Start restoring
Reboot to system
• Via full stock firmware files
Copy FOTA and UDF to the root of your external SD card
FOTA: Full OTA (update.zip) / UDF: Data Update (update_data_full.zip)
Flash KingOfMezi's TWRP
Reboot to recovery
Wipe Dalvik, cache, system, data, internal storage
Flash FOTA and UDP respectively
Flash stock recovery via fastboot
Touch Wipe data/factory reset
Touch Wipe cache partition
Touch Reboot to system
If you have modified ramdisk or kernel flash the stock images of them as well.
You can download kilroystyx's TWRP, here.
You can find more information about going back to stock via firmware files and download KingOfMezi's TWRP, here.
After you boot up a custom system, you will not be able to boot kilroystyx's or KingOfMezi' TWRP.
If you need TWRP at that moment, use dil3mm4's Treble TWRP.
This TWRP cannot manage your data and files. You can use ADB, or use your external SD card to flash files.
Stock firmware files are here. All you need are system, recovery_ramdisk and ramdisk images.
Extract the UPDATE.APP from the ZIP file. You can extract the partition images by Huawei Update Extractor.
If you have any other questions, feel free to join our group. You can ask anything without hesitation.
If i follow your guideline, when i revert back to EMUI, TWRP cannot mount system.
It's weird cause i did flash a lot of treble roms and went back to stock several times before but not with your method.
Every time i go back to stock i got a different problem to troubleshoot due to encryption i think.
The best way i found:
Going back to EMUI
Wipe data and cache via stock recovery
Flash stock system image via fast boot
Let the system boot to the setup wizard
Flash Pretoriano80's TWRP via fastboot
Restore the backup
Wipe Dalvik and Cache
Letzen said:
You can download Pretoriano80's TWRP image here.
After you boot up a custom system, you will not be able to boot Pretoriano80's propertiary TWRP.
If you need TWRP at that moment, use dil3mm4's Treble TWRP.
This TWRP cannot manage your data and files. Use your external SD card to flash files.
Stock firmware files are here. All you need are system, recovery_ramdisk and ramdisk images.
Extract the UPDATE.APP from the ZIP file. You can extract the partition images by Huawei Update Extractor.
If you have any other questions, feel free to join our group. You can ask anything without hesitation.
Click to expand...
Click to collapse
which firmware is for ane-lx3?
i can't go back to stock recovery.
I'm using aosp treble images, i've an ANE-LX1
Someone can help me?
---------- Post added at 11:42 AM ---------- Previous post was at 11:40 AM ----------
i can't go back to stock recovery.
I'm using aosp treble images, i've an ANE-LX1
Someone can help me?
---------- Post added at 11:43 AM ---------- Previous post was at 11:42 AM ----------
I've an ANE-LX1 and i'm using aosp treble image.
I can't go back to stock emui, can someone help me?
U need to flash a stock system.img
Then flash the stock recovery
mchtt said:
U need to flash a stock system.img
Then flash the stock recovery
Click to expand...
Click to collapse
from where can we get stock system image.img and the stock recovery?
fbh59 said:
from where can we get stock system image.img and the stock recovery?
Click to expand...
Click to collapse
Find the complete firmware of your device and download the update.zip.
both are extracted from UPDATE.APP that is inside the update.zip
Unzip UPDATE.APP from the .zip file, then with the "Huawei Update Extractor" open the UPDATE.APP file and the files you need should appear and you're done, you can extract them
Is there a reason, why this guide only mentions
fastboot flash system systemimage.img
Click to expand...
Click to collapse
while the "official" one (https://www.xda-developers.com/flash-generic-system-image-project-treble-device/) mentions
fastboot -u flash system name_of_system.img
Click to expand...
Click to collapse
and
fastboot erase system
Click to expand...
Click to collapse
(before)
?
Cause you need to full wipe after a different system flash ?
I suggest:
- flashing system.img
- flash stock recovery
- full wipe
must unlock bootloader or no please reply thankx
i flash download Huawei P20 Lite-ANE-LX1 8.0.0.144(C432).zip
extracting and flash fastboot mode YES
Yes you have to unlock your bootloader.
mchtt said:
Yes you have to unlock your bootloader.
Click to expand...
Click to collapse
I cant unlock bootloader dc unlocker is error 375
How unlocking bootloader please reply bro
Hi, I have a couple of questions.
Firstly, why can't you flash images from TWRP? On the OpenKirin website it says they don't support it at all. Is it TWRP's fault or Huawei's? On my P9 lite I had a while back it worked perfectly.
Secondly, I would like to know what the difference is between the TWRP versions. Is there no support for backups on KingofMezi's one?
Thanks!

Root issues in Oreo

I'm installing twrp but whenever i try to boot into twrp all my data is wiped and twrp is unable to mount it
"Could not mount /data and unable to find crypto footer"
I need to manually change the filesystem and then again change to ext4 for twrp to mount data.
Main issue is i want to use snapchat and for that i need to boot into OS, login into snapchat and then root in twrp
but again as soon as i boot into twrp my data partition is not mountable. I have flashed no_encrypt_no_verity.dm_ashyx to disable dm-verity.
Flashed various twrp version from 3.0 to 3.2
Also did a clean OS flash from odin but still no luck.
Any suggestion and help will be appreciated.
jfk999 said:
I'm installing twrp but whenever i try to boot into twrp all my data is wiped and twrp is unable to mount it
"Could not mount /data and unable to find crypto footer"
I need to manually change the filesystem and then again change to ext4 for twrp to mount data.
Main issue is i want to use snapchat and for that i need to boot into OS, login into snapchat and then root in twrp
but again as soon as i boot into twrp my data partition is not mountable. I have flashed no_encrypt_no_verity.dm_ashyx to disable dm-verity.
Flashed various twrp version from 3.0 to 3.2
Also did a clean OS flash from odin but still no luck.
Any suggestion and help will be appreciated.
Click to expand...
Click to collapse
https://forum.xda-developers.com/sa...w-to/guide-root-install-twrp-samsung-t3747535
Baseminge said:
https://forum.xda-developers.com/sa...w-to/guide-root-install-twrp-samsung-t3747535
Click to expand...
Click to collapse
Tried that too , same issue still.
It seems that data partition gets corrupted whenever i boot into twrp everytime.
No way out
jfk999 said:
I'm installing twrp but whenever i try to boot into twrp all my data is wiped and twrp is unable to mount it
"Could not mount /data and unable to find crypto footer"
I need to manually change the filesystem and then again change to ext4 for twrp to mount data.
Main issue is i want to use snapchat and for that i need to boot into OS, login into snapchat and then root in twrp
but again as soon as i boot into twrp my data partition is not mountable. I have flashed no_encrypt_no_verity.dm_ashyx to disable dm-verity.
Flashed various twrp version from 3.0 to 3.2
Also did a clean OS flash from odin but still no luck.
Any suggestion and help will be appreciated.
Click to expand...
Click to collapse
have you wiped data(TWRP/wipe data/type YES in the keyboard)?
and use superuser for root cause magisk can t mount data at the moment.
broky said:
have you wiped data(TWRP/wipe data/type YES in the keyboard)?
and use superuser for root cause magisk can t mount data at the moment.
Click to expand...
Click to collapse
As soon as i boot in twrp, data is not mountable. So I then go to
wipe-->adv wipe-->(select data partition)repair or change partition-->change partition format-->fat
TWRP then wipes it to fat filesytem,then i change it to ext4 (which is readable by OS)
then only data partition is mounted.
Afterwards I flash no-verity-no-encryption_ashyx and RMM patch
Boots normal to OS
Again boot to twrp i get error unable to mount /data
I had this issue in nougat but it used to happen only once.After flashing patch i used to not get this error repeated
jfk999 said:
As soon as i boot in twrp, data is not mountable. So I then go to
wipe-->adv wipe-->(select data partition)repair or change partition-->change partition format-->fat
TWRP then wipes it to fat filesytem,then i change it to ext4 (which is readable by OS)
then only data partition is mounted.
Afterwards I flash no-verity-no-encryption_ashyx and RMM patch
Boots normal to OS
Again boot to twrp i get error unable to mount /data
I had this issue in nougat but it used to happen only once.After flashing patch i used to not get this error repeated
Click to expand...
Click to collapse
Twrp/above factory reset on right side there is an option format data.
Press on this option and a keyboard rises.type YES and select format data.
After this check data partition,should be mounted.
After this flash SU zip and last Ashyx s patch.
Idonel this many times never had a problem even in Orsi.
Hope it works I can t think of something else.
broky said:
Twrp/above factory reset on right side there is an option format data.
Press on this option and a keyboard rises.type YES and select format data.
After this check data partition,should be mounted.
After this flash SU zip and last Ashyx s patch.
Idonel this many times never had a problem even in Orsi.
Hope it works I can t think of something else.
Click to expand...
Click to collapse
Which twrp version are you using?
Try...
The universal "no verity opt encrypt".
Magisk for the above, or safetynet evasion.
Backing up snapchat in /data/data/ and /sdcard/Android/data/, and load the backup. By PC or external sdcard, or load the backup later.
jfk999 said:
Which twrp version are you using?
Click to expand...
Click to collapse
look in 1:13
this is the step i mean:
format data/type:yes
https://www.youtube.com/watch?v=iOjnmGQ14fc&t=41s
broky said:
look in 1:13
this is the step i mean:
format data/type:yes
https://www.youtube.com/watch?v=iOjnmGQ14fc&t=41s
Click to expand...
Click to collapse
Tried it but still same issue.
Bryan48765 said:
Try...
The universal "no verity opt encrypt".
Magisk for the above, or safetynet evasion.
Backing up snapchat in /data/data/ and /sdcard/Android/data/, and load the backup. By PC or external sdcard, or load the backup later.
Click to expand...
Click to collapse
Tried the universal version for samsung and applied RMM patch, unfortunately same issue again.
I think that this has to do with SEpolicy. In nougat i used to get a small red warning at the edge of screen while booting to twrp. That time i did not face this
issue. Now I dont get any warning..boots into twrp with data partition corrupted.
I dont know, ive tried everything possible but no luck.
This is how I did and it works on my A320FL:
1. I installed Ashyx's version of TWRP via odin.
2. Boot into TWRP and "Format Data" from "Wipe" menu.
3. Flash SuperSu.
4. Flash Ashyx's patch.
5. Reboot phone(into recovery again).
6. Update TWRP with McFy's version.
jfk999 said:
Tried it but still same issue.[/QUO
I think I have the same issue.
May was your phone branded when you bought it?
Click to expand...
Click to collapse
Baseminge said:
jfk999 said:
Tried it but still same issue.[/QUO
I think I have the same issue.
May was your phone branded when you bought it?
Click to expand...
Click to collapse
I bought it from official store..Also i bought it jus few months after launch..
Which carrier are you using?
Click to expand...
Click to collapse
jfk999 said:
Baseminge said:
I bought it from official store..Also i bought it jus few months after launch..
Which carrier are you using?
Click to expand...
Click to collapse
So I think is something concerning the MM firmware that was not fixed with the N and O updates, 'cause I bought it very close to his launch too. I solved it by flashing a custom rom, so I think the problem was in official MM firmware or something went wrong in the OTA updates
Click to expand...
Click to collapse
Baseminge said:
jfk999 said:
So I think is something concerning the MM firmware that was not fixed with the N and O updates, 'cause I bought it very close to his launch too. I solved it by flashing a custom rom, so I think the problem was in official MM firmware or something went wrong in the OTA updates
Click to expand...
Click to collapse
Well ya..from MM to N, I did Odin update but from N to O i did ota update..since then im facing this issue..
But i still dont get it..i did a clean install and downloaded firmware from sammobile..yet this issue persist
Click to expand...
Click to collapse
jfk999 said:
Baseminge said:
Well ya..from MM to N, I did Odin update but from N to O i did ota update..since then im facing this issue..
But i still dont get it..i did a clean install and downloaded firmware from sammobile..yet this issue persist
Click to expand...
Click to collapse
At this point the only advice I can give you is to do a full wipe including "Internal Storage" (if you didn't) before flashing with Odin.
I really don't guess it will solve the problem on an official firmware, but there's no harm in trying
Click to expand...
Click to collapse
Still no luck...
At this point i have lost hopes
jfk999 said:
Still no luck...
At this point i have lost hopes
Click to expand...
Click to collapse
No matter what you try at this point you're data will always encrypt and will need to be formatted. TWRP will always reset.
This requires a whole different route and needs you to edit system files.
I'll get back to you with details.
---------- Post added at 11:25 PM ---------- Previous post was at 10:39 PM ----------
jfk999 said:
I'm installing twrp but whenever i try to boot into twrp all my data is wiped and twrp is unable to mount it
"Could not mount /data and unable to find crypto footer"
I need to manually change the filesystem and then again change to ext4 for twrp to mount data.
Main issue is i want to use snapchat and for that i need to boot into OS, login into snapchat and then root in twrp
but again as soon as i boot into twrp my data partition is not mountable. I have flashed no_encrypt_no_verity.dm_ashyx to disable dm-verity.
Flashed various twrp version from 3.0 to 3.2
Also did a clean OS flash from odin but still no luck.
Any suggestion and help will be appreciated.
Click to expand...
Click to collapse
This method requires intermediate knowledge of Windows and CMD commands....I've tried to simplify it and hope it is easy enough to go through
The files that need editing are the ramdisk fstab files.
Basically you are going to unpack boot.img, edit the files and repack it.
Here's how you do it:
In windows...From the firmware, open the AP file with WinRAR. Extract boot.img.lz4 and save it to your desktop
Go here https://github.com/lz4/lz4/releases/download/v1.8.2/lz4_v1_8_2_win64.zip
Extract it then just place your boot.img.lz4 to directory of lz4
Next open up cmd as admin and cd to the location where lz4.exe is located
In cmd type lz4.exe boot.img.lz4
This will unpack the lz4 file.
Now download http://www.mediafire.com/file/93a3f4bikaxh6tj/MTK_Extractor_V2.6.3.zip
Just open exe go to boot tab select the unpacked boot.img
This will extract the files you need and it will create folder called "initrd" and it will contain the contents of boot.img.
Make sure you have Notepad++ installed to edit the files.
Go to the MTK folder where your files have been extracted
Right click Fatah.goldfish and select open with Notepad++
Next find the phrase ",encryptable=userdata"
Delete it
Close the tab in Notepad++ and click to save
Back to MTK folder and right click fstab.ranchu. Open with Notepad++
Find the phrase ",quota,forceencrypt=/dev/block/vdd"
Delete it
Find the phrase ",encryptable=userdata"
Delete it
Close the tab in Notepad++ and click to save
Back to MTK folder and right click fstab.samsungexynos7880. Open with Notepad++
Find the phrase ",verify"
Delete it
Find the phrase ",forceencrypt=footer,quota"
Delete it.
Close the tab in Notepad++ and click to save
Next, go back to the MTK program and press the repack button
This will create your new boot.img file
Go back to the MTK folder. You should see your old boot.img file saved as "boot-old.img" and your new file as "boot.img"
Install 7-zip
Back to MTK right click your new boot.img. select 7-zip then select "add to archive"
This will open up another window. Simply select "tar" from the dropdown menu for "Archive format"
Press OK
This will create a new file "boot.tar"
Flash this via Odin with phone in Download mode
The boot will now be patched and you can set up TWRP as you need.
This whole process will need repeating if a new AP is flashed

Categories

Resources