[Q] Can't extract tar - Android Q&A, Help & Troubleshooting

I have been at this for hours, but to no avail. I have been trying to root my GS2 with CF Root, but I can not get the tar file, instead, I see a zImage file. I am not extracting the tar to get the zImage. The zImage is what is there originally. I have tried multiple sources of CF Root, but get the same problem.
Edit: Figured it out, nvm

I have no clue about CF root and the GS2, but I suspect it could be a few things: 1) your OS automatically untars whatever file you download. Good luck getting control back from your OS. 2) the zimage might actually be tar file. I'm not familiar with kernel formats, but I though they were sometimes compressed. It might indeed be a tar file, but it doesn't have any sort of tar.gz or bz.tar extention to advertise to the world.
Again, I'm not even sure what device you are talking about or what root exploit you are using. I did a quick look at the devices page and they are a lot of Sammy's with galaxy in the name.

Related

[Q] Extracts zImage instead of .tar

I'm new to rooting,
Android Version= 2.3.3
Baseband Version= I9100NEKF2
Kernel version= 2.6.35.7-I9100XWKF4-CL280512
Build Number= GINGERBREAD.XWKF4
Firstly am i looking for KF2 or KF4?
I downloaded the zip file for KF2 from chainfire afew posts down where he writes "yet more downloads" but i get a zImage file being extracted instead of the .tar file i expected.
what am I doing wrong? where is the right root kernel for me? I want to use Chainfire's as he provides everything in one.
Thanks.
You need to know your PDA version, not baseband. *#1234# in keypad and see it. Then download the same XXX.zip from CF thread. If you download that .zip file then you will get .tar after extraction, then to get the zImage you have to extract that .tar file again.
Regards.
ithehappy said:
You need to know your PDA version, not baseband. *#1234# in keypad and see it. Then download the same XXX.zip from CF thread. If you download that .zip file then you will get .tar after extraction, then to get the zImage you have to extract that .tar file again.
Regards.
Click to expand...
Click to collapse
Thnks, my PDA is XWKF4 so I just downloaded CF-Root-SGS2_ZS_OZS_KF4-v4.0-CWM4. The same thing happens when I extract though. the zImage is for when you already have root to flash from SDcard isnt it? I havent got root.
Smousers said:
Thnks, my PDA is XWKF4 so I just downloaded CF-Root-SGS2_ZS_OZS_KF4-v4.0-CWM4. The same thing happens when I extract though. the zImage is for when you already have root to flash from SDcard isnt it? I havent got root.
Click to expand...
Click to collapse
That's the right file you downloaded. I just checked for you again, and I do get .tar file if I extract that downloaded zip with 7Zip/WinRar. Don't know why aren't you getting it!!!
ithehappy said:
That's the right file you downloaded. I just checked for you again, and I do get .tar file if I extract that downloaded zip with 7Zip/WinRar. Don;t know why aren't you getting it!!!
Click to expand...
Click to collapse
I just tried it with 7zip aswell. I dont understand this
Is there anything else you can recommend?
Cheers
Are you downloading a kernel instead of the cwm and root file .
As said 6mb file zipped unzip that file open the folder and inside is a tar file . Flash the tar file do not open it .
You are opening the tar file is your problem .
jje
What's the size of the zip you downloaded, is it ~6 MB?
Make sure you are downloading this one,
http://forum.xda-developers.com/attachment.php?attachmentid=630778&d=1308560606
Thanks guys. Got Root now, what do i do with the superuser/CWM apps, also installed ROm manager and titanium backup but dont want to mess about before i know exactly what im doing.
I know i want to freeze/remove all the bull**** i dont need, what else can i do with root now and how?

[Q] Startup problem

