TWRP and ROOT for Tab 4 8/10 (Plus) (TB-8704X/F/V,TB-X704L/F, TB-8504X/F, TB-X304L/F)

Search This thread

jsgraphicart

Senior Member
Nov 25, 2011
6,295
1,884
OnePlus 7T
Google Pixel 7 Pro
So, I flashed the boot.img, recovery.img and system.img from needrom (factory images for 8.1) and almost everything ist dandy - except that TWRP cannot decrypt the partitions. Which unfortunately means I cannot root the device.

I'd really like to keep /data, if possible.

adb sideload does not work, as soon as I start it, adb doesn't see any device.

Any chance to gain root without formatting /data?

From what I gather, the TWRP we have can't read anything on the 8.1 system. So it's like it doesn't even detect anything on the device. I have read though that it can still read off of the SD card. So if you put the root zip on an SD card and flash it from there it should work. But with this TWRP, it means you can't backup or restore anything if something goes wrong. This is why I haven't rooted yet. Hopefully we get an updated TWRP someday.
 

StuBeers

Member
Jan 11, 2018
22
6
Ok... does anyone have a full OTA for tb-x704v? Checked russian site... my setup doesn't let me dload direct from site. Malware warnings.
 

michaave

Senior Member
Dec 27, 2010
52
9
This thread deals with at least 9 different variants of the Tab4 so it is very necessary to mention which model you have.

Unfortunately for you I have the TB-X704V so I cannot supply a suitable system.img, but hopefully someone else can.

You have a suitable system.img for the TB-X704V? Can you send me a link to this file please?
 
  • Like
Reactions: StuBeers

michaave

Senior Member
Dec 27, 2010
52
9
Download the factory image for your tablet from the Russian Lenovo forum (lenovo-forums.ru) . In there you will find a fragmented system image. You have to puzzle it together with a script according to XML file in the Image directory. If you wanna flash via fastboot you will have to convert it with img2simg to sparse format. You can also use dd command line TWRP with the raw image file. If you tell me your exact model number I can also upload what you need.

What do you use to puzzle it together? I've installed img2simg and I have an array of system images with number suffixes, as well as the XML with the offset values. I imagine I have to concatenate them somehow before using img2simg...?

---------- Post added at 06:39 PM ---------- Previous post was at 06:38 PM ----------

Ok folks, here is a link to my FULL stock ROM for the Lenovo TB-X704V .
I'll leave it live for a week or so.

https://mega.nz/#!rLJBmIZb!axE0fxI3KSOvzUmyJ_XMmMlPEKfnNy6OXLG07Pz8mUY

Ah! You're wonderful. Thank you very much sir!
 
Last edited:
  • Like
Reactions: StuBeers

coolbeans2016

Senior Member
Feb 9, 2015
630
162
33
Atlanta

michaave

Senior Member
Dec 27, 2010
52
9
Download the factory image for your tablet from the Russian Lenovo forum (lenovo-forums.ru) . In there you will find a fragmented system image. You have to puzzle it together with a script according to XML file in the Image directory. If you wanna flash via fastboot you will have to convert it with img2simg to sparse format. You can also use dd command line TWRP with the raw image file. If you tell me your exact model number I can also upload what you need.

OK I think I've got it. I used packsparseimg from another post to obtain system.raw, and used img2simg to get from system.raw to system.img for fastboot flashing... I think. Anything else I should know before fastboot flashing this thing?
 

Dr4In

Senior Member
Sep 1, 2012
110
9
Hello i seriously need the latest firmware for Lenovo TB-8504X LTE for TWRP flashable, i managed to flash stock recovery but the OTA updates just fails! Please help me how do i update it to the latest version via TWRP?

My current version is TB-8504X_S000037_170910_ROW and i need TB-8504X_S000037_170910_ROW_TO_TB-8504X_S000057_180912_ROW
 

jsgraphicart

Senior Member
Nov 25, 2011
6,295
1,884
OnePlus 7T
Google Pixel 7 Pro
So what do people think are the odds of getting an updated TWRP for Oreo or even another update from Lenovo? I'm feeling antsy about rooting this device. I may just go ahead and do it. If anything goes wrong in the future, I can always just factory reset with the stock firmware and MiFlash, right? Or maybe I will keep it on Nougat so I have a fully working TWRP. Any thoughts/recommendations?
 
Last edited:

swieder711

Senior Member
So what do people think are the odds of getting an updated TWRP for Oreo or even another update from Lenovo? I'm feeling antsy about rooting this device. I may just go ahead and do it. If anything goes wrong in the future, I can always just factory reset with the stock firmware and MiFlash, right? Or maybe I will keep it on Nougat so I have a fully working TWRP. Any thoughts/recommendations?
Im staying on Nougat. It's solid and stable and works with TWRP.

