yashsingh1/xdaforums huggingface dataset:
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] kuapao:
I joined V40 Telegram group and was able to get is resolved with /notes from there. It helped to get a different judypn image file. It helped that in TWRP, I reflashed to boot the pre-saved boot image, then attempted to mount Vendor and System and Format Data, before installing any TWRP nor Magisk.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Roizoulou:
can you please share the img? I am stuck in fastboot without recovery
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] kuapao:
Try this video. He has links for obtaining files.

"How to Install Custom Recovery, Custom Rom and Root on LG V40 ThinQ [All Files Provided"

Good luck! It is easy to miss steps and even if you did things in the correct order and completely, who knows if it will work out.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] saiankun:
links off I have my v405ua with unlocked bootloader, I would like to install rom with android 12 but for that I need custom recovery my current rom and android 10 verizon variant
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] ctl999999:
anyone have the twrp metadata bootable "zip" file? The link below from page 1 is dead. Thanks a lot.

Metadata bootable: https://drive.google.com/file/d/1hdzeH3AIQVf3siQNsI27IS_vmghPESEG/view?usp=sharing + Install zip: https://drive.google.com/file/d/1CQUfg54zD838detcIJqdRiKXdVNtd6Iy/view?usp=sharing
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] 1slotrk:
Dead links, but they worked for a little while. At least they are dead for me.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] sahoo56:
Hello, can some one please upload twrp.img as links are dead
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] whitedavidp:
Trying to upload the one I used here. Hopefully it will work for you.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] xaxxelous:
Ok, thanks for the clarification.

I was a bit confused because I could access my exFat sdcard in TWRP (but not internal storage), then the sdcard was "corrupted" in Pie. Not how I thought it should work at all.

Any plans for exFat support?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] copota:
I have Sprint variant LG V40 LM-V450UA running Oreo 8.1.0 that has OEM unlock ability.

Since TWRP needs Pie firmware to install, I was wondering if anyone can post a link to a guide they used to successfully get Pie on a Sprint/Oreo in order to flash TWRP. Thanks for any help.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] xaxxelous:
You probably just need LGUP, the no root part here:

https://xdaforums.com/lg-v40/how-to/guide-lgup-root-t3967858
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
So TWRP has actually working exfat fuse, glad to hear!

The Problem with exfat in stock is that the module for the driver is external (aka in the rom), but the kernel (for security reasons) wont load that module (different signature/compile time)

There are patches for that though, and i might include an exfat driver in future
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] xaxxelous:
Apparently twrp does, and that makes a lot more sense.

If you do include those patches it would be much appreciated. Thanks for your work!
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] 寒水易珏丶:
hi，im sure that i'm following the right way...but,when i "fastboot flash boot_a twrp.img"and restart,it just stocked on verizon logo...my system version pie UA20C and its rooted.

now i'm downloading V405QA720A firmware...i wish your twrpboot can boot in these version...I'm trying
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] avaie:
Hi - Internal Memory isn't accessed. Is there a disable verity (f.stab - or something of that sought)? The device is rooted and TWRP installed but Magisk does not work. I do not want to risk formatting without a implementing dm-verity function.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] curtis91:
Hi

Anyone has a way to implement successfully TWRP , cause with oreo or pie when i reboot it s a bootloop with logo or fastboot mode ?

Regards

Fred
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] eric3231559:
[MENTION=3475147]SGCMarkus[/MENTION] is there anyway to unlock the bootloader or swap rom without unlocking the bootloader ?

when i try to unlock my LG v40 it is telling my is LMV405EBW-sea version (Singapore), and unlock bootloader is not available.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
Youre encrypted, you cant get around formatting internal storage (and change in the vendor fstab to encryptable, follow xsavis instructions for that)

You need to contact someone with a octoplus box to unlock the bootloader on any V40 which isnt a EUROPEAN V405EBW (e.g. on Telegram in the v40 group)
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
Tell me which model + current security patch youre on.

As i soon have time, might try to make a fastboot bootable version which ignores the "skip_initramfs" (but then you mustnt flash that version, just use it to install recovery ramdisk)

atm do this: fastboot flash the twrp

boot it

flash stock boot image into the slot you installed twrp into (within twrp, do not reboot after)

then go to advanced and install ramdisk -> select twrp there

now you have twrp in stock boot
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] eric3231559:
Could i get a link to join that telegram group ? Or could u let me know where i can get to join ?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] curtis91:
Hello Mister Markus

On this V405EBW i have tried since last pie ( twrp one time ok after reset factory) until this oreo 10E security january 2019 and impossible to boot twrp with oreo.

It's unlocked by lg , i can t setup a twrp boot there and i don t know what s boot image to use ?

Regards

Fred

---------- Post added at 09:19 PM ---------- Previous post was at 09:18 PM ----------

Hello Mister Markus

On this V405EBW i have tried since last pie ( twrp one time ok after reset factory) until this oreo 10E security january 2019 and impossible to boot twrp with oreo.

It's unlocked by lg , i can t setup a twrp boot there and i don t know what s boot image to use ?

Regards

Fred
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
In the LOS thread, theres an invite.

I made the TWRP with the V405EBW 20b kernel and security patch initially. And it worked.

Oreo doesnt work atm, because it would require a different kernel. It should work on Pie though.

And as you appear to have flashed kdzs already, unpack them and extract the boot.img, thats what i meant.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] je2854:
Is there a way to bootloader unlock the Verizon version just yet?

I want TWRP on my device lol
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Ainz_Ooal_Gown:
Yes you just have to pay for the unlock...it's been out for a while now.....
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] je2854:
Could you send me the link or the direction of where to go to speak to the guy?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
come to the V40 telegram group, the guy is in there (link is in the LOS post)
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] sirs2k:
Flashed this on 405EBW Australian stock and it's stuck on boot logo.

Have I bricked my phone?

Then When I finally get into twrp (after hard reset key combo) I can't install recovery ramdisk, keeps saying Vendor not mounted
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Ainz_Ooal_Gown:
So mount the vendor .-. and if your on Stock then it won't Boot...there should be a guide that shows you how to have TWRP with Stock....
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
Well, it booted for me, on V405EBW 20b (European) ?

thats what i made this for, anything else may result in not direct booting into Stock it seems...
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Ainz_Ooal_Gown:
Seems like, definitely won't Boot into Sprint Stock or US unlocked Pie....
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] skeeeee:
I have a Korean variant V409N on Pie with bootloader unlock. Can I flash this without having root at the moment?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] karlico:
Hi,

My phone wouldn't boot after flashing twrp.img. Yesterday it would get stuck at lg boot logo. Today however it goes straight to fastboot mode when i turn it on.

When i boot to recovery I will first have to go through the old recovery before I get to the new twrp.

I did try to follow the instruction, but a/b partitioning might have messed it up for me.

Before I flashed twrp I checked the current slot which was A. Then I flashed the recovery file to slot A. It was pretty unclear if I was supposed to flash it on the current active slot or the inactive one. Instructions says: "4. fastboot flash boot_a TWRP.img (or boot_b, depends on the slot youre on)".

I'm not able to backup in twrp (in case I mess it up some more) because it says fail to decrypt data.

How should I proceed? Im still active on slot A, havent tried B. My end goal is to get lineageos 17 on it.

-Karl
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Ainz_Ooal_Gown:
What Android version are you running on both slots?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] karlico:
It was the android 9 version. I guess that was slot a since it was right before I unlocked the bootloader and started the process. Haven't checked b though.

Btw cant use slot b either. It bootloops. I thought that b would still work since I havent done anything on it.

I got the phone just 2 weeks ago and, although I could, I have never done any update on it.

edit: The phone model is the LMV405EBW.ADECWU
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
keymaster probably crashing because of security patch missmatch (boot.img and system need to have the same security patch)

Currently working on a new TWRP, where you wont have any of these issues...

For now:

Flash twrp

directly boot to it with button combo

in twrp: flash back stock boot image from your system version (e.g. from a kdz extracted), dont reboot yet

go to advanced -> install recovery ramdisk -> select twrp.img on your phones memory (internal, or ext. sdcard)
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
A little update here :)

Its not as complete as i wanted it to be (encryption still doesnt work... :/ ), but this TWRP should be "good to go" nonetheless.

It now has the ability to be booted, no need to flash anymore (aka you can then proceed to patch your existing boot slots with TWRP), and it properly formats /data now, without stock complaining about "not properly encrypted" when youre doing the decrypt process.

OP will be updated soon.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Ugedarkline:
can u upload v409 pie bootlooader unlocked. ???? i get bootloop on logo after flash custmRom , ablpiestok..,

status at fastboot screen v405 , unlocked , active slot-b
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Danny Fernandes:
LG V40 Indian Model

Hi, will this TWRP work on LG V40 Indian Model?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] axelhimself:
Problem restoring Backup

Hi,

after formatting the drive in TWRP I restored a previous made backup and got a bootloop. I backuped and restored all partititions.