I just flashed UHLB2 from Intratech's thread.
My phone downloaded the file fine, and Odin had a green 'PASS!' in the top left corner. I think it installed OK as well as I saw the word 'Sucessfully (something)' just before it rebooted.
But now trying to turn it on, the phone is in a perpetual state of starting up. It just replays the starting animation over and over again.
What is wrong?
Also, I noticed the file I downloaded was ~286MB, as opposed to ~333MB in the file from sammobile. Intratech's file was .7zip, and sammobile's was just .zip.
aaronsclee said:
I just flashed UHLB2 from Intratech's thread.
My phone downloaded the file fine, and Odin had a green 'PASS!' in the top left corner. I think it installed OK as well as I saw the word 'Sucessfully (something)' just before it rebooted.
But now trying to turn it on, the phone is in a perpetual state of starting up. It just replays the starting animation over and over again.
What is wrong?
Also, I noticed the file I downloaded was ~286MB, as opposed to ~333MB in the file from sammobile. Intratech's file was .7zip, and sammobile's was just .zip.
Click to expand...
Click to collapse
I'm just speculating... I don't think 7zip files are compatible with Odin. That's probably your problem. The 7zip file from Intratech will contain compatible zip files. You can extract it using the program 7zip(freeware) which I'd highly recommend for general use anyway.
ibm9001 said:
I'm just speculating... I don't think 7zip files are compatible with Odin. That's probably your problem. The 7zip file from Intratech will contain compatible zip files. You can extract it using the program 7zip(freeware) which I'd highly recommend for general use anyway.
Click to expand...
Click to collapse
Yeah I do unzip the files with 7zip, after which it is a .md5 file.
And I've flashed many times before using that method so I don't think it's that. Thanks anyway.
.7zip file is not supported by Odin.
You need to extract that .7zip file, you will get .zip file that supported by Odin.
I think the downloaded file you used is incomplete. Most of the file sizes downloaded are around 350MB or higher. Recommend you re-download the file again or even an older release and re-flash the phone.
aaronsclee said:
Yeah I do unzip the files with 7zip, after which it is a .md5 file.
And I've flashed many times before using that method so I don't think it's that. Thanks anyway.
Click to expand...
Click to collapse
Just rename .md5 to .zip file.
JasMiL said:
Just rename .md5 to .zip file.
Click to expand...
Click to collapse
No. Odin can flash .md5 so you should leave it. md5 files actually help because Odin can check the md5 hash and stop if the file is corrupt/incomplete.
But you have to extract it from 7z because it can't flash that.
Sounds like you've got an incomplete file if the file size is less than what you'd expect. Re-download and try flash again.
Also, to those saying extract the 7zip file; I'm pretty sure OP said he had done that before flashing and had used the .md5 file. Unless I'm reading his posts wrong, in which case, yes unzip the 7zip file and flash the .md5.
BJ van Beethoven said:
Sounds like you've got an incomplete file if the file size is less than what you'd expect. Re-download and try flash again.
Click to expand...
Click to collapse
Hm..
I've downloaded and flashed again, but I have the same problem. The new file was bigger than the original one, so the original was probably incomplete. But the file has been at about 274MB for about 6 hours now on Intratech's post. I guess I'll just have to stick to LA4 for now then.

Packaging an Odin ROM for size and consistancy

Hey guys.. Odin3 version3 and higher has gz support. I've been working with this for a bit and tonight I found that Odin will accept tar.md5.gz files. This is important for GNote2 users as the stock ROM is 1.2Gigs! You can get an extra 10-40% compression and 100% gaurantee that the files arrive to your users computer in the condition that you packaged them using this method. I have not found a guide on using the gz format so I thought I would write one up.
You will need:
A Linux computer
Your rom (we will call it MyROM)
How to package for Odin on Windows
I will cover packing into a single file, adding an MD5, and compressing the file down. For the purposes of this, we are working with "MyROM". You will want to call your ROM whatever you like. Just make sure to add version information to the file name so users don't get confused. Also note, the name MUST be consistent throughout the process. If you change the name, Odin can fail.
Another good tip is to put a model number in the name so there is no confusion as to what device your Odin package goes to. Several users, myself included, have 20+ Odin packages on their computer.
So first you want to turn the ROM into a single tar file and then make sure changes are written to the disk.
Code:
tar -H ustar -c boot.img hidden.img modem.bin param.bin recovery.img system.img tz.img sboot.bin>./MyROM.tar;sync;
Next we want to add an MD5 to the file so Odin can check its consistancy.
Code:
md5sum MyROM.tar >> MyROM.tar;
Now we will change it into a tar.md5 file so Odin knows it has an MD5 attached to it.
Code:
mv MyROM.tar MyROM.tar.md5; sync;
Finally we will compress it with GZip. GZip is the only compression method supported by Odin.
Code:
gzip MyROM.tar.md5 -c -v > MyROM.tar.md5.gz;
You will now have a file called MyROM.tar.md5.gz.
Conclusion
The first time the file is flashed, Odin will uncompress it into MyROM.tar.md5, then check its consistancy, then flash the file. Using this method you will be transferring the smallest file possible and adding integrity checks.
notes
Note to Verizon GNote2 users: Stay away from using Odin after IROM unlock as flashing a package intended for another device will perma-lock your device into another carrier's bootloaders. Especially stay away from GS3 as the displays are not compatible.
good ****! this is def useful
Awesome news! Any test results with the older versions? If not one click solutions may not benefit.. but servers and users will by cutting the downloads even more!
Sent from my SPH-L900 using Tapatalk 2
Windows OS
How can I do it on a Windows computer?
MAQ7 said:
How can I do it on a Windows computer?
Click to expand...
Click to collapse
Install Virtual Box and a Linux distribution. I haven't seen any tools for Windows that work properly to make tar archives that work with Odin.
cygwin.
Mine all work
imnuts said:
Install Virtual Box and a Linux distribution. I haven't seen any tools for Windows that work properly to make tar archives that work with Odin.
Click to expand...
Click to collapse
adrynalyne said:
cygwin.
Mine all work
Click to expand...
Click to collapse
I managed to make tar on Windows using cygwin :good:.
Thank you
Interesting adam, I always compressed the whole odin package into a rar file (same effect but one step extra). Also I made an article about odin a while ago:
http://broodplank.net/?p=496
Btw, did you know that you can put cwm backups (ext4.tar) inside an odin package? It's the first odin image I ever saw, filled with a CWM backup, and yes it works XD
But it's not an 1:1 copy of course, Also I wonder how nandroid backups actually store their permissions, I mean dd is a 1:1 dump, which is logical, cwm has the updater-script. but the nandroid backups which are actually just tar files packed with the contents, how do they store it?
Last thing, Odin packages can be a last resort fix, believe me, many users reported that flashing my rom broodROM_RC5.tar.md5 (which contains about 13 files, you can imagine how many partitions it includes) fixed their phone when nothing else worked.
So thank you Samsung for leaking your tool, A world with Samsung Kies only would be a very sad "softbricky" world
broodplank1337 said:
But it's not an 1:1 copy of course, Also I wonder how nandroid backups actually store their permissions, I mean dd is a 1:1 dump, which is logical, cwm has the updater-script. but the nandroid backups which are actually just tar files packed with the contents, how do they store it?
Click to expand...
Click to collapse
TAR files preserve file permissions.
I still like making a 7z out of the final .tar.md5 file.
The info in OP is great to know as it does save a step for the end user but I'd rather them take a couple steps to vet out the incompetent ones. Could prevent a brick
mrRobinson said:
I still like making a 7z out of the final .tar.md5 file.
The info in OP is great to know as it does save a step for the end user but I'd rather them take a couple steps to vet out the incompetent ones. Could prevent a brick
Click to expand...
Click to collapse
Only on the Verizon Galaxy Note. All others are IROM locked. The IROM lock prevents flashing of an improper SBOOT. An unlocked VZWGNote 2 can flash any SBOOT.
Other than this specific case, adding third party tools other than ZIP compression means your user must download special tools.
Extra files?
If I were to pack an extra README.txt file into the tar before prepping it for Odin, would Odin then ignore it during the flash? Obviously there's no entry for what to do with an extraneous text file in the pit, so hopefully Odin would just disregard it.
I happened to find out today that heimdall has support for "Heimdall Firmware Packages." You can read and write them from the heimdall frontend (the 1.3 FE binary is forward compatible with my source built 1.4 heimdall). What's interesting, is that the format is almost identical to odin's format. It is still packaged in a tar file, and it contains the same system.img, boot.bin, recovery.bin etc. files you'd find in the Odin tar. By default it's format is Package.tar.gz. The only significant difference is the addition of a firmware.xml file that identifies the proper partition for each image file, as well as the target platform, the author, and other details like that.
So I got curious. I took a Package.tar.gz file generated by heimdall, and repackaged it as a Package.tar.MD5.gz file. Heimdall has no problem reading this! So the upshot is, Odin now handles the .gz, so as long as Odin isn't bothered by an extra firmware.xml file inside the tar, the same format would be compatible with either tool.
PS> Don't flame me about flash counters or bricked phones. I do understand that Odin/Heimdall are only particularly relevant for returning a phone to stock, but that's still a very important functionality and it would be great to have a unified format.