If a working version of TWRP came out for Oreo than I might upgrade. I had trouble with Magisk and Root when I tried to upgrade months ago.
 

Strephon Alkhalikoi

Senior Member
Aug 3, 2010
7,479
3,462
Vulcan
Samsung Galaxy S4
Nexus 6
Im staying on Nougat. It's solid and stable and works with TWRP.

If a working version of TWRP came out for Oreo than I might upgrade. I had trouble with Magisk and Root when I tried to upgrade months ago.
In my case, upgrading to Android 8 caused problems with my modded copy of ES File Explorer not remaining installed after a reboot, and not even a factory reset while on Android 8 has been able as of yet to fix it. Meaning I did something wrong; possibly adaptable storage is the culprit. Plus a tablet is low priority to me compared to my Pixel 2 XL and other phones.

I do have to try again at some point. I missed some files @LumenReaper needed.
 

jsgraphicart

Senior Member
Nov 25, 2011
6,295
1,884
OnePlus 7T
Google Pixel 7 Pro
Im staying on Nougat. It's solid and stable and works with TWRP.

If a working version of TWRP came out for Oreo than I might upgrade. I had trouble with Magisk and Root when I tried to upgrade months ago.

I may go this route. I do miss my root apps and stuff like Xposed Framework. When I got this tablet I wasn't on Nougat for too long but it didn't really seem all that different from what Oreo is on this tablet. I've just never done any factory resets with the factory images on this yet. Kind of hesitant since there's not very much support here. But do you get the update notification staying on nougat? Do you have to do something special to block it?
 

fn_noobee

Member
Mar 5, 2012
16
8
Ok folks, here is a link to my FULL stock ROM for the Lenovo TB-X704V .
I'll leave it live for a week or so.

https://mega.nz/#!rLJBmIZb!axE0fxI3KSOvzUmyJ_XMmMlPEKfnNy6OXLG07Pz8mUY

Ok. I just want to thank you and tell you you're a golden god amongst mere mortals. I installed this update on my TB-X704V to test it and something had gotten borked in my TWRP backup (I think it may have been that I did the backup on a Samsung external micro SD card, I know, I know it's a mistake) and I was soft-bricked. Thanks to you, I was able to create a working boot.img and system.img to flash via fastboot after flashing my stock recovery from TWRP. It took a bit of work turning the files (which I think were in QFIL tool format) into a system.img using a couple programs and some terminal commands, I finally got it! I may upload my unpacked recovery.img, boot.img and system.img files for anyone else who might need it. FYI, no need to convert the system.img file into more manageable sparse chunks as fastboot adb will do it automatically into 500ish MB chunks (7 total IIRC). Thanks again!
 
Last edited:
  • Like
Reactions: Sparkrite

fn_noobee

Member
Mar 5, 2012
16
8
So, I flashed the boot.img, recovery.img and system.img from needrom (factory images for 8.1) and almost everything ist dandy - except that TWRP cannot decrypt the partitions. Which unfortunately means I cannot root the device.

I'd really like to keep /data, if possible.

adb sideload does not work, as soon as I start it, adb doesn't see any device.

Any chance to gain root without formatting /data?

Ok, when you say you flashed factory image for 8.1 do you mean the one that came out for the TB-X704A (WIFI only) variant? Also, what variant are you using? I have the TB-X704V (US WIFI & LTE) variant. When you say everything's working, does that mean fingerprint scanner or it just boots with no major issues? Sorry for all the questions but I'd like to update. Nougat has most of the features I *NEED* but it's egregious that the flagship variant of this tablet is riding on December 17 security updates. Lenovo support seems to be of no use from what I've researched.
 

tgm28

Senior Member
Dec 20, 2010
207
31
Łódź
Soo... TB-8504X Oreo with TWRP which can mount /data is only a dream? :(
Also it is impossible to install Remounting module for magisk...
 

Strephon Alkhalikoi

Senior Member
Aug 3, 2010
7,479
3,462
Vulcan
Samsung Galaxy S4
Nexus 6
Soo... TB-8504X Oreo with TWRP which can mount /data is only a dream? :(
Also it is impossible to install Remounting module for magisk...
I stopped bothering with the remount module some time ago. In fact I keep my /system partition read only these days, but when the module stopped working I ran the command within the module using the TWRP terminal.

As to a working TWRP for Android 8.1, if you're running Android 8.1, run the following command and send @LumenReaper the files.

Code:
adb pull /system/vendor/lib64
 
  • Like
Reactions: tgm28

tgm28

Senior Member
Dec 20, 2010
207
31
Łódź
I stopped bothering with the remount module some time ago. In fact I keep my /system partition read only these days, but when the module stopped working I ran the command within the module using the TWRP terminal.

As to a working TWRP for Android 8.1, if you're running Android 8.1, run the following command and send @LumenReaper the files.

Code:
adb pull /system/vendor/lib64

Dump only /system/vendor/lib64? or maybe whole /system? What else is needed from the newest OTA update for TB-8504X?
 

Top Liked Posts

  • There are no posts matching your filters.
  • 66
    TWRP is an open source, community project. TWRP development is done by roughly 4 people at this point. We also have a large support community with many people who are willing to answer questions and help people with their devices either through our IRC channel or on forums like xda-developers.

    Team Win was originally formed to work on porting WiMAX to CM7 for the HTC EVO 4G. After our work on the EVO 4G we wanted to work on a project that would work on more devices than just the EVO 4G and we settled on working on a recovery. Today TWRP is the leading custom recovery for Android phones.

    A custom recovery is used for installing custom software on your device. This custom software can include smaller modifications like rooting your device or even replacing the firmware of the device with a completely custom "ROM" like OmniROM

    WARNING!!! Be careful what you do here. One mistake and the device is soft-bricked. I take no responsibility for bricked devices, lost warranty or even OTAs not working!! Booting and/or flashing files from this post is on your own risk.

    Requirements
    • Unlocked bootloader
    • Lenovo Tab 4 Plus with and without LTE and both 8 and 10 inch versions (TB-X704L/F, TB-8704X/F) are supported

    Known Issues
    • WARNING! Our device uses dm-verity (verified boot). The system partition should remain read-only. Otherwise a bootloop will occur. You can flash SuperSU to resolve this but OTA's are no longer possible! You have to restore a factory image or clean system backup to receive OTAs

    Download

    Instructions
    1. Install fastboot and adb on your PC, e.g. from here
    2. Enable developer options and in there select to unlock your bootloader by enabling OEM unlock and enable USB debugging
    3. Connect your PC to your tablet and run
      Code:
      adb reboot bootloader
      using adb on command line. The tablet will reboot into bootloader mode where you will only see the Lenovo logo. Now you use
      Code:
      fastboot oem unlock-go
      to unlock. This will factory reset your device
    4. Setup the tablet again and reboot again to the bootloader
    5. Then run
      Code:
      fastboot boot twrp-3.2.3-0-<your-filename>.img
      to temporarily boot into TWRP. You can also flash if you are sure ;)
    6. Select to keep system read only when TWRP starts to avoid modification which will make OTAs impossible
    7. Backup at least system and boot partitions. Choose "System Image" for the system partition backup. Keep this backup for OTA updates.
    8. Optionally flash SuperSU or Magisk in TWRP which should install system less. Keep OEM unlock enabled if you flash or modify anything

    Writable System Partition
    Some mods and root apps require write access to the system partition. By default the system partition is read-only to prevent any modification. Please note that if your system partition is modified in any way it needs to be restored to its original state before a system update (OTA) can be applied.

    • @dywersant has created a Magisk module here to achieve write access
    • @KreAch3R has updated the Magisk module to the latest version here



    System Updates (OTA)
    In order to successfully apply Lenovo system updates after root you have to restore the original boot, recovery (if you flashed TWRP) and system partitions from your current installed version (e.g. S000037) for your variant of the tablet. This will NOT delete your apps and data but will unroot. Note that OTAs are block based and always check the contents of most of the partitions. This means that all of these partitions (except your data) have to be original and have to be on the exact same version (e.g. S000037) for the update to succeed.

    Credits
    @wonderfulme - for testing the 8" version
    @Teddy01 - for testing the 10" version
    @3m1k - for providing the 8" Verizon version
    TeamWin


    Source
    TWRP Manifest: https://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni/tree/twrp-7.1
    Device Tree (TB-8704X): https://github.com/Matshias/twrp_android_device_tb_8704x/tree/android-7.1
    Device Tree (TB-8704V): https://github.com/3m1k/twrp_android_device_tb_8704v
    Device Tree (TB-X704L): https://github.com/Matshias/twrp_android_device_tb_x704l/tree/android-7.1
    Device Tree (TB-8504X): https://github.com/Matshias/twrp_android_device_tb_8504x/tree/android-7.1
    Device Tree (TB-X304L): https://github.com/Matshias/twrp_android_device_tb_x304l/tree/android-7.1


    Changelog
    v3:
    • Update to TWRP 3.2.3-0
    v2:
    • Update to TWRP 3.2.1-0
    v1:
    • Initial Release
    12
    I am happy to make probably the best announcement since we got TWRP: My X704F is running LineageOS 14.1. While some things are already working, two things keep me from releasing it now: Wifi and Usb don't work yet. Once I have solved these problems, I will create my own thread for it. So be patient ;)
    11
    Can someone please help I soft bricked my device And I'm unable to fastboot new rom QFIL is keep saying SAHARA FAILED can someone help me?

    You need to have install both the qualcomm drivers and the Lenovo drivers, both installed via executables in the drivers section in the russian .7z download. You need to be in a mode of disable driver signature checking, search how to do that for your OS.

    When you get that message, hit volume up key when it says that then hit download again and it keeps going.

    I spent a day trying to unbrick, I kept trying and hitting walls and trial+error and eventually succeeded, this is what worked for me, this is not necessarily the best approach and some steps may not be required, but it at least worked for me so I offer it.

    Download the Russian forum ROM for your device e.g. mine was the Lenovo Tab 4 8 Plus. If you didn't flash, only boot, TWRP, you can use the stock recovery. If you're not sure what is your model then have your tablet powered off and press and hold the volume up key and press the power button til you feel a vibration then let go both buttons. The recovery will then tell you the model. Mine was TB-8704F so my link is here

    http://lenovo-forums.ru/topic/24137-lenovo-tab4-a8-plus-proshivka-tb-8704f_s000024_170706_row_qfil/

    Change do your own model. Go up the forum and down to your model.

    You need a 7zip extractor.

    When you extract you need a password which is "lenovo-forums.ru"

    Inside the unzip is images, drivers, tools. We're using the images and the drivers, but ignoring the tools

    Go to drivers and run the Lenovo and the Qualcomm executables.

    Inside the unzip the tools has QFIL.exe but it doesn't work. Download the QFIL 1.0.02 from here

    https://androiddatahost.com/jj9ye

    Boot into a mode without device driver signing. I used Windows 7 32bit so I reboot and hit F8 as it came out of BIOS and selected disable driver sig. Once booted all the steps below are done.


    Run the qfil exec in the above.

    qf_4.png.f5797926619c16ad6a4b9f1a9b9032c7.png


    The top most browse point it to the images folder and it will show one file, select it. Then load XML select browse and point it to the image folder and it will select a file and then it will select another file "patch".

    Then unplug your tablet and turn it off (press hold and ensure screen is black for many seconds).

    Then this is a tricky part, took me many attempts. Press and hold the volume up key and plug in the USB-C cable and then let go of the volume up key. The QFIL tool should show a qualcomm port as being used. If you don't see anything active saying qualcomm in port then unplug table and repeat the vol up and power. You can get other modes like Lenovo diag mode, keep trying til it says qualcomm.

    Then hit the lowest download button. If it says error hit the table volume up key and press download again.

    If it is working you'll see a movement left to right above the text log status section. If it is working you'll see a "reset" message and the table shows activity it is doing something there is a moving bar on the tablet. Keep repeating it takes 2 or 3 time phases where the tablet stops showing progress so then hit the download button. Eventually you get a normal boot and you're unbricked.
    10
    Twrp 3.4.0-0 tb-8704

    Hi Everyone,

    As an experiment I wanted to see if I could compile TWRP for my TB-8704X so I started out using Matshias sources which worked fine. My next step was to see if updating the kernel would with the issue of not being able to see the internal storage with stock Android 8.1 so I then forked Matshias's Device Tree and updated kernel from 8704X_S001025_190606 and ran another compile test. With my build I'm now able to select Internal Storage with 8.1 so I believe the updated kernel fixes the issue where TWRP can't see and wipe partitions.

    Credits to Matshias for providing his device tree
    Thanks to plutothot for helping test this on the TB-8704F

    Updated to TWRP 3.4.0-0

    Sources
    TWRP Manifest: https://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni/tree/twrp-7.1
    Device Tree (TB-8704X): https://github.com/lancebukkake/twrp_device_lenovo_tb_8704/tree/android-7.1
    Device Tree (TB-8704F): https://github.com/lancebukkake/twrp_device_lenovo_tb_8704/tree/8704F
    Device Tree (TB-8704V): https://github.com/lancebukkake/twrp_device_lenovo_tb_8704v

    Downloads (TB-8704X and TB-8704F are separate so make sure you download the correct img for your device)
    Github

    Download for TB-8704V (shoutout to xsacx for testing it out)
    Github

    Please click Thanks if I helped you
    10
    I was having trouble flashing magisk-remount.zip from @dywersant on Magisk v17.1, so I updated the module on top of the 17 template. Find the file attached, I tried it and it flashes correctly and provides RW access.
    @matshias, you can update OP with a link to this post as well for users having the same problem.