14

[GUIDE] [ADVANCED] Bootloader Unlock and Root for the T-Mobile LG Velvet (G900TM...

 1 year ago
source link: https://forum.xda-developers.com/t/guide-advanced-bootloader-unlock-and-root-for-the-t-mobile-lg-velvet-g900tm-only.4458055/page-2#post-87504949
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

[GUIDE] [ADVANCED] Bootloader Unlock and Root for the T-Mobile LG Velvet (G900TM ONLY)

[previous post]

thanks for the response. its been a while since ive messed with an lg device. figures it would be overly complicated.

overall seems like a nice product. couldnt believe they skipped face unlock tho. the in-screen thumbprint is only so-so, esp with a screen protector. kinda sucks cause i wear gloves at work most of the time. good chance ill end up reselling or shelving the velvet for something else before too long.

------------

i opted to go with the ubuntu live distro linked in post 1 ... just to be safe on the version, plus having resources baked in.

i have everything i need except a recent-ish android kdz to re-upgrade with. found a couple sources but file sizes look way too small to be a full image (~1.x gb).

A) do you have a source on a legit v11 kdz? the more recent the better

B) OR is there any way to use lgup (or anything else) to extract an image of the version im running already?

EDIT: ive already ran a backup thru LG Bridge app for windows, but appears to only backup user data and such, not the system image

< KDZ downloads >

EDIT 2: even tho the file size shows 1.2gb on those android 11 kdz downloads, once download begins, it jumps up to 5.2gb (for 20g version). seems legit

any way for me to make complete backups, or even just system image backups, without having custom recovery? i ran a backup using lg bridge windows app, but appears to only backup user data and settings, not the rom

Last edited: Aug 15, 2022
[I have successfully rooted this device. i took some notes in hopes to clarify/simplify the process for others.]
  • this is meant to be a supplement to the other root guides (linked below), and may not be complete in every detail.
  • i used a windows 10 desktop, and a laptop running the ubuntu live disc linked in post 1. also, a flash drive to store files and swap between computers as needed. of course, youll need a type c usb cable capable of data transfers and your T-Mobile LG Velvet 5g [LMG900TM] with phone drivers installed on the windows box
  • for me, unlocking the bootloader and/or rooting broke OTA updates
  • fingerprint unlocking still functions normally
  • this is the method that worked for me, but may not be the only or best way to get the job done
  • attempt at your own risk.
[GUIDES & Info]
  • follow the general guidelines from post 1 and this xda tutorial
  • ubuntu live disc to usb created using rufus windows application, set to leave remaining storage space on usb stick as persistent storage for the live session to use as 'hard drive' space
  • for file swapping, i used a usb flash drive formatted to exfat due to large file size of android images (5gb each, plus other resources, room to extract app zips, and store patched boot images)
1. [Windows] [Backup User Data] [Optional Step]
  • you can take a backup of your settings, apps, etc with the LG Bridge app for windows if you dont want to start over with a clean install after downgrading/upgrading the android version.
  • this only backs up settings and whatnot, not the system image, boot.bin or anything like that.
  • this is a completely optional step
2. [Windows] [Downgrade Android Version]
  • install patched LGUP to windows
  • run LGUP
  • with phone powered off, hold the volume up key then connect the usb cable to boot the device to download mode
  • select the android 10 .kdz file as shown in the guides
  • toggle refurbish option
  • click start to downgrade your device to android 10
  • NOTE: this will wipe your device of all user data and end with a clean install of android 10
  • allow to auto boot and finish the process before disconnecting the usb cable
3. [Linux] [Unlock Bootloader]
  • extract mtk v1.52 to your usb stick
  • insert into rig running the Ubuntu live session
  • open mtk 1.52 folder on usb and right click -> open terminal here
  • with phone powered off, run 1st python command in guides in the terminal window. allow to run and finish
  • leaving phone alone, proceed to running the second and third python commands.
  • disconnect phone cable and power on as usual
  • take note of the bootloader unlock warning (doesnt look as pictured in guides)
4. [Windows] [Upgrade back to Android 11] [Optional]
  • open LGUP on your windows rig
  • with phone off, hold volume up key, then connect the usb cable to enter download mode
  • select the android 11 .kdz file as shown in the guides
  • select the DL option in LGUP
  • click start, then a popup box will show up
  • in the popup, choose the "select all" option, then un-select the "[0]preloader" option
  • start the flash process to upgrade back to android 11
  • allow device to auto boot before disconnecting the usb cable.
  • note the "red state" bootloader unlocked notice during boot process
  • once booted, reboot device to show the typical "orange state" notice as pictured in the guides
5. [Windows] [Restore User Data] [Optional Step]
  • run LG Bridge to restore personal data to device if you decided to take a backup before downgrading to android 10
  • device will auto reboot once restore completes
  • NOTE: i took a backup while running android 11 version 20i. backup successfully restored to version 20g. both were android 11 builds.
