Hi guys, I could successfully unpacked and repacked system.img on 4.0.4 for my Galaxy S III by learning from xda, add root files, delete unnecessary system apps, etc, and using "tar -cvf ...." to make an tar pack to flash with ODIN, thx to all xda developpers.
But when I did this again on new GSIII 4.1.1 firmwares like DI2, My phone jammed in the 2nd screen, could someone help me?
Here is what I did on 4.1.1 firmwares in Ubutu, just like what I did on 4.0.4
1. unpack system.img from tar files
2. exchange system.img to system.img.ext4 in Ubutu
3. unpack system.img.ext4 with
Code:
mkdir systest; mount -o rw,loop system.img.ext4 systest
oh just forget the folder name.
4. modify the files in systest folder blablabla
5. repack system.img from systest folder using
Code:
sudo mkuserimg.sh -s systest systest-new.img ext4 temp 1536M
6. then make a new tar file to flash with recovery.img, hidden.img etc.
This tar file could be flashed with ODIN successfully, but like I said above, my phone didn't response in the 2nd screen with Samsung logos, I've wiped userdata in stock recovery but it didn't work.
Then I didn't modify any files, just unpack and repack system.img, flash it with ODIN, my phone remains the same
Could someone kindly to figure it out what I did wrong on new 4.1.1 firmwares? Is it about Samsung file format in 4.1.1?
Oh no replies until now...:crying:
I tested other 4.1.1 firmwares, unpack and repack system.img, then zip into new tar file, flash it, also stuck on the Samsung Logo with vibration
but it worked on all 4.0.4 firmwares
Related
I downloaded roms from samfirmware, after I unrar it, these are the file list
boot.img bootloader.bin cache.img hidden.img modem.bin recovery.img system.img
So How can I extract some files from system.img? I've tried unyaffs, but it segfaulted.
another stupid question is , how I can flash these files using odin? just select *.img in
pda and start?
yo
hi darren.hoo, i faced the same problem as yours and i realised that we should actually boot our tab to the downloading mode before we launch Odin3,pda.Turn on the usb debugging too(i dont know if this is necessary or not).Anyway happy flashing!
*Odin can only read .tar / .md5 extension ,you dont have to extract everything.
Kruel
Hi Darren.hoo,
To read the image files - It depends.
boot.img and recovery.img requires potentially a script to seperate the ramdisk and also the kernel. There are many good article on many wikis that explains which hex point is the seperator between the two.
system.img - I haven't really played with this too much as I don't usually create ROMS or anything - have you tried to mount it normally on a linux system? as if the system.img is just a ISO? (e.g. mount -o loop system.img /mnt). To rebuild this to become "flashable" is a different story (i believe you need the unayffs2 tools).
bootloader.bin - you'll need a hexeditor of some sort. This is as is a bin file (data file)
Not sure about the others. (cache - i'd assume you can recreate anyway and the modem i guess is another binary that requires a hexeditor.)
In terms of flashing the IMG - you need to tar up the *.img files, then do something like md5sum -t #name of tar# >> #name of tar#. Basically, it just appends the hash in md5 format to the tar. rename the file to something like *.tar.md5, and use that to flash as PDA.
Hope this helps.
Really great tips!
frankus0512 said:
system.img - I haven't really played with this too much as I don't usually create ROMS or anything - have you tried to mount it normally on a linux system? as if the system.img is just a ISO? (e.g. mount -o loop system.img /mnt). To rebuild this to become "flashable" is a different story (i believe you need the unayffs2 tools).
Click to expand...
Click to collapse
no luck with this:
debian:/home/darren/gtab/rom/EUR/P7500XWKG9# mount -oloop system.img /mnt
mount: you must specify the filesystem type
But from what I've got from searching xda a lot, maybe it's RFS filesystem?
frankus0512 said:
In terms of flashing the IMG - you need to tar up the *.img files, then do something like md5sum -t #name of tar# >> #name of tar#. Basically, it just appends the hash in md5 format to the tar. rename the file to something like *.tar.md5, and use that to flash as PDA.
Click to expand...
Click to collapse
this tip just really solved my problem.
I've got a tar.md5 file with three files in it: boot.img, system.img, recovery.img, but I don't
want to flash recovery.img coz I've already flashed CWM, yesterday I tried delete recovery.img from the tar ball and then flash it, then ODIN tells me that the files is invalid by
md5sum. I didn't know earlier that it records md5 checksum at the end of the tarball file.
It seems the OP got his answer but I'm having problems figuring out what to do.
I also have a system.img that i unzipped from a tar.md5 package by first editing the file extension to only say tar and then untarring it. When I try to mount the system.img with:
sudo mount -o loop system.img /media/systemimg
I get the filesystem type error:
mount: you must specify the filesystem type
Could someone who knows this please comment on how to mount the system.img to gain access to the files so I can explore system, that would be awesome.
span_01 said:
It seems the OP got his answer but I'm having problems figuring out what to do.
I also have a system.img that i unzipped from a tar.md5 package by first editing the file extension to only say tar and then untarring it. When I try to mount the system.img with:
sudo mount -o loop system.img /media/systemimg
I get the filesystem type error:
mount: you must specify the filesystem type
Could someone who knows this please comment on how to mount the system.img to gain access to the files so I can explore system, that would be awesome.
Click to expand...
Click to collapse
samsung firmwares should have -t rfs but you have to have a linux kernel on your dev machine that has a rfs modules
http://forum.xda-developers.com/showthread.php?t=1081239
darren.hoo said:
I downloaded roms from samfirmware, after I unrar it, these are the file list
boot.img bootloader.bin cache.img hidden.img modem.bin recovery.img system.img
So How can I extract some files from system.img? I've tried unyaffs, but it segfaulted.
another stupid question is , how I can flash these files using odin? just select *.img in
pda and start?[/QUOTE,
........................................
hello,
you can extract system.img by android kitchen but it is long process to setup kitchen.
you make it .tar file to flash as pda in odin.
if you want to extract system.img, contact me by email, [email protected]
I will tell you .
Click to expand...
Click to collapse
i need to extract the amms inside the ROM (which is a tar.md5 file), I tried to extract it with 7zip, but creating a new .tar with the file and using it to flash the baseband, Odin gets stuck on "download AMSS".
i need the amss from a 5830L, i tried to flash the amss from 2.3.4 stock rom in the russian 2.3.6, but for some reason after that the phone starts to lag, so i think i need the amss from the same version.
anyone know how to extract the amss and create a valid file to flash with?
You need to use Linux/Ubuntu to change the permissions from rwxrwxrwx back to rw-r--r--
Herpderp Adreno + Tegra.
You can only extract the file in 7Zip and repack it to Tar. However, you cannot repack it to a Odin Flashable tar. The way to do it is using either Linux or if on a Windows Machine, then Install Cygwin and run the commands from there. The commands is as follows:
tar -H ustar -c filename1.ext filename2.ext filename3.ext filename4.ext > OdinFlash.tar
Include all files to be packed including their extentions by replacing filename#.ext with the relevant filenames to be packed. The resultant tar will be flashable in Odin.
thanks, work perfectly
So...my problem is that my provider (3AT) has the option to roam in another provider-net when the connection is bad.
In Settings I have the option to choose: Roaming on/Roaming off/Only national Roaming...but this option I have only in the branded provider firmware.
My idea was to extract the csc, flash a new rom, flash the extracted csc over it and voila: New firmware with the option "national roaming only"
Now my question: Does it work how I imagine it? :laugh:
2nd question: Who can do it? :angel:
Few infos: Galaxy SII GT-I9100
PDA: I9100XWLPG
PHONE: I9100NELP4
CSC: I9100DRELP4 (This is the one I want to flash on any other rom)
Thx for your help
Push
mhm...nobody?
Push
I guess you can try and see for yourself =)
Here are the steps for extracting CSC from a firmware file.
1. Download the firmware file from Sammobile website or Intratech's thread.
2. Extract cache.img and hidden.img files from the .tar.md5 firmware file using 7zip.
3. Bundle up cache.img and hidden.img to a .tar file using the following linux command (if you are using windows, you can install Cygwin to run the command).
tar -H ustar -cf csc.tar cache.img hidden.img
4. Flash csc.tar via Odin.
Hope that helps
waaahhh...thanks so much!!!! I'll try it and report back! :victory:
So...tried to bundle it with cygwin.
It writes that : No such file or directory
Where do I have to lay the img. files?
Ah...have it by trying it out =) They have to lay in:
...:\cygwin\home\...
So...report back:
I took the latest official stock firmware, extracted it with winzip, changed the hidden.img and cache.img (took the latest from 3AT)
bundled everything as u told me and voila: IT WORKS!!!! :victory::victory::victory::victory::victory:
Great! One tip for using cygwin: you can change your working directory to something other than the default cygwin/home by entering
cd c:
Or
cd d:
Sounds like the good old MS Dos
I did this method and flashed the csc.tar.
After doing this, it prompts an install in CWM. I installed it and nothing changes afterwards. What's am I doing wrong?
Packing the file
adotkdotjh said:
Great! One tip for using cygwin: you can change your working directory to something other than the default cygwin/home by entering
cd c:
Or
cd d:
Click to expand...
Click to collapse
Hi,
can I pack the files into csc.tar using 7zip?
I see it has such a option...
Cygwin is more difficult for me.
Thank you in advance.
Greetings!
---------------------------------------------------------------------------------
I posted this in the hacking section by mistake. I hope to get some help by posting this in the correct Q&A section.
I have a Samsung Galaxy Player 70 Plus (YP-GB70D) which is sold in Korea only (got it secondhand from ebay). I cannot find any development of this player (or the Korean development team is not willing to share), particularly on installation of CWM. I would at least like to have this rooted. I did manage to find copies of the OEM firmware in TAR format.
I read about dsixda's Android Kitchen. I installed Virtualbox on my Windows 7 machine to run ubuntu 12. I successfully installed Kitchen and used it to modify my TAR firmware. I know that this player is not on the list supported by Kitchen, but the modification process seemed to complete smoothly.
I notice that the modified firmware is in ZIP format suitable for flashing with CWM (as I said there is no CWM for this player). I renamed this to "update.zip" and tried Samsung's 3e recovery, but it rejected it saying "verification fails".
Further research shows that I can unpack the factoryfs.img in the TAR firmware, and manually add su / superuser into the system folders, then repack it back into factoryfs.img and then the TAR firmware, and use ODIN or Heimdall to flash it to the player. I have also successfully installed EXT4_UTILS on ubuntu and used it to unpack the factoryfs.img into an ext4 image, and mounted the unpacked image using this command:
Code:
sudo mount -o loop output.img tempdir
Unfortunately, the mounted image only allows you to see the content of the image, and you cannot add / delete / change anything inside. I tried modifying the permission of the folder of the mounted image, but no luck.
When I look at the output from Kitchen and the mounted image, I notice they have all the identical system folders and files (except su and superuser added in the Kitchen output). Therefore, I copied the "system" folder from Kitchen output and repacked it into factoryfs.img with EXT4_UTILS, and replaced the original factoryfs.img of the OEM firmware with the modified version (I repacked the TAR using 7zip).
Unfortunately, when I flashed the modified TAR with ODIN (which detected the player without problem), it said "failed" and aborted. When I used Heimdall (which detected the player without problem), it gave me a "usblib error -12" message and aborted. I have tried unsintalling the "Samsung USB driver for mobile phone" and reinstalling the Heimdall driver from zadig.exe, but no luck.
My questions are:
(1) Is there a way to make the mounted ext4 image of the EXT4_UTILS read/writable, so that I can modify the content and add su / superuser to "bin"?
(2) Does ODIN check whether the firmware is original (OEM) or custom, and reject custom firmware? If not, why would my method of replacing the "/system" folder of the original factoryfs.img with that from the Ktichen output fail?
Thanks for helping a noob out.
As I said I used Kitchen to generate a CWM-flashable zip of the rooted version of the original firmware. I repeated the experiment, this time replacing both factoryfs.img (made from repacking the modified /system from Kitchen output using EXT4_UTILS tool) and zImage (instead of just the factoryfs.img) of the original firmware with those from the Kitchen output, then repacking the whole thing into TAR.
This time ODIN worked and completed the flashing of the customized TAR and the player rebooted into recovery for update. Unfortunately, it failed with some red error messages (too fast for me to read through before the player rebooted again).
I notice in Download Mode, the "custom firmware count = yes (1)". I wonder if this is the reason why I cannot flash anything other than official firmware, because the Samsung recovery is blocking unofficial flashing from ODIN and also Heimdall (therefore the "libusb error -12").
I found three versions of the official firmware, one of which is rooted and flashable with ODIN. I wonder how someone can sneak su into the firmware and repackage it to an official Samsung firmware?
Hello I was interested with someone here. can help me I want to take a Samsung Firmware and extract its contents. example system.img and add to some of my own applications. Into the app folder in The system.img i has been extract with some software.
Now I want to repackage the contents of the folder. Back to file system.img then to take all img files example
system.img + boot.img recovery.img cache.img + hidden.img + modem.bin and repackaged to TAR file. I will flash it with Odin