Please can.you tell me what went wrong?

Greetings

Axel
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
Which partitions did you restore?

Which ROM did you backup/restore?

Is the slot where you restored to the correct firmware version?

more infos pls...
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] axelhimself:
Hi,

Sorry for the few infos.

I wanted to restore your LineageOS 17.1. I checked all partitions till EFS for backup and restore. I was in slot B. In Slot A was still the V20a I think.

Do I restore in slot B when I don't change it?

Thank you very much for your help

Axel
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Danny Fernandes:
LG V40 Thinq Model Number- V405EBW (indian model)

Hi

I want to install TWRP. However, it does not reboot to system after flashing TWRP in the ram disk and instead it reboots to TWRP only.

Please provide me a solution.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
Its only neccessary to backup and restore boot, system, data, vendor and dtbo. Dont need anything else actually...

does the other slot still work?

In the TWRP which "automatically" starts (which shouldnt), can you give me the output of the following (preferable with adb shell)

cat /proc/cmdline

(you can remove serialno if you want)
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] axelhimself:
Thanks for the information. Yes I think slot A works because I refurbished the phone with LGUP and the V20a. Then I installed LineageOS 17.1 which is now on slot B. Means V20a was in slot A, right? Didn't check before installing LineageOS.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Infy_AsiX:
The steps I had to take from stock to get onto LOS were a little different. I couldn't use fastboot commands for some reason so used EDL to replace boot_a and b to TWRP. Once in TWRP I ran the install recovery ramdisk option to be sure but I don't think it's necessary. Then I had to use it's factory reset to clear the stock encryption, just wiping the standard boot, system, data partitions wasn't enough. Then I could install LOS to the other slot, reboot to other slot recovery, install gapps, reboot to recovery again to install magisk or else it would just error being installed immediately in the same session as gapps it seems.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
Couldnt use fastboot commands?

Could you not boot fastboot, or did it just load for ages, or just not do anything in fastboot? For the later, try a different USB port, or replugging the phone while it does "nothing" (and make sure correct usb driver is installed for fastboot)

Edit: if you flash the bootable TWRP into a slot, it will ALWAYS boot TWRP, not the system (that doesnt apply to when you use that TWRP for installing its ramdisk)
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Infy_AsiX:
Could boot fastboot. I had commands give off different failures but most common was just along the liens of command does not exist IIRC. I guess I can try the rear motherboard USB2 ports next time. There are separate usb drivers for fastboot? I've only installed the LG official phone drivers.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] argon9898:
Hi. I cannot boot the image using fastboot. I'm currently using stock Oreo, does that mean I have to switch to Pie?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] clutterking:
I had similar issues. Switching to a USB 2 port fixed it
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] KouaV1:
So this only works on android pie? Just making sure cus im on oreo and it keeps failing. My phone is the US unlocked LG V40
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] karlico:
I'm, first off, very glad you are working on this.

So I've got the stock boot images (a and b) from a suitable kdz file. Used the software SALT.

However, I cannot install any image file. They do not appear under Install - install image in twrp. Zip files appear, the image files show up under the file manager and I can backup with the error "Failed to umount ''/system_root" (Device or resource busy)". The same error shows up when i try to repair a partition under the wipe section.

Same problem with the old and new twrp.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
Yep, requires pie (idk what LG changed, but the pie kernel wont boot on oreo bootloader).

If its really requested, and i have time for it, i can make an oreo bootable TWRP, if enough people want it (and wanna test it).

The "Failed to umount ''/system_root" (Device or resource busy)" is somewhat normal after an operation like installing roms, or injecting TWRP for some reason :confused:

Just reboot recovery again and its fine.

You images have the file ending ".img" and not ".image" like SALT unpacks them?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] karlico:
Dunno about the error because it still comes after rebooting directly to recovery.

Okay, that's why the files didn't show up^^ Can I just rename .image to .img and install?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] argon9898:
Let me know if I can contribute :)
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
Hmm... so you (re)boot to recovery, and the first thing it does is showing you that error O.o ?

Can you give me a recovery log?

And yeah, you can just rename it. Some extractors name it .bin, or .image or .img ... all the same files, just different names.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] karlico:
Recovery Log attached (the first one was too long to upload as file or as text).

The error is not the first thing that comes, but after a backup:

"...

Updating partition details...

...done

Failed to unmount '/system_root' (Device or resource busy)

[BACKUP COMPLETED IN 139 SECONDS]"