6. [Phone] [Enable USB Debugging]
  • skip thru setup, etc., enable developer options, then enable android debugging in dev options
  • power phone off
7. [Linux] [Extract/dump boot sectors from stock rom]
  • open MTK 1.52 folder on your usb stick in linux
  • right click in folder -> open terminal here
  • enter boot dump command for boot_a, as shown in guides, press enter key
  • now plug in your powered off phone to usb cable
  • boot dump process will begin for boot_a
  • allow to finish process
  • with phone still connected, proceed to enter the boot dump command for boot_b as shown in guides
  • allow process to finish
  • NOTE: boot dump files will land in the MTK 1.52 folder on your usb stick
8. [Windows] [Copy boot dumps to phone]
  • move the usb stick over to your windows pc
  • with phone powered on, connect it to your windows pc
  • copy/paste boot dump a & b files over to phones internal storage.
  • create a magisk manager folder if you like, or just use the downloads folder. remember where you copied the files to tho
9. [Phone] [Download and Install Magisk Manager APK]
  • download magisk manager apk from github
  • run downloaded apk to install magisk manager to your phone (allow unknown sources)
10. [Phone] [Patch boot sectors using magisk manager]
  • open magisk app on your phone
  • in the "Magisk" box, choose "Install" option
  • on next screen, select "patch a file"
  • browse for and select boot_a.bin file you copied to your device in step 8
  • tap the "Let's Go!" option in magisk app
  • patched file lands in phones downloads folder
  • find and rename the output file to something like "velvet_boot_a_patched.bin" (will originally be a .img file, rename to .bin)
  • repeat these steps for boot_b.bin file, rename output file accordingly (velvet_boot_b_patched.bin)
  • copy both patched boot .bin files back over to your usb stick. anywhere is fine.
11. [Linux] [flash patched boot images for root]
  • in linux, right click on desktop and open terminal here
  • download/install adb & fastboot tools using sudo apt-get command
  • copy/paste patched boot images to the desktop
  • right click open desktop area -> open terminal here
  • with phone booted up, connect usb cable.
  • have usb connection set to file/data transfer mode and allow android debugging access to the linux computer when prompted.
  • type command to reboot into fastboot mode: adb reboot fastboot
  • NOTE: if errors given, try using the kill-server and start-server commands outlined on the page linked in this section
  • phone will reboot into fastboot mode
  • type the following command to push/flash the patched boot image to the phone: fastboot flash boot_a [whatever you renamed your boot_a patched file as].bin ; press enter and allow process to complete
  • repeat the process to flash patched boot_b image to the phone: fastboot flash boot_b [whatever you renamed your boot_b patched file as].bin
12. [Phone] [Reboot and check root access]
  • on your phone, use power button to select "Reboot System" option on fastboot mode screen
  • once phone boots, sign in to the Play Store
  • download "Root Checker Basic" app
  • open root checker app and select the "Verify Root" option
  • grant root checker basic superuser permissions when prompted
  • it should say "Congratulations! Root access is properly installed on this device!" if all went as expected
  • you can delete the root checker app once you have verified root access, if you wish. it serves no other function.
  • magisk manager must stay installed for modules to function
[Magisk Modules, Etc.]
  • you can now use your web browser to download magisk module .zips and activate them via the magisk manager app, under the modules tab
  • id recommend bootloop protector module as a safeguard.
  • also an unlock wifi hotspot module paired with the VPN Hotspot app from play store along with a vpn. this allows you to have unlimited hotspot data regardless of your phone plans allotment, and a secure vpn tunnel for hotspot traffic. without vpn hotspot app, your tethered data doesnt run thru your vpn even if its activated on your phone.
  • ive personally used more than 200gb of hotspot data in a month on the $40 single line plan thru metro by t-mobile, which comes with absolutely no hotspot data by default. no problems whatsoever.
Last edited: Aug 16, 2022
I just want to chime in and thank all the people that made this root possible. I had trouble unlocking the bootloader using Windows. Ended up using the live CD and that worked like a charm.

I got the phone for free during last year's T-Mobile Black Friday. Now that it is rooted, the phone is actually useful. It's really not a bad phone. The screen quality is great. It also has a headphone jack and a built-in FM radio.

EDIT: Just found out that the memory can be expanded to 2TB with an sdcard and there is also a desktop mode if used with a USB-C to HDMI dongle. If this had a better camera, I would actually consider using it as a daily driver!
Last edited: Monday at 6:13 AM

Reactions: double b26

I just attempted this and made a mistake with the manipulation to upgrade to android 11 🥲
I checked like 4 partitions after preloader and it went flashing with LGUP... Now stuck in endless bootloop, don't know how to turn off the phone and marked as unknown on lgup. So basically can't even recover 🥲
Please help!
Can I use the mtk command to reflash some img? or put it to fastboot? How do I even enter fastboot?
There is a high chance I messed up ftm partition
Tried flashing all partitions with mtk GUI, now phone does not boot hehe

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK