yashsingh1/xdaforums huggingface dataset:
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] g-member:
Wut?? you mean stock recovery??

then what.......

I can't get twrp installed, so i can't flash SU/Magisk
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] néonaloj:
How do you try to flash the TWRP recovery (exact steps)?

If you follow the rule, it must stick...
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] g-member:
As always.....

i was running twrp 46 just fine but i wanted the OS update so i rolled back to stock recovery.

After the update was done i lost root ofcourse so i put the phone back in fastboot and flashed latest stable TWRP in fastboot.

C:\twrp>fastboot flash recovery twrprecovery.img

target reported max download size of 536870912 bytes

sending 'recovery' (24612 KB)...

OKAY [ 0.884s]

writing 'recovery'...

OKAY [ 0.234s]

finished. total time: 1.120s

i rebooted into system and again in recovery but no twrp.......

i got the screen where i must enter my password for decrypting, and after entering my password the stock recovery appears......

EDIT: GOT IT, WITH MY OPO I JUST REBOOTED INTO SYSTEM NO PROBLEM, BUT WITH THE OP5 TWRP GOT OVERWRITTEN.....IT'S A MUST AFTER FLASHING TWRP TO DIRECTLY BOOT INTO RECOVERY.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] néonaloj:
Do NOT reboot into system, but instead, reboot manually (power + volume down) into TWRP.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] -fluffy-:
well

i backup oos 4.5.2

wipe dalvik cache an cache

flashed new oos 4.5.3

wipe dalvik cache an cache

flashed SU

restored my data

wipe cache an dalvik

rebooted

phone comes wiht 1+

then it reboot again

an this picture comes up that it wipe cache an data

no matter what i do

its the same wen i try to restore my backup it boot an then it reboot an do the same again

so no matter what i end up whit a clean phone an need to updata all my data an apk again
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] CroW_D:
Some can say me if restoring only the boot.img on cheeseburger 46 is a problem or not ?.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] benc88:
So anyone tried 62 data restore? Let the Dev know.. man's working his balls off.....they are going to look like Hershey kisses!
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] Flint2:
TWRP 58 ?

Tried Flash 4.5.2 and then restore?

Looks like once you flash OOS, you cannot restore anymore, is like OOS does not recognize data, somebody needs to investigate what files to delete after restore (encryption keys??)

For example. on 3T, after Data restore, you need to delete some files to regen security fingerprints and pattern because is not recognized.

More investigation is needed, possibly connect ADB and get bootloop info.

Running out of ideas...
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
To clear up the confusion:

If you use the latest test image it won't wipe your data if OOS decides to do it, at least that's how it has been before.

The problem with restoring data is rather simple, but rather hard to find a solution:

The backups are fine, and after restoring a data backup the data is there.

But when booting OOS with that, it can't set the policy on /data/local which will cause the system to reboot into recovery and wipe data.

So please test the new test image and stop complaining about things we have already explained multiple times.

To make sure everyone gets to know this, I'll add it to the first post.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] -fluffy-:
Well i didt try wiht latest and it didt wipe data after reboot it booted into twrp again and wipe data

Trust me i have try All day:crying:
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Seems that you didn't read what I just wrote. I said that OOS will tell TWRP to wipe your data because something fails.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] -fluffy-:
Well i didt read but what i dont get

Wen i got the phone and flashed the update to 4.5.2

All went well and i restored my backup no problem at All

Phone booted kept root

It is only after i updated to 4.5.3
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] dansou901:
[MENTION=6584600]xdvs23[/MENTION], just an idea: Does it help to connect via adb shell while in recovery and run restorecon -RF /data after doing a data partition restore? Maybe it doesn't because selinux context on TWRP is different than in OOS, but still worth a try.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] Hackpb:
Well just flashed lastest TWRP, installed freedomOS, installed some aps... rebooted to recovery and have done a backup. Then to test if last version of TWRP is working for restore data, I have wiped data, cache, dalvik and system. After that, I have done a restore and reboot, and now it allways goes to TWRP dosen't boot--- don't know if it is a usefull information?...
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] djsubterrain:
Wiped data or erased data? That behaviour sounds like the data partition doesn't exist.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] Hackpb:
Wiped data - like that - wipe, then advanced wipe - and I have selected cache, dalvik, data and system. And then I have done a restore with all of the options like efs, boot, system, data etc... and reboot then it showed oneplus logo and rebooted again to twrp...
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
I was actually about to do this yesterday but I wasn't sure if this wouldn't make it worse because wouldn't running restorecon set the contexts how TWRP wants and not how OOS wants? I don't get one thing. Since restorecon /data runs on every system boot, why does it still not work?