[Q] Files in a nandroid back up

Ive done a backup on my phone and created a flashable zip (update.zip)
Now im playing around with dsixda's kitchen and trying to extract the system.tar, however it fails most likely due to fact the the system.tar is empty
the files in the archive are as follows
Meta-inf -- <folder>
boot.img -- <8192KB>
image-edify -- <1KB>
system.ext4.tar -- <0KB>
system.ext4.tar.a -- <976,563KB>
system.ext4.tar.b -- <68,151KB>
By the looks of things it has split the system.ext4.tar because its over a gig
How can i compile this into one file or one image so that the kitchen can read it, I'm on a windows 7 PC but i can run linux in a vbox if necessary.
Thanks
Try using the zip file in your input folder.
dsixda's kitchen should be able to extract from it
mikep99 said:
Try using the zip file in your input folder.
dsixda's kitchen should be able to extract from it
Click to expand...
Click to collapse
Already tried, it comes back saying its deleting the part a and part b files and then says the system.ext4.tar isnt a valid archive.
Is it a stock rom?
If so, download the firmware from sammobile and put the tar.md5 file into your input folder (after removing the .md5 suffix).
Thats worked for me in the past....
It is stock, but i have removed the bloatware, installed a few mods, i was hoping to use this particular one really as a base. Ive already played around with fully stock and i kind of broke the whole thing
I'm not too sure then unless theres some tool you can find to merge the 3 tar files into 1...
Never had to do it so I'm unable to suggest anything I'm afraid.

[Q] Need help to repack a .tar file from adb backup on windows

Good evening,
I'd like to apologise first for my english, as it may not be perfect.
I'm trying to backup some app with adb backup (giving me a .ab file), transform the .ab file to a .tar file, extract the .tar file and change some files in it, then repack the .tar file (this is my problem) , then restore it to the phone.
I'm using windows, and my phone is not rooted.
I managed to get the app with adb backup, managed to transform the .ab file into a .tar file, managed to extract the .tar file and change some files in it, but i can't find how to repack the .tar file. This is the main problem, as i think once the .tar file is well repacked, the restoration with adb will be easy. I found some topics about it, but seems that repacking a .tar file is not that easy as I need to get the header from the .ab file and recreate the .tar file with it. All the solutions I found are for linux, and I'm really not quite good with it, so any solution with Windows would be awesome.
Hope anyone can help me,
Thanks

Categories

Resources