[REF][I9500-I9505] How to repack galaxy S4 img files (system/cache)

Search This thread

M_J_Nazari

Inactive Recognized Developer
Jul 14, 2010
1,545
2,577
35
Bushehr
pda-planet.com
Hi , please someone describe where the 2764Mb is coming from?


Code:
make_ext4fs -s -l 2764M -a system /sdcard/system.img /system

i searched for partition table for i9500 but cant find this number

Code:
lrwxrwxrwx root root 2013-03-26 16:07 SYSTEM -> /dev/block/mmcblk0p20

************************
major   minor  #blocks    name
259       12    2830336    mmcblk0p20
************************
/dev/block/mmcblk0p20 /system ext4 ro,seclabel,relatime,data=ordered 0 0
************************
 

shayind4

Senior Member
Mar 24, 2008
540
97
London
Hi , please someone describe where the 2764Mb is coming from?


Code:
make_ext4fs -s -l 2764M -a system /sdcard/system.img /system

i searched for partition table for i9500 but cant find this number

Code:
lrwxrwxrwx root root 2013-03-26 16:07 SYSTEM -> /dev/block/mmcblk0p20

************************
major   minor  #blocks    name
259       12    2830336    mmcblk0p20
************************
/dev/block/mmcblk0p20 /system ext4 ro,seclabel,relatime,data=ordered 0 0
************************


Hi

When you unpack system.img, the size of 'system.img' in output file = 2898264064 bytes.

Now convert to megabytes. 1024 bytes= 1 kilobytes, and 1024 kilobytes= 1 megabytes.

Size of filesystem= 2898264064/1024/1024=2764M.
 
  • Like
Reactions: M_J_Nazari

M_J_Nazari

Inactive Recognized Developer
Jul 14, 2010
1,545
2,577
35
Bushehr
pda-planet.com
finally i made the system.img from my phone and it boots correctly , but there is no permissions for some files like su.
I tried another way to make system.img from linux but no success too , as i checked the problem it caused by file permission problem, it seems many files have not correct permissions, phone stays on samsung logo ( 2nd logo ), tried to catch the logcat, but i cant access too, this is the message, any idea please?
Code:
M:\>adb logcat
- exec '/system/bin/sh' failed: Permission denied (13) -
 
Last edited:

shayind4

Senior Member
Mar 24, 2008
540
97
London
finally i made the system.img from my phone and it boots correctly , but there is no permissions for some files like su.
I tried another way to make system.img from linux but no success too , as i checked the problem it caused by file permission problem, it seems many files have not correct permissions, phone stays on samsung logo ( 2nd logo ), tried to catch the logcat, but i cant access too, this is the message, any idea please?
Code:
M:\>adb logcat
- exec '/system/bin/sh' failed: Permission denied (13) -

Hi

Check here for solution: https://android-review.googlesource.com/#/c/100312/

shayind4
 
  • Like
Reactions: M_J_Nazari

saniel_fly

Member
Apr 23, 2015
6
2
Chainfire's bloating tool works also for Samsung Galaxy Young 2

I know this thread is about S4 but I want to inform you that the Chainfire's bloating tool works also for Galaxy Young 2. Many thanks, Chainfire.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 4
    Hi xda


    for some reson the ext4_utils is not working well on the galaxy s4, but there is another way to do that.

    so thanks to hua_wuxin explained to me how to do it, and big thank to Chenglu for this.

    What do you need to do:

    • first flash the firmware you wnat to modify, and root the phone. (it's can't be done without root first)
    • Do your changes in the device, by root explorer, zip files and etc.
    • Then via CMD (or terminal emulator) you type the following commands to dump the partition to samsung img file. (odin img, not ext4)


    The commands according to the device and partition.

    I9500
    System:
    Code:
    su
    make_ext4fs -s -l 2764M -a system /sdcard/system.img /system

    Cache:
    Code:
    su
    make_ext4fs -s -l 2072M -a cache /sdcard/cache.img /cache



    I9505
    System:
    Code:
    su
    make_ext4fs -s -l 2760M -a system /sdcard/system.img.ext4 /system

    Cache:
    Code:
    su
    make_ext4fs -s -l 2070M -a cache /sdcard/cache.img.ext4 /cache

    Now you can flash in odin by making tar from this modified img and the rest of the firmware.

    The commands to create tar file, for example to I9500. (Cygwin or Linux)
    Code:
    tar -c boot.img cache.img hidden.img modem.bin recovery.img system.img >> file_name.tar
    md5sum -t file_name.tar >> file_name.tar
    mv file_name.tar file_name.tar.md5

    Good Luck!


    Sorry for my bad english.
    3
    Unfortunately, this still doesn't work for the I9500. Works fine for I9505 (which for me never had any issue at all, and worked with existing make_ext4fs tools just fine), but can't get *anything* to work with I9500.
    2
    works great!
    i flashed it on new device and i checked it with root explorer.
    the android was red like all cf-auto root.

    waitng to your tool..
    thanks.
    1
    To me it worked for both I9500 and I9505.
    I created successfully for the I9500/I9505 scripts to add hebrew language to the languages list, by flashing custem recovery and cache img. (extended command and zip like your old root method to I9300)
    also, i created full firmwares to both models with system and cache modified.
    i flashed this files on over 1000 devices (I9500), and it's works gerat.

    Have you tried making the I9500 image on the I9505 ? Or only on the I9500 ?

    Could you make and attach an empty (or containing one small file: echo 1 > file ) custom cache.img for the I9500, so I can test some more ?

    Really need to get this working :) I wish I actually had the device, heh ...

    EDIT: Also maybe attach the make_ext4fs from your device ?
Our Apps
Get our official app!
The best way to access XDA on your phone
Nav Gestures
Add swipe gestures to any Android
One Handed Mode
Eases uses one hand with your phone