I'll try it anyways.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
The system instructs the recovery to wipe data because it fails to set the policy.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] dansou901:
That's quite easy to find out. Just list the directory permissions while in TWRP and compare that to the permissions shown in OOS. If they are the same, it should be fine, otherwise something else needs to be done.

---------- Post added at 07:46 AM ---------- Previous post was at 07:45 AM ----------

Sorry that I can't help with that myself right now, didn't have time for messing around with my system...
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
We'll see
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
[MENTION=4588971]dansou901[/MENTION] Tried to do restorecon_recursive /data in various places but it doesn't help. Any ideas?

This is where the problem is: https://github.com/omnirom/android_system_core/blob/android-7.1/init/builtins.cpp#L374
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] thy1985:
hello there

i rooted (with oxygenos 452 running) via the latest working twrp from this thread. That worked fine (Thanks for that xdvs23!). Also backup seemed to work.

Now there is an update to Oxy453. For sure OTA incremental failed. But trying to flash the full zip afterwards via twrp (which usually works quite well) failed for the following reason:

The package is for a "Oneplus 5"; this device is a "" (empty string). Is that something I can fix somehow on my own or is is a minor bug in the latest twrp for the OP5?:confused:

Thanks for any input!

Cheers,
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] materoprodutions:
so I've read a lot of pages on this thread, what is the correct way to update to the latest ota without loosing apps and settings? I'm pretty confused
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] JRevenge:
Hello, i try on OnePlus 5 8/128GB with Oxygen 4.5.1 but lock on boot TWRP. I have try the three version and all don't work.

Have you got a fix?

Thanks a lot
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] rav101:
Sorry, I didn't elaborate. I was working on the China version and going to provide logs but mean't for anyone hoping for a working version that didn't want to go through the process of helping debug.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] djsubterrain:
Build 9 just sitting on the teamwin logo screen for me when using "fastboot boot twrp-oneplus5-9.img"
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Ok so I added some guidance for providing logs to the first post, hoping that someone will come up with logs.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Yeah could you please send me a log like described in the first post
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] rav101:
Okay,

To help make things easier on myself, before flashing test v9 I cleared everything in my cache using a root app.

Installed v9 and waited for a while after it was hanging on the splash screen. Came back to system and with root I have gone to cache/recovery and it's empty? I have attached an image below to show I'm in the right place.

Could be that your recovery isn't getting to a point where logs are being generated?

Either that or I'm just not helpful and someone else might be better placed to support?
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Well this means then that it does not even get to mount the partitions...

This means that something is wrong with encryption that prevents anything from happening...
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Alright new image: Download here

I changed it up a little bit maybe the encryption will work properly now.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] djsubterrain:
OK, Flashed the chinese TWRP, it asks for a password when booting which I seem to remember was an issue with the 3T also, if I press cancel, it lets me advance but I can then copy the first log you asked for but when browsing to the SDCard to paste it there for uploading, there are a nonsense list of folders shown which don't actually exist on the storage.

---------- Post added at 08:36 PM ---------- Previous post was at 08:34 PM ----------

Build 10 still sticking at the logo
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Hmm, interesting...

Noted that.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] rwallhtc:
how should i send them
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
I'm making a new one, this has to work
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] djsubterrain:
Getting the following when I try to get into recovery now, I think the fact it's asking for a password is important, I do remember it being a major problem when the 3 first came out
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] rav101:
I have just tried version 10 with my systematic approach of removing everything from cache and once again, i didn't see anything in cache/recovery after trying to boot into twrp.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
New image: Here
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] rwallhtc:
find attached the logs you asked for. I already had root. Flashed and attempted to boot recovery. stopped on splash
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Well that's the stock recovery you have there, isn't it?
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] djsubterrain:
This is the password screen shown when going into the chinese TWRP
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] djsubterrain:
No, I had flashed the chinese TWRP to recovery, possibly if you don't put in the password too many times it'll reflash the stock recovery itself?
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
This is confusing
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] benschhold:
Can anyone who has problems restoring nandroids do a fastboot format userdata before the restore? Thanks for feedback
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
The latest working twrp should have that issue fixed. If not, try the test image.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Just update, that's not of a problem, as far as we have seen here.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] benschhold:
Can someone who has proplems restoring nandroids and not get it booting, do a fastboot format userdata before the restore? Thanks for feedback
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] VelosCohagen:
I rooted my OP5 on Oxygen 4.5.2 with magisk. For the update to 4.5.3 I flashed latest magisk Uninstaller and then the full rom via ADB sideload. Then I flashed magisk again and wiped cache and dalvik. That worked for me.

