Extracting/Browsing a TWRP Backup?

Search This thread

heyjoe66

Senior Member
Mar 15, 2007
566
173
just tried and this does not work, so I assume you never tried it with TWRP backup files, cygwin does work

Quite the contrary, I just did. Assuming that TWRP backup is a multi-volume tar packed additionally with gzip, I've unpacked all parts feom gzip by 7zip, then extracted resultin multi-volume tar by that Windows tar binary.

Of course , there might be a problem with symlinks supported by tar, but unsupported by windows file systems.
 
  • Like
Reactions: carl1961

diedmatrix

Member
Aug 27, 2016
38
5
Hi everyone,
please i need your help i am ****ed up :(

Display was broken or in the process of dieing really quick. So i copied all folders via Windows explorer as long i could do something with the phone.

I dont now why but the folder where the app colornote makes regular backups is empty??? it is/was located (via windows explorer) under internal storage\data\colornote\backup

I do have an older twrp backup left here, but i cant find the missing folder/files via 7-zip or twrp browser on an other phone :crying: The folder structure and files looks different, not like in the root of internal storage via windows explorer, why is that?

I think this are the files to look at, arent they? I tried them because they are the biggest ones, the rest is just a few kb...

data.ext4.win000
data.ext4.win001
system.ext4

These files are so important for me, please help me! :crying: :(
 

ciko84xp

Senior Member
Jul 16, 2008
144
4
Rossano Calabro
Hi guys.. Does someone knows why "tar -xvzf xxx.tar.gz" don't work with "boot.emmc.win"? (On Ubuntu 16.10)
With "xxx.ext4.win" files works properly.
Some suggestion to do same thing on "xxx.emmc.win" files on Ubuntu?
Thanx!
 

mjd4one

Member
Feb 25, 2017
15
0
Tabriz
plz help

Thanks @Optikmike for CYGWIN tip

here's what I did..

CYGWIN Unpacking TWRP Backup Files

rename:
data.ext4.win to data.ext4.win.tar
system.ext4.win000 system.ext4.win000.tar
system.ext4.win001 to system.ext4.win001.tar

Make a directory in your CYGWIN Home [Username]folder
Example: untar

Use Windows File Explorer go to your CYGWING Home
C:\cygwin\home\carl (your user name will be here)
make any folder you choose
Example:
C:\cygwin\home\carl\untar
and C:\cygwin\home\carl\untar\data ( for data files)

put your renamed data files in a folder named data
C:\cygwin\home\carl\untar\data (this is to keep files separate when unpacked)

While in Explorer put your renamed system files in untar folder

start CYGWIN ( Use the Cygwin Terminal and then you can copy and paste these commands)
cd to untar folder
example:
cd\untar
do these commands one at a time, it will extract to a folder named system

tar -xvf system.ext4.win000.tar
tar -xvf system.ext4.win001.tar

cd to data

do this command
tar -xvf data.ext4.win.tar

all your data files will extract

how repack???
 

carl1961

Senior Member
Dec 5, 2010
7,521
6,201
Tickfaw
I would make a installer zip, install to your phone and let TWRP back it up, or if your time is plenty the head to TWRP thread and see how TWRP packs it, it would be around the place where they talk about compiling. another choice maybe is to search the tar function and try to do that in CYGWIN command screen . I do not have much time to invest as I am rather busy with work and home projects and do not do any phone work any more

CYGWIN console

carl@carl-PC ~/untar
$ tar
tar: You must specify one of the '-Acdtrux', '--delete' or '--test-label' options
Try 'tar --help' or 'tar --usage' for more information.
 
Last edited:

Deelight2

Member
May 15, 2009
12
0
Hi guys ;)
after updating the htc screenlock app via playstore today my phone won't boot into sense. I just see the wallpaperscreen going on and off and i can't do anything.
I have a twrp backup, which is including the faulty app. I renamed the files extension to .zip and can extract them.

My question is... can i remove the app from the back up and just restore the backup (md5 comes into mind...) or will i have to install fresh and copy all the files manually to the phone?

Any suggestions?
 

lovemytab

Member
Jul 20, 2017
19
8
D.C. Area
Thanks @carl1961 Worked!

Thanks @Optikmike for CYGWIN tip

here's what I did..

CYGWIN Unpacking TWRP Backup Files

rename:
data.ext4.win to data.ext4.win.tar
system.ext4.win000 system.ext4.win000.tar
system.ext4.win001 to system.ext4.win001.tar

Make a directory in your CYGWIN Home [Username]folder
Example: untar

Use Windows File Explorer go to your CYGWING Home
C:\cygwin\home\carl (your user name will be here)
make any folder you choose
Example:
C:\cygwin\home\carl\untar
and C:\cygwin\home\carl\untar\data ( for data files)

put your renamed data files in a folder named data
C:\cygwin\home\carl\untar\data (this is to keep files separate when unpacked)

While in Explorer put your renamed system files in untar folder

start CYGWIN ( Use the Cygwin Terminal and then you can copy and paste these commands)
cd to untar folder
example:
cd\untar
do these commands one at a time, it will extract to a folder named system

tar -xvf system.ext4.win000.tar
tar -xvf system.ext4.win001.tar

cd to data

do this command
tar -xvf data.ext4.win.tar

all your data files will extract


I followed these instructions and it worked. I had two data files instead of one though. The second data file ended in win001, so I had an extra step to do, which was to extract the second data file using the same convention outlined for the other files.
 

DIGVIJAY24

New member
Oct 5, 2017
4
4
Thanks @Optikmike for CYGWIN tip

here's what I did..

CYGWIN Unpacking TWRP Backup Files

rename:
data.ext4.win to data.ext4.win.tar
system.ext4.win000 system.ext4.win000.tar
system.ext4.win001 to system.ext4.win001.tar

Make a directory in your CYGWIN Home [Username]folder
Example: untar

Use Windows File Explorer go to your CYGWING Home
C:\cygwin\home\carl (your user name will be here)
make any folder you choose
Example:
C:\cygwin\home\carl\untar
and C:\cygwin\home\carl\untar\data ( for data files)

put your renamed data files in a folder named data
C:\cygwin\home\carl\untar\data (this is to keep files separate when unpacked)

While in Explorer put your renamed system files in untar folder

start CYGWIN ( Use the Cygwin Terminal and then you can copy and paste these commands)
cd to untar folder
example:
cd\untar
do these commands one at a time, it will extract to a folder named system

tar -xvf system.ext4.win000.tar
tar -xvf system.ext4.win001.tar

cd to data

do this command
tar -xvf data.ext4.win.tar

all your data files will extract
I'm sure somebody is already aware of this;just sharing coz this awed me![emoji33]

You need to ..extract/restore individual data files from nandroid backup?

Restore data to an app when switching between ROMs or OS versions?

Well TWRP IS THE ONLY THING YOU NEED! And a PC of course.

Bless the Devs[emoji7][emoji28]

Forget Nan managers, tar.extractors & the insanely complex Bash terminal commands

1. Go to File manager on TWRP recovery, it can read the system data i.e. data/data/ file (while your other file managers can,only data files on SD or ext.SD)

2.Go to data/data and locate the data folder of the app you wish to extract; will be in the format 'com.app name'

3.Push 'Select folder' tab on the screen; it gives you option to COPY the file

4.Move up & paste the data/data file on your readable memmory: sd/ext.SD

And that's it!! Just connect to the PC & pull the file & there u have: your APP DATA FILE!

I was tired using zip extractors, changing file names & struggling with command prompts; then found this[emoji4]

Hope it helps[emoji106]

Sent from my GT-N5110 using Tapatalk
 

ali32768

Member
Jun 21, 2016
32
2
So, I just flashed CleanROM 4.5. Everything went smoothly, except I've lost all my sms/mms messages from both Go SMS and the default Messaging app.

I have a TWRP backup here on the computer, as well as a TiBu backup of all user apps.

I can't seem to find the SMS database in the TiBu backup at all, and I can't figure out how to browse the TWRP backup to find it.

Nandroid Explorer doesn't read TWRP backups either...

Anyone have a solution?
The best software you can edit TWRP files is an old version of 7-zip.
Download Version 2016-10-04 from here:
For win32: https://www.7-zip.org/a/7z1604.exe
For win64: https://www.7-zip.org/a/7z1604-x64.exe
Ref: https://www.7-zip.org/download.html
Good luck.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 39
    CYGWIN Unpacking TWRP Backup Files

    Thanks @Optikmike for CYGWIN tip

    here's what I did..

    CYGWIN Unpacking TWRP Backup Files

    rename:
    data.ext4.win to data.ext4.win.tar
    system.ext4.win000 system.ext4.win000.tar
    system.ext4.win001 to system.ext4.win001.tar

    Make a directory in your CYGWIN Home [Username]folder
    Example: untar

    Use Windows File Explorer go to your CYGWING Home
    C:\cygwin\home\carl (your user name will be here)
    make any folder you choose
    Example:
    C:\cygwin\home\carl\untar
    and C:\cygwin\home\carl\untar\data ( for data files)

    put your renamed data files in a folder named data
    C:\cygwin\home\carl\untar\data (this is to keep files separate when unpacked)

    While in Explorer put your renamed system files in untar folder

    start CYGWIN ( Use the Cygwin Terminal and then you can copy and paste these commands)
    cd to untar folder
    example:
    cd\untar
    do these commands one at a time, it will extract to a folder named system

    tar -xvf system.ext4.win000.tar
    tar -xvf system.ext4.win001.tar

    cd to data

    do this command
    tar -xvf data.ext4.win.tar

    all your data files will extract
    20
    Sorry I'm not following this. I made a twrp backup using 2.5.0.0 and I got a bunch of .WIM files.
    7-Zip recognizes those and opens them to have a .ext4 file. However every ext browser and mounter (in windows) I've tried can't seem to browse them. I tried renaming them zip, but I'm guessing I'm doing something wrong.

    With old CWM releases, my backups were tars which were easily browsable.

    Am I missing something?

    Thanks!

    I know this is an old post, but it's the first Google result.

    What you want to do is rename the .wim file to .tar.gz, then extract the file (command line is tar -xvzf filename.tar.gz). If you look at the TWRP logs it indicates that it uses tar to create the archive file.
    5
    What are WIN files?

    Along with win and md5 files TWRP creates recovery.log file. If you look inside this file, you can see the full log of what TWRP has done. There you can notice that win file with the boot partition is in fact a result of the dd command, so that's a bit-to-bit copy of the boot partition, sometimes named as .img file.
    Other partition win files are tar files. If you used compression, you got .tar.gz files.
    So .win files are raw partition data, .tar, or .tar.gz files. See recovery.log
    4
    If you use compression in TWRP, just rename the .win to .tar.gz

    i.e data.ext4.win to data.ext4.tar.gz , then use tar -xvzf , extracts perfectly fine.
    I used this to extract my apps from a TWRP backup just now.
    3
    So, I just flashed CleanROM 4.5. Everything went smoothly, except I've lost all my sms/mms messages from both Go SMS and the default Messaging app.

    I have a TWRP backup here on the computer, as well as a TiBu backup of all user apps.

    I can't seem to find the SMS database in the TiBu backup at all, and I can't figure out how to browse the TWRP backup to find it.

    Nandroid Explorer doesn't read TWRP backups either...

    Anyone have a solution?

    Yep, it's fully possible. Just get the nandroid backup file, and make a copy and change the extension to .zip After that just unzip, and volia. A bit of searching (should be in the apps file, I forgot the details).

    Sent from my HTC One XL using xda premium