yashsingh1/xdaforums huggingface dataset:
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
I`d suggest re reading the directions, the things you are asking about are plainly stated in those directions. Re-read and absorb them slowly. It takes time.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] darkensx:
Is there an twrp for the v40 that supported or supports the Oreo version?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Legitsu:
why does the meta-data bootable, or the flashable zip not have the inject twrp option ?

on stock Q the non metadata bootable does not boot
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] darkensx:
I know on pie I had to do the format data then reboot back to fastboot and boot twrp from the img file as it can error out with the the injection process but if it's missing completely in Q sounds like something changed the Ramdisk either the location or whatever the twrp looking for. The developer may have to check.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Legitsu:
Interesting sounds like that might be the case, I Have a work-around for now

once you get it installed and verity disabled it works fine but the instructions do not apply to stock android Q at least not on my 405UA-VZW

here is my boot.img containing twrp and magisk

Install instructions

THIS HAS ONLY BEEN TESTED ON The Verizon Variant 30C Android 10/q Flash it on anything else at your own peril

Stock Q Verizon

img contains TWRP and Magisk and disable verity (you still need to reflash the disable verity and magisk zips anyway)

Install instructions

requires unlocked bootloader (duh)

Note For some reason the meta-data version used here doesn't inject properly you need to re-flash the TWRP installer Remember the TWRP installer unroots you so remember to re-flash Magisk

Flash image to boot_a* or boot_b* whatever your current active partition is (on stock its nearly always A) you can use QFIL or fastboot flash boot_* 30C_VZW_TWRP_MAGISK.img

if you are encrypted you need you need to flash the disable-verity-forceencrypt first ( https://zackptg5.com/android.php#disverfe) (stock is always encrypted )

1.flash the disable Verity zip reboot to recovery

2.format /data (format not wipe!!)

3.Flash the TWRP installer zip in the OP if you want TWRP on both slots (required to get injection working again **pre metadata only! )

4 .flash Magisk(21.0+) https://github.com/topjohnwu/Magisk/releases

5. reboot and install the Magisk manager for full root https://github.com/topjohnwu/Magisk/releases

DL Patched boot.img below

https://www.androidfilehost.com/?w=files&flid=319566

if you are leaving stock then you need to flash TWRP after flashing your rom, reboot to recovery on the other slot and then re-root using magisk
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] yumm91:
Works fine for me, from 405UA-20e (Pie) to 405EBW-30b (Q), flashed with LGUP with Partition DL mode (unlocked bootloader).

Steps I did:

1) Install 405EBW-30b KDZ using LGUP

2) Go to 9008 mode, using QFIL with firehose, backup laf_a. Erase laf_a.

3) Go to download mode (with laf_a erased, this will move to fastboot mode automatically)

4) Fastboot boot twrp.img (bootable twrp-first link in first page)

5) Flash twrp.zip (+ 2nd link in first page). It will show boot_a and boot_b patched. This means you can go to recovery with reboot recovery now. (similar to ramdisk injection on original TWRP)

6) Re-flash magisk zip and you should have root & TWRP installed. (does not work for me, if it works, the steps end here)

==============================================

This is what I did as normal magisk flashing via zip does not work for me.

6) Go back to QFIL in 9008 mode. Backup boot_a.

7) Manually patched boot_a using magisk manager.

8) Go back to QFIL in 9008 mode. Restore boot_a using patched_magisk.img.

Now the stock ROM (Android 10 EBW 30b) will have root & TWRP installed. If you need to restore the rom, just switch the slot to B and you can activate the download mode.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] CodeDonut:
bro you are a life saver!

no matter what i did, fastboot boot twrp.img was always giving me errors. flashing the vrz 30c kdz with lup_cmd then flashing your boot.img with qfil allowed me to access twrp and restore my efs backup! :D

you the man!!
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Zephyr76:
Hello Here is a picture I am on android 9 with the v35 charger with twrp on the way only I can not start my system it goes up to the logo lg v40 and after I enter twrp suggestions I have something magnifying glass?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
I don't speak French but most of your error output seems to be about encryption. The way the process is suppose to work, is after qfil the boot loader with twrp, u need to go directly from qfil to twrp (don't boot the device). Then format data and reboot recovery, then flash the dm-verity zip and magisk zip.

then it will no longer be encrypted. cheers.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] Zephyr76:
Thank you for your reply ,

The problem is that I have to restart the device because the bootloader in the menu activated the oem unlocking is ok but I no longer have the v35 bootloader menu indeed I have to turn on the device poir reflash abl_a with the v35 image from this moment I go into the bootloader to install twrp with some difficulty I have to insist with the fastboot commands and afterwards I have twrp which starts up but I can no longer go to mo ' android pie because the v35 charger does not start with what to do?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
Sorry, but I cannot follow what it is that you are doing (and thus indicate where to change).

What I would suggest would be to make a copy of the directions you are following, have them numbered 1 thru whatever.

Underneath ea one of the directions; indicate what you did, and what the result was. Copy (just the directions) from the original post, underneath ea one, say what you did, expected, what you think is wrong or right, etc.

cheers
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AnDevil:
Hi all,

I am quite inexperienced in all of this, but I managed to unlock the bootloader (the official way) and enter it. Being in the bootloader, I type the command 'fastboot boot TWRP-judypn-boot.img' and it looks like this in powershell (see attachment).

Right after it says 'sending boot.img' and then 'booting' I see the warning screen (that one where it says that device has unlocked bootloader), then the v40 start screen, then once again the warning screen and then the phone just boots up normally. So i just cannot replicate steps 5-10. Can anyone help me understand what am I doing wrong?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] abuchison:
This Verizon boot.img unfortunately is incompatible with AT&T Android 10. The symptom is random long freezes in System UI. The issue goes away after I flash the original boot_a back. I guess I will have to live without TWRP for now.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] racer8dan:
I have an unlocked stock att v40 with android 10, am i able to install twrp on this as well? My goal is to have lineageos 18
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
yes, of course. If you read the threads on this subject, they all refer to 'all models, except t-mobile'... so... is yours t-mobile? No? then yer good.

first, when u say 'unlocked' you mean carrier unlocked right? You need it to be bootloader unlocked to accomplish what u say u want. And with Q, you don't 'install' twrp anymore. You have to have the bootloader image with twrp already in it. But that's not hard to find. I have a link to it posted in another thread.

I'd focus on unlocking the boot loader, if u haven't done so already.

cheers
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] racer8dan:
yes carrier unlocked.

All the guides i see say to have twrp installed prior; heres one i was looking at: https://rootmygalaxy.net/lineage-os-18-lg-v40-thinq/

Can you elaborate a bit on your method, links you have?

Thanks
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
That author fails to mention a pretty vital aspect of 'not working' (and may not even know it). Unfortunately, the lg code for volte and vowifi is proprietary and thus doesn't work on lineage, so for us in the US, with carriers doing away with 3G (I believe t-mo has already done this or will be very soon), that's a big problem if your phone isn't capable of volte and or vowifi.

Another thing, and why I wouldn't follow that guide, is they probably haven't done this themselves, they seem to have just copied the instructions for a different phone and applied them to the v40, probably because they saw SGMarkus rom available.

But they are using directions from a single slot phone, not a dual slot, which is what the v40 is (they say to wipe data, cache and system, but SGMarkus directions point out correctly to wipe data (not the others) from lineage (slot b), not slot a, where your lg stock 10 firmware will be).

I would follow the guides here on xda, you have the opportunity to read other comments to avoid pitfalls, and to ask questions if u have problems.

the directions are easily found in the main forums of 'v40 Guides' and 'v40 roms'.

cheers
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] 2566SB:
work in Android 10？
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] 2566SB:
When i am in android Q

fastboot flash boot TWRP-judypn-boot.img

sending 'boot_a' (30804 KB)...

OKAY [ 0.662s]

writing 'boot_a'...

FAILED (remote: unknown command)

WHY IT?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
Well, 2 things. 1) that way doesn't work anymore with android 10. You have to have the boot partition with twrp already installed, or make one yourself. And 20 it was never 'fastboot flash boot'... that's combining 2 fastboot commands together, it's either 'boot' or 'flash'.. not both.

which OS are u using, which version? I may have or can get the boot part with twrp in it, for you.

cheers
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] racer8dan:
Ill soon be flashing this verizon kdz:

V405UA30c_00_VZW_US_OP_0814.kdz

Do you have this?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
Yup, follow this link and it will be for vzw 30c with twrp in the boot partition. I'd save off the original in case you need it, before flashing this, with qfil of course.

keep in mind, after flashing this, you want to go directly from qfil to recovery, don't boot the device. Once there, format data, then reboot back to recovery. Then flash magisk and verity. Should be all set then.

cheers
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] racer8dan:
Awesome! thanks for the help! I will try this soon
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] racer8dan:
Not sure if I did this right but.. I flashed this to abl_b but it gave me a black screen that said press any key to shut down with no other modes available except edl, so i tried the v35 eng bootloader but now i get a gray screen that says lge crash handler : uefi crash, again with only edl available. Do you know how i can restore some typ of functionality?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
it's the boot partition ;) It's not the abl partition. The boot partition (this), should be flashed to the boot_a (assuming your active slot is a).

I'd guess you can get back by flashing the original abl_a, so long as you haven't changed anything else. If not, reflash a kdz or a bkup if not kdz avail.

cheers
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] racer8dan:
The only thing that was changed was abl a & b. I made a backup up of both, but nothing changes when i flash them back, maybe the backups weren't done right? I used the "read" function which spit out a bin file. I have been unable to get the phone into any mode except edl, so im not sure i can use lgup on this one:(
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
Well all I can guess is that when u flashed the twrp/boot partition (which is some 63 meg in size) to the abl_a partition (which is some 1 meg in size), it overwrote nearby partitions. I would have thought it would error off before doing that, but maybe not.

I'd suggest, if u can, flash a kdz to it with lgup. If that's not possible, you'll have to get the various needed partitions, and flash them, to make lgup recognize the phone. I can help find those for you or point you in the direction to get them, if lgup doesn't recognize the phone now.

cheers
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] racer8dan:
I cant get it into download mode; trying lgup with the gray crash screen shows up as unknown, so it won't allow me to continue
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
Okay, no surprise. Follow this link, it's to a gdrive folder that has the files that should help u. Read the file I put in there called 'notes' it should be easy to follow. I feel I should point out, do not, under any circumstances, flash an image file to a partition it doesn't belong in. The boot one goes in boot, the laf one goes in laf, the abl one goes in abl, the dtbo one goes in dtbo.

and yes, any that are for both _a and _b you need to flash the image to both _a and _b. They are identical, that's why that's okay to do.

cheers
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] racer8dan:
Than

Thanks for the help, I flashed all 4 files to both a and b slots, but nothing changed. Still on the gray uefi crash screen, Im pretty sure qfil is working, it shows "finish send image" with no errors
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
Yeah that was a possibility, I'd have to guess than the the gpt partition table is a mess now with partitions being overwritten. I'd suggest going to the rom devel forum (forv40) and in the lineage rom topic, first post, SGMarkus put an 'invite' into the v40 tele group. Join that and ask for help there. I know those guys have helped others reflash the gpt table info and have recovered devices. Best way to approach them is don't make assumptions about what's right or wrong, just tell them exactly what you see in front of you, and exactly what you've done. That will make it easier for them to figure out what's wrong, and what to do to help.

good luck
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] racer8dan:
I will take your advice, thanks again
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SASUKE THE DRAGON SIN:
Please help me I want to unlock my bootloader for lg v40 thinq 405ua10m please help me
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] racer8dan:
Using the solution received from telegram group I was able to restore some functionality and reflash the kdz with lgup:) i also installed twrp boot partition you gave me and waiting for the phone to boot up now, my question is if i want to install lineageos, will i have install twrp using recovery ramdisk before flashing lineageos or will twrp remain on the boot partition after its installed?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
Hey good you got it back, that's encouraging. I've only installed lineage once and don't have it anymore. Only because it doesn't support vowifi and volte.

I'd suggest in the tele group, type in '/notes', that gives a list of all the doc's they've created for all the various issues. It will have the most up to date info re how to do almost anything. When I had lineage I used the recovery built into it, but there is a way to have twrp on both slots, just didn't do it myself.

cheers
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] racer8dan:
Thanks for the tip
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] racer8dan:
For anyone else in my situation, here is the unbrick method from telegram:

Download (https://drive.google.com/drive/folders/1WQaaM35SWiF_UbXAM8hiRB95D2CDkIEq) the backup. Unzip it to find 7 luns (0-6).

1. Open QFIL

2. Select Flat Build

3. Click load xml and select the rawprogram(#) XML that is in the lun(0-6) folder.

4. If it asks you for a patch xml, click cancel. It's not needed to flash this backup.

5. Click download

6. Repeat steps for each lun folder.

I wasn't able to install luns 0-2 and got a firehose error, so i moved on to 3 & 4 which worked, but I had to close out qfil and reboot the device back into edl after each one. I only did luns 3 & 4 because when I rebooted I got the lg logo back and was able to put the phone into download mode and flash a new kdz with lgup.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] The_Y8Y_Rapist:
Anyone willing to make a video for noobs where to cover everything and post it on youtube? I will subsrcibe to him.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] SASUKE THE DRAGON SIN:
Can someone please help me with my lgv40 thinq 405ua i want to unlock bootloader and root please help me.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] bsteph27:
hello maybe this help you https://xdaforums.com/t/edl-mode-9008-v40-very-easy.4233059/
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] bsteph27:
hello i have a probleme.

obviously I succeeded in unlocking the bootloader. if the phone is not connected to usb it automatically boots from a fastboot menu.

I flashed the twrp by following hthis howto

unofficial twrp 3.3.1 Root LG V40/ LG V40 thinq - unofficial twrp

download twrp 3.3.1 root LG V40 thinq, user who own LG V40 thinq can root it by following the below instructions

unofficialtwrp.com

i try flash twrp judypn boot in boot_a and boot_b

it was successful

but fastboot flash vbmeta

writing 'vbmeta' ...

FAILED (remote: Cannot flash this partition in unlocked state)

finished. total time: 1.076s

I cannot boot from the recovery. I even have options that disappear at the top of the menu before I had to start reboot turn off recovery and only start power of reboot

please help
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
First, I'd suggest to (generally speaking) not follow guides unless they are from XDA. In the XDA guides, like this one we are in now, you have many comments to read indicating if the guide 'works or not'.

The one you followed is wrong. It will not work.

Even this guide could be updated, because the newer roms you have to use qfil to flash the (already by someone else) boot_a partition with your specific OS boot partition and twrp already installed in it.

You don't say which version of EBW you're using, but if it's 30b, then use This Link to download your boot partition with twrp already in it. (If u have a diff version say so and I'll see if I can find the boot+twrp for it).

Next, that's not the way to fix vbmeta. Follow This Link to a folder that has both the blank vbmeta u need and also a file with text instructions showing exactly how to flash it.

Third, there are 2 ways to get fastboot on your device, it's important to know the difference because one version is much more powerful than the other, and can flash partitions etc, where the other cannot. The 2 ways are 'nuking the laf' partition, which u then lose the LGUP (flash kdz) ability (until you flash the laf partition back). What that means is, with laf nuked, you go to laf but nothing is there so OS gives u a modified and stripped down version of fastboot. In many cases it's very crippled.

The next way, and the one you'll have full fastboot, is to flash the v35 eng abl to the abl partition of the inactive slot (because if u flash it to the active slot the device won't boot unless you're running Oreo). Flashing it (using qfil) to the inactive slot means you switch to the other slot in bootloader mode, use fastboot, then switch back to other slot when done.

good luck, it's not as difficult as it sounds.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] bsteph27:
first thanks for your answer.

i have a lg v40 lg-v405ebw

I flash the twrp in the boot_a and boot_b partition

is that bad?

i try re-flashing your boot v30.img file reset everything to zero?

i try your boot ebw 30b ebm and i ha a big black screen with minuscule white word
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
Well first, u say u 'flash' the image... how? did u use qfil or fastboot?

You have to use qfil to flash my 30btwrp boot image to boot_a. Then, after exiting qfil normally (hold vol - and pwr for a few seconds), wait for the lg logo to appear and release pwr and then re press it.

In other words, you want to go directly from qfil and into twrp recovery. Don't boot the device. Once in twrp, cancel pw if requested, swipe to allow mods. Then format data. After that reboot to recovery, flash magisk and dm_verity. Should be all set then.

cheers
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] bsteph27:
i used qfil for flash your 30btwrp in abl_a as in the guide of xda...... i'm lost.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
It's confusing to me, why oh why, anyone has the idea to flash a BOOT partition to ABL?

ABL is NOT A BOOT partition! ABL is the android boot loader, not the boot partition.

Sorry, but the reason YOU SHOULD NEVER DO THAT is because you run the chance of overwriting the partition and then corrupting the partitions next to it! And then the device will be a brick.

Why would you flash a boot image to the wrong partition? What makes you think you should do that? It's beyond me.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] bsteph27:
sorry i dont know wrong an right partition. it's write in the xda guide with v35eng.img. ithink is the same of your 30btwrp.

https://xdaforums.com/t/guide-unloc...8-mode-every-variant-except-t-mobile.4042207/.

i write a howto for v40 phone in french for when i done with my phone..... with explain. howto dont explain....
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
That guide, which is correct, is explaining how to use the v35_engineering_abl_a to get fastboot on your device, which is needed to unlock the bootloader.

The guide you should follow to get twrp installed is the one you're in, and it does not say to flash a boot_a image to abl_a.

abl_a partition is only about 1 meg in size. If you flash an image to it that is greater than 1 meg, you will overwrite whatever is in nearby partitions. If you do that, your device will probably be a brick.

you need to spend more time reading the comments so you better understand what you're doing. I know it's not in french, but it would be better to use a translator (like google translate) than to just 'guess' and have it go wrong. If it goes 'wrong' you may not be able to get your device back.

cheers
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] bsteph27:
please could you help me on skype discord or else in pv please?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
There is a post, above, #247, by someone that also over wrote their partitions.

If your device is no longer functioning, follow the above post to try to unbrick it. All the information you need to un-brick it is in there. There's nothing more I can tell you that it doesn't say, and I don't speak french so can't explain it either.

good luck
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] bsteph27:
my phone is not bricked it goes into sahara mode.

would it be possible to find a backup of all partition tables and inject them back into v40 and start from scratch please?
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] AsItLies:
I just said, look at post #247, it has what u need.
[LG V40 ROMs, Kernels, Recoveries, & Other Developm] bsteph27:
thank you very much I flashed the phone with the backup and it starts again. I have followed the bootloader guide to the letter.

and sorry if I seem slow it's true I try to translate English myself to progress.

now i flash your 30btwrp in which partition exactly with qfil please?