Btw I used a special version of adb.exe. I don't remember where I downloaded it, but I think it was mentioned somewhere in this thread.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] thy1985:
hi - I don't know if it is the "correct" way (so be careful, no warranty) but what I did for that with my Oneplus One and Two to achive OS updates without loosing apps/settings/data is (I assume this is working the same for the Five but never tried due to the issue I posted above EDIT: Worked fine for the five, just did it):

1. Let Oxy download the incremental update (usually just a few MB) and "do the update" which will fail and boot up again (assuming you have stock recovery, I usually only boot twrp instead of really flashing it)

2. Let Oxy do the download again. After a failed incremental it will download the full zip (1 - 1.5GB usually). With stock recovery this can't be flashed as well. But the big zip is located in folder .Ota/ (emulated storage 0) and named for example like this OnePlus5Oxygen_23_OTA_008_all_1706262145_0393170a9.zip (If you can't find it use find / -type f -name *Oxygen_*zip 2>/dev/null on the (phone's) terminal to locate it)

3. boot into twrp and dirty flash the full zip

4. reboot (lost root/yposed etc..), verify this works

5. boot into twrp, flash supersu or similar and xposed (sadly not availbale for nougat yet)...

6. reboot

=> Done.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] SynergyKim:
Depends on what you mean by "correct." :)

If you're stock, just update via the OTA option or go to One Plus website to download the ROM. (not trying to talk down, just an attempt to be helpful)

Otherwise, you'll want to do the whole song and dance to use TWRP and gain root.

I'd keep tabs on this thread, though, as we'll likely see new versions rolled out since the Kernel is currently prebuilt OOS one which is included in device tree (from the OP's first post)
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] thy1985:
oops- I managed to boot a version that is a couple of days old as i mixed files when fastbooting. I'll try again. Sorry for the confusion and thanks for your reply!:good:

EDIT: i can confirm using v58 instead of v46 of twrp works fine for flashing the update and re-rooting. :cool:

Thanks for your reply. And a good point - my current adb is not yet working with the new phone, just fastboot. Need to find the equivalent of that exe for my OS now. :)
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] jorgis1:
How does one remove TWRP asking for decryption password when first booting to recovery?
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] WaseemAlkurdi:
[MENTION=6584600]xdvs23[/MENTION]

Just a little thought: what happens if you use the "dd" command to backup and/or restore the /data partition?

dd is block transfer, and OOS won't recognize it.

Or it would?
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] unknownblkman:
How do you update software for op5 rooted... I've never done this before help
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Why would you? The password is the same as on your lockscreen.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Just as usual. The OTA updater of OOS will give you all information you need.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
I guess that would be no problem at all, but do you really want to backup your 54 GB / 118 GB or whatever it is just for that?

I did that on my OP2 already, it works flawlessly.

Should do on any other device as well.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] unknownblkman:
Is there a reference page to look at as I've never done this b4
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] WaseemAlkurdi:
Thanks for the quick response!

I actually mean that you do that (on a fresh wipe) to troubleshoot the issue with TWRP restore.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] jorgis1:
Just wondering because ive never had to do that before. Its an extra step...
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] Hackpb:
Has anyone managed to put system as RW? I have tried everything like mount -o rw,remount,rw /system and other commands but I never managed to take system to RW it always stays in RO. It is something to do with encrypted data?? Thanks
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
As I already said, the OTA updater already tells you what you need to know. Just do the update and the OTA updater as well as TWRP will handle the rest for you.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
I don't think it will make a difference because dd'ing will copy the partition 1:1
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
It's because of encryption, nothing to worry about, just make sure not to restore data backups until that is fixed.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
No, it does not. TWRP has asked you at the beginning whether you want to allow system modifications so that is the first thing you need to allow.

And system is mounted RW when doing it on the mount page.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] Hackpb:
Yes I have allowed TWRP at first boot to allow modifications, but when in OS I'm not able to make it RW to remove some system apps. Am I missing something? Sorry for disturbing...
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Root file managers like Solid Explorer tend to do that better, but why don't you simply delete the apps you want from TWRP instead?
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] materoprodutions:
I'm rooted with 4.52 on and twrp v 58. I've used custom roms and flashed stuff a lot of times in my oneplus one until a fdew days ago. My only concern is if Booting in twrp, flashing full ota and wipe dalvik+cache, flashing magisk will overrwrite twrp and put me back in stock recevory (and so I'll need a computer again to reflash twrp) or twrp will survive the update. Thank you
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
After doing the OTA you need to reflash TWRP.

As already said flashing magisk or supersu should keep TWRP installed but it doesn't survive OTA updates.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] materoprodutions:
Thank you for the answer, so after I flash and boot the new version I'll need to connect to a computer, go fastboot and reflash TWRP.img ? pretty annoying
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Exactly.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] Flint2:
What happen if you flash TWRP just after flashing full OTA before reboot ?
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] dansou901:
If it doesn't work, I'm out of ideas for now, sorry. Thanks for trying!
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] Hackpb:
Yes I know that solid explorer and others do that also commands in terminal. But I never can get it to rw. I know I can delete in TWRP but in OS I can select more rapidly and I thought that this info could be important to you because in other phones I can always achieve system to rw...
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] dkryder:
i was getting this with the early builds, got a recent stable and no more error 7.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] 3DSammy:
These instructions have work perfectly for me since I flashed this thread's stable TWRP. Use the instruction titled "For Rooted Users with TWRP Recovery" which starts part way down the post. FYI I've left encryption on but I doubt that would make a difference except that you can't use Magisk if you've decrypted.

Also after flashing the full OTA and SuperSU (in my case), I've never lost TWRP therefore never had to reflash TWRP after applying a full OTA.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] rwallhtc:
Delete
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] Dinerve:
Thanks, tested OTG over 13gb of backups/restore and worked like a charm. My OTG USB stick never had worked before that version in TWRP
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] yaarnamiley:
Thanks for making this possible!!
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] uzzz2004:
Hi guys,

congratulations for the job ....

I have a problem when starting the recovery asking me to enter the sign to unlock, is it normal ?.

Inviato dal mio ONEPLUS A5000 utilizzando Tapatalk
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] dansou901:
Yeah, it needs the sign for decrypting the internal storage
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] mofeywalker:
Yes, this is normal. It is necessary in order to decrypt your partition
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
My guess is because OOS secretly remounts system as rw, does some dirty stuff, and then remounts to ro again, that all at boot, and later you can't do it anymore because it has already been done.

You could try this:

su
mount -o remount,rw /system -f

Or this on your computer:

adb root
adb remount
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] xdvs23:
Since I am working together with [MENTION=4729623]benschhold[/MENTION], you can also follow his instructions.

As he already told, could someone do fastboot format userdata and then restore the TWRP backup?
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] Hackpb:
Thanks. I will try everything (maybe today) and report back specially the format userdata.... Keep the good work
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] djsubterrain:
I thought the issue was something like this cos when I was trying to remove the encryption I used "fastboot erase userdata" and forgot to add "fastboot format userdata", when I tried to boot the phone it was bootlooping like people were describing so it sounds as if the phone can't see the userdata partition when it's wiped, like TWRP is erasing it instead of just formatting it.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] jirorocker:
Thanks for sharing
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] rwallhtc:
Made no difference at all. This was my method.

Updated to twrp 62, made a backup and moved to my laptop. Wiped system, data and cache in twrp.

Rebooted to bootloader and fastboot format userdata.

Rebooted to the recovery and moved the backup back to the device. Restored aforementioned backup including data (exc. Userdata) and rebooted system

Rebooted once then it auto booted to twrp where i had to wipe data and round it goes
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] moro686:
Hi, is this recovery stable enough to do all the basic stuff? (flashing rom, wipe partitions, etc)?

otg is working?

thanks
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] mofeywalker:
Definetly stable enough to flash and wipe, but as said multiple times in this thread there are currently problems restoring backups. Just check the last comments. :)
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] Flint2:
Maybe a bit offtopic, but Titanium Backup can restore from TWRP backup ?

At least we can mitigate restoring apps.
[OnePlus 5 ROMs, Kernels, Recoveries, & Other Devel] nadejo:
Anyone noticed that Data and Cache Are on ext4 and There is no f2fs Option in twrp?