This is a test root method for the G4. It is based off of the original root method for rooting LG devices. The original method showed modified in the boot loader but it didn't have su. This a modified script to push su correctly and the su used by the H815.
Note: On the H815 If you would like root all you have to do is unlock boot loader, flash twrp for G4 then flash the supersu.zip
WARNING: USE AT YOUR OWN RISK!!
I am not responsible for bricked devices, dead SD cards,
thermonuclear war, or you getting fired because the alarm app failed. Please
do some research if you have any concerns about features included in this ROM
before flashing it! YOU are choosing to make these modifications, and if
you point the finger at me for messing up your device, I will laugh at you.
The Recovery used in this is TWRP for H815 and I am not sure of how compatible it is with other variants but if it gives you root then its worth testing.
Step 1: Enable USB Debugging
Step 2: Download G4 Flasher and unzip, Also Install Drivers
Step 3: In unzipped folder open a new command prompt window (Shift+Right click)
Step 4: Run this command
adb.exe push recovery.img /data/local/tmp/
Step 6: Check Device Manager> Serial Port (Windows) and make sure your Phones COM is set to 41, if not then change it. After changing it you may have to unplug usb, pull battery and then reboot into download mode.
Step 7: Open a new Command prompt window just like before. in the folder you extracted.
Step 8: Run this Command
Step 9: Run this to Backup your current recovery
dd if=/dev/block/platform/f9824900.sdhci/by-name/recovery of=/data/local/tmp/recoverybak.img
dd if=/dev/zero of=/dev/block/platform/f9824900.sdhci/by-name/recovery
dd if=/data/local/tmp/recovery.img of=/dev/block/platform/f9824900.sdhci/by-name/recovery
Step 13: Flash Supersu.zip
Note:: to restore original Recovery all you have to do is pull it
adb pull /data/local/tmp/recoverybak.img \
Rename it recovery.img (you might have to delete or rename the one that was extracted from the zip earlier because the can only be one recovery.img in a folder )
then rinse and repeat all the steps