However, afte I flashed boot_a.img (no errors) and install twrp again under "install recovery ramdisk" I get the error failed to mount vendor. Should I install vendor_a.img as well? I still cannot boot.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] karlico:
double post
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
Thanks for the log

What are you trying todo btw? Or better, in which situation are you?

Seems like something is wrong with your vendor partition according to the log (TWRP is unable to mount it at all, not just after flashing something).

Other than that, theres no error in the recovery.log (which is created anew whenever you start TWRP btw).
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] karlico:
Well I hope to get the stock rom to boot and work again. Don't know how. Phone wouldn't boot after i flashed the original twrp that was made. Got stock on lg logo on slot a and slot b boot-looped. Still pretty much the same. This was a few weeks ago. I tried to follow your instructions on how to move on from original post on page 5, but get this vendor/system_roots problems.

My long term plan is to install lineage on it.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
Original TWRP was based on V405EBW 20b (july? or so security patch), it isnt able to boot any system that doesnt have that security patch (will max go to bootanimation, and then when looking at logs, you would see that keymaster is constantly crashing).

To get stock working, i guess flash a kdz? Maybe with partition DL so you dont override a maybe modded LAF or so?

The /system_root isnt an issue, your vendor issue (it cant mount it at all, says size is 0MB) probably needs a reflash of the partition :confused:

I remember on telegram someone had a ducked up vendor partition too, i dont remember what they ended up doing then though.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] KouaV1:
so i did all this but how come I cant install anything on slot A? I have my custom rom on slot B. Ive seen people say they got custom rom on both slots, so is there a way I can free up the useless stock rom on slot A since cant use it?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
As long as your slot A is on pie firmware (abl/bootloader, modem partition and so on...) just boot TWRP from slot B, and install a ROM, it will end up on slot A.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] KouaV1:
oh okay, the posts were like confusing. so its just if Im on slot B in twrp then I install a rom it goes to A, and if on A it gets installed on B. correct?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SGCMarkus:
Yep, always to the non-active slot ^^
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] bestgames:
Please Help! I did all guide of Xsavi to get bootloader unlocked. But after Revert to STock Pie img from v35.img, i can not access Fastboot.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Ainz_Ooal_Gown:
You flashed the Modified stock pie abl correct? if so button combination is now "Vol + and USB cable" not "Vol - and USB cable"...
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Restian Rony:
Excuse me sir

I have done all the instruction

Until delete LAF so the fastboot will always there and twrp can be installed and i have root with magisk instruction

So my question

1. How to enter twrp? I can enter it with adb reboot recovery only on homescreen

2. LAF is deleted so i dont have download mode. How can i flash my fw if something goes wrong ? But i still want to have my fastboot and twrp ?

3. Is there any custom rom ? I have read on here like DotOs and Lineage, but when i searching on google i found havoc 3.0

But i cant found any artickel or review on that rom.

4. Any stable rom ? I needed all the V40 feature working. And i use my device to gaming.

Thanks for your advanced

Pls help me
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] R800x_user:
1.) To enter twrp you need to do the master reset button combination or just go to fastboot and select recovery. It's A bit tricky since some of the lettering for fastboot covers up the selection

2.) Laf can be flashed back on using fastboot. You just need to get the laf_a and laf_b flashed to it's respective slots

3.)I'm using lineage that Markus has up in the developer section running smooth for the most part. I haven't tried any other roms to give you a opinion about stability.

4.) Since you want stability I'd say stay on stock rooted and use third party launchers like lawnchair or Nova to give a stock Google feel. Plus you would be able to use all the lenses of the camera if you care about that.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] karlico:
Thank you for the help and sorry for late response.

This worked and I could flash a stock rom with lg up. slot b still wont boot. Could be I havent flashed that slot with a rom or the vendor issue.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] whitedavidp:
Backup/Restore/Open Recovery Script Working?

Hello and thanks for this TWRP and any help you can give.

I use TWRP on several older devices and rely upon it for doing backups and restores when I screw up. To help with this, I use Open Recovery Script and Tasker on my rooted devices (I will insist on rooting a model LM-V405QA7 if I buy one) to automatically perform full TWRP backups nightly. Basically, I generate a ORS and put it into /cache/recovery/openrecoveryscript and then do a /system/bin/reboot recovery. TWRP seems to see the script file and process it, rebooting back to the system automatically when done with it.

My experience does not include any devices like this using slots, etc. So please forgive my ignorance in asking. But it would be really essential to me to know how/if this all works. If I have to make modifications to my technique can someone please let me know what they may be?

Thanks very much.