/data always has error ? - Captivate General

First of all my phone is working fine, and I don't see any errors.
However when I do FS check on the data partition - mmcblk0p2
it has so many errors!
Code:
e2fsck -yv /dev/block/mmcblk0p2
e2fsck 1.41.6 (30-May-2009)
DATA contains a file system with errors, check forced.
Pass 1: Checking inodes, blocks, and sizes
Inodes that were part of a corrupted orphan linked list found. Fix? yes
Inode 80 was part of the orphaned inode list. FIXED.
Inode 89 was part of the orphaned inode list. FIXED.
Deleted inode 91 has zero dtime. Fix? yes
Inode 105 was part of the orphaned inode list. FIXED.
Inode 5905 has imagic flag set. Clear? yes
Inode 5905 has compression flag set on filesystem without compression support. Clear? yes
Inode 5905 has INDEX_FL flag set but is not a directory.
Clear HTree index? yes
Inode 5905, i_blocks is 4294967295, should be 0. Fix? yes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Inode 5905 (...) has invalid mode (0177777).
Clear? yes
Pass 5: Checking group summary information
Inode bitmap differences: -80 -89 -91 -105
Fix? yes
Free inodes count wrong for group #0 (3270, counted=3273).
Fix? yes
Free inodes count wrong (117779, counted=117782).
Fix? yes
DATA: ***** FILE SYSTEM WAS MODIFIED *****
5098 inodes used (4.15%)
385 non-contiguous files (7.6%)
6 non-contiguous directories (0.1%)
# of inodes with ind/dind/tind blocks: 0/0/0
Extent depth histogram: 5026/57
76415 blocks used (15.55%)
0 bad blocks
1 large file
4376 regular files
707 directories
0 character device files
0 block device files
3 fifos
2 links
0 symbolic links (0 fast symbolic links)
3 sockets
--------
5091 files
[check again, it is fine now]
# e2fsck -v /dev/block/mmcblk0p2
e2fsck -v /dev/block/mmcblk0p2
e2fsck 1.41.6 (30-May-2009)
DATA: clean, 5098/122880 files, 76415/491520 blocks
[force check again, ensure all errors are corrected]
# e2fsck -fv /dev/block/mmcblk0p2
e2fsck -fv /dev/block/mmcblk0p2
e2fsck 1.41.6 (30-May-2009)
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
5098 inodes used (4.15%)
385 non-contiguous files (7.6%)
6 non-contiguous directories (0.1%)
# of inodes with ind/dind/tind blocks: 0/0/0
Extent depth histogram: 5026/57
76415 blocks used (15.55%)
0 bad blocks
1 large file
4376 regular files
707 directories
0 character device files
0 block device files
3 fifos
2 links
0 symbolic links (0 fast symbolic links)
3 sockets
--------
5091 files
Now all errors are corrected.
After a few days of normal use, install uninstall apps.... power off and on....
The data partition has errors again during FS check....

Related

Why does my almost finished build terminate with no reason or error?

I have been building some CM7/9 ROMs, but lately this one repo I'm compiling from never finishes the make job. It did worked once, but the rest of the times it never does. I do not do anything other than edit the init, mk, vendor files.
It always stops after making the system.img and terminates for no reason back to the terminal.
Code:
Install: out/target/product/vivo/system/app/SystemUI.apk
Finding NOTICE files: out/target/product/vivo/obj/NOTICE_FILES/hash-timestamp
Combining NOTICE files: out/target/product/vivo/obj/NOTICE.html
Installed file list: out/target/product/vivo/installed-files.txt
Target system fs image: out/target/product/vivo/obj/PACKAGING/systemimage_intermediates/system.img
in mkuserimg.sh PATH=out/host/linux-x86/bin/:/usr/lib/jvm/java-6-sun/bin:/home/kaijura/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/home/kaijura/android-sdk/tools:/home/kaijura/android-sdk/platform-tools:/home/kaijura/icecold/out/host/linux-x86/bin:/home/kaijura/icecold/prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin:/home/kaijura/icecold/development/emulator/qtools:/home/kaijura/icecold/prebuilt/linux-x86/toolchain/arm-eabi-4.6.3/bin:/home/kaijura/icecold/prebuilt/linux-x86/toolchain/arm-eabi-4.6.3/bin
make_ext4fs -s -l 585101312 -a system out/target/product/vivo/obj/PACKAGING/systemimage_intermediates/system.img out/target/product/vivo/system
Creating filesystem with parameters:
Size: 585101312
Block size: 4096
Blocks per group: 32768
Inodes per group: 7152
Inode size: 256
Journal blocks: 2231
Label:
Blocks: 142847
Block groups: 5
Reserved block group size: 39
Created filesystem with 1402/35760 inodes and 66573/142847 blocks
Install system fs image: out/target/product/vivo/system.img
out/target/product/vivo/system.img+out/target/product/vivo/obj/PACKAGING/recovery_patch_intermediates/recovery_from_boot.p total size is 266217238
[email protected]:~/icecold$
Any ideas what I can try? I have done make clean, deleted the out folder and have properly set ccache.
Code:
export USE_CCACHE=1
export CCACHE_DIR=/home/kaijura/.ccache
prebuilt/linux-x86/ccache/ccache -M 40G
make -j2

[SOLVED] HELP! I'm soft Brick

Ok people I need help I'm soft brick I can get into recovery and fastboot but If install a ROM it doesn't pass ASUS Screen and it gets a reboot loop just there
any idea?
I downloading right now asus default firmware to try to put it on SD hope that works cus I don't need a 500$ paperweight
maxrdlf95 said:
Ok people I need help I'm soft brick I can get into recovery and fastboot but If install a ROM it doesn't pass ASUS Screen and it gets a reboot loop just there
any idea?
I downloading right now asus default firmware to try to put it on SD hope that works cus I don't need a 500$ paperweight
Click to expand...
Click to collapse
How did you soft brick your device??
buhohitr said:
How did you soft brick your device??
Click to expand...
Click to collapse
Making stuff
Flashing via fastboot doesn't revive my tablet Now I flashing putting the original Update on the SD card with the original recovery..
Flashing for SD Didn't work either I Fixed my tablet .. mmm let's say it's an advanced thing
Code:
~ # tune2fs -l /dev/block/mmcblk0p2 | grep features
tune2fs -l /dev/block/mmcblk0p2 | grep features
Filesystem features: has_journal resize_inode filetype needs_recovery exten
t sparse_super large_file
~ # e2fsck -f /dev/block/mmcblk0p2
e2fsck -f /dev/block/mmcblk0p2
e2fsck 1.41.12 (17-May-2010)
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
/dev/block/mmcblk0p2: 16/27392 files (6.3% non-contiguous), 3650/109568 blocks
~ # tune2fs -O ^has_journal -c 1 -i 1d -m 0 /dev/block/mmcblk0p2
tune2fs -O ^has_journal -c 1 -i 1d -m 0 /dev/block/mmcblk0p2
tune2fs 1.41.12 (17-May-2010)
Setting maximal mount count to 1
Setting interval between checks to 86400 seconds
Setting reserved blocks percentage to 0% (0 blocks)
~ # e2fsck -f /dev/block/mmcblk0p2
e2fsck -f /dev/block/mmcblk0p2
e2fsck 1.41.12 (17-May-2010)
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
/dev/block/mmcblk0p2: 16/27392 files (6.3% non-contiguous), 1938/109568 blocks
~ # tune2fs -l /dev/block/mmcblk0p2 | grep features
tune2fs -l /dev/block/mmcblk0p2 | grep features
Filesystem features: resize_inode filetype extent sparse_super large_file
~ # e2fsck -f /dev/block/mmcblk0p8
e2fsck -f /dev/block/mmcblk0p8
e2fsck 1.41.12 (17-May-2010)
Pass 1: Checking inodes, blocks, and sizes
Deleted inode 1646715 has zero dtime. Fix<y>? y
y
yes
Deleted inode 1647157 has zero dtime. Fix<y>? yes
Pass 2: Checking directory structure
Entry 'dontpanic' in / (2) has deleted/unused inode 221185. Clear<y>? y
y
yes
Entry 'misc' in / (2) has deleted/unused inode 778241. Clear<y>? yes
Entry 'local' in / (2) has deleted/unused inode 892929. Clear<y>? y
y
yes
Pass 3: Checking directory connectivity
Unconnected directory inode 1400833 (/???)
Connect to /lost+found<y>? yes
Pass 4: Checking reference counts
Inode 2 ref count is 26, should be 24. Fix<y>? y
y
yes
Unattached inode 1237006
Connect to /lost+found<y>? yes
Inode 1237006 ref count is 2, should be 1. Fix<y>? y
y
yes
Inode 1400833 ref count is 3, should be 2. Fix<y>? yes
Unattached inode 1630913
Connect to /lost+found<y>? y
y
yes
Inode 1630913 ref count is 2, should be 1. Fix<y>? yes
Unattached inode 1631458
Connect to /lost+found<y>? y
y
yes
Inode 1631458 ref count is 2, should be 1. Fix<y>? yes
Unattached inode 1655157
Connect to /lost+found<y>? y
y
yes
Inode 1655157 ref count is 2, should be 1. Fix<y>? yes
Unattached inode 1655166
Connect to /lost+found<y>? y
y
yes
Inode 1655166 ref count is 2, should be 1. Fix<y>? yes
Pass 5: Checking group summary information
Block bitmap differences: +(3520--3559) -(831232--831394) -1248476 -1248519 +12
48522 -2826956 -(2827309--2827316) -2828801 -2828805 -(2829826--2829827) +(28298
50--2829853) +2829855 +3133955 +(3134982--3134983) -(6523708--6523717) -6548656
+6548787 -(6624192--6624247) -6636288 +(6636296--6636297) +6636304
Fix<y>? y
y
yes
Free blocks count wrong for group #0 (31180, counted=31109).
Fix<y>? yes
Free blocks count wrong for group #25 (3596, counted=3759).
Fix<y>? y
y
yes
Free blocks count wrong for group #27 (30714, counted=30715).
Fix<y>? yes
Free blocks count wrong for group #38 (32213, counted=32214).
Fix<y>? y
y
yes
Free blocks count wrong for group #86 (25562, counted=25569).
Fix<y>? yes
Free blocks count wrong for group #95 (23279, counted=23289).
Fix<y>? y
y
yes
Free blocks count wrong for group #109 (32252, counted=32254).
Fix<y>? yes
Free blocks count wrong for group #171 (32254, counted=32253).
Fix<y>? y
y
yes
Free blocks count wrong for group #199 (23041, counted=23051).
Fix<y>? yes
Free blocks count wrong for group #202 (26244, counted=26298).
Fix<y>? y
y
yes
Free blocks count wrong (4374231, counted=4374407).
Fix<y>? yes
Inode bitmap differences: +1237006 +1631458 -1646715 -1647157 +1655157 +1655166
Fix<y>? y
y
yes
Free inodes count wrong for group #27 (8191, counted=8192).
Fix<y>? yes
Directories count wrong for group #27 (1, counted=0).
Fix<y>? y
y
yes
Free inodes count wrong for group #95 (8179, counted=8192).
Fix<y>? yes
Directories count wrong for group #95 (11, counted=0).
Fix<y>? y
y
yes
Free inodes count wrong for group #109 (8190, counted=8192).
Fix<y>? yes
Directories count wrong for group #109 (2, counted=0).
Fix<y>? y
y
yes
Free inodes count wrong for group #151 (8175, counted=8174).
Fix<y>? yes
Free inodes count wrong for group #171 (8192, counted=8191).
Fix<y>? y
y
yes
Directories count wrong for group #171 (0, counted=1).
Fix<y>? yes
Free inodes count wrong for group #199 (6581, counted=6580).
Fix<y>? y
y
yes
Free inodes count wrong for group #201 (6796, counted=6798).
Fix<y>? yes
Free inodes count wrong for group #202 (7800, counted=7798).
Fix<y>? y
y
yes
Free inodes count wrong (1796954, counted=1796967).
Fix<y>? yes
/dev/block/mmcblk0p8: ***** FILE SYSTEM WAS MODIFIED *****
/dev/block/mmcblk0p8: 13465/1810432 files (4.2% non-contiguous), 2856689/7231096
blocks
~ # tune2fs -O ^has_journal -c 1 -i 1d -m 0 /dev/block/mmcblk0p8
tune2fs -O ^has_journal -c 1 -i 1d -m 0 /dev/block/mmcblk0p8
tune2fs 1.41.12 (17-May-2010)
Setting maximal mount count to 1
Setting interval between checks to 86400 seconds
Setting reserved blocks percentage to 0% (0 blocks)
~ # e2fsck -f /dev/block/mmcblk0p8
e2fsck -f /dev/block/mmcblk0p8
e2fsck 1.41.12 (17-May-2010)
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
/dev/block/mmcblk0p8: 13465/1810432 files (4.2% non-contiguous), 2856689/7231096
blocks
~ # tune2fs -l /dev/block/mmcblk0p8 | grep features
tune2fs -l /dev/block/mmcblk0p8 | grep features
Filesystem features: resize_inode filetype extent sparse_super large_file
~ # exit
exit
C:\Program Files (x86)\Android\android-sdk\platform-tools>
what were you doing which caused the brick. have you tried to push a new rom via adb, can you get into recovery. if you can get into recovery, wipe your entire phone then push a new rom via adb, it is possible to get corroptions putting the sd card in ur computer transfring a rom them putting the sd back in your tablet, bypass all that and us adb
Sent from my ASUS Transformer Pad TF700T using Xparent Blue Tapatalk 2
Are you on the right bootloader for the ROM you are trying to flash?
pals0007 said:
what were you doing which caused the brick. have you tried to push a new rom via adb, can you get into recovery. if you can get into recovery, wipe your entire phone then push a new rom via adb, it is possible to get corroptions putting the sd card in ur computer transfring a rom them putting the sd back in your tablet, bypass all that and us adb
Sent from my ASUS Transformer Pad TF700T using Xparent Blue Tapatalk 2
Click to expand...
Click to collapse
It was a journaling thing man this shouldn't happen to a normal user I think
maxrdlf95 said:
It was a journaling thing man this shouldn't happen to a normal user I think
Click to expand...
Click to collapse
Trying to flash Data2SD by any chance eh!
Sent from a tablet optimized by CleanROM 2.3
Thats OK said:
Trying to flash Data2SD by any chance eh!
Sent from a tablet optimized by CleanROM 2.3
Click to expand...
Click to collapse
It wasn't Data2SD I was disabling Journaling on the Original Tablet partition.. hehe

data/data IO error

As far as I can tell, my OPO work just fine
However, when I tried to do a nandroid using PhilZ, it is reporting that there's IO error with /data/data/com.nubelacorp.javelin/database, and can't finish nandroid backup
I then reboot back, and check it using a rooted shell, and this is what I see
Code:
1|[email protected]:/data/data/com.nubelacorp.javelin # pwd
pwd
/data/data/com.nubelacorp.javelin
[email protected]:/data/data/com.nubelacorp.javelin # ls
ls
app_webview
databases
[email protected]:/data/data/com.nubelacorp.javelin # ls -la
ls -la
drwxrwx--x u0_a137 u0_a137 2014-08-31 04:07 app_webview
[email protected]:/data/data/com.nubelacorp.javelin # busybox ls -la
busybox ls -la
ls: ./databases: I/O error
drwxr-x--x 4 u0_a137 u0_a137 4096 Aug 31 04:08 .
drwxrwx--x 188 system system 8192 Aug 31 04:01 ..
drwxrwx--x 3 u0_a137 u0_a137 4096 Aug 31 04:07 app_webview
1|[email protected]:/data/data/com.nubelacorp.javelin #
In fact, app_webview has similar problem inside: quite a few files are having IO error
has anyone come across this IO error before?
Any idea how to recover/fix it?
Thanks!
Welp...
Since it's Android, it's running linux, and I can use fsck to fix this error
However, I still have no idea how the filesystem got corrupted in the first place
So I hook up my phone to PC, so I can adb into it...
I then reboot recovery
I then adb shell into the phone
I now use PhilZ to mount /data so I know the device name to data
I switch back to adb shell and run e2fsck
Code:
~ # /sbin/e2fsck -f /dev/block/platform/msm_sdcc.1/by-name/userdata
/sbin/e2fsck -f /dev/block/platform/msm_sdcc.1/by-name/userdata
e2fsck 1.41.14 (22-Dec-2010)
Pass 1: Checking inodes, blocks, and sizes
Inodes that were part of a corrupted orphan linked list found. Fix<y>? y
y
yes
Inode 214760 was part of the orphaned inode list. FIXED.
Inode 215662 was part of the orphaned inode list. FIXED.
Inode 263256 was part of the orphaned inode list. FIXED.
Inode 524292 was part of the orphaned inode list. FIXED.
Inode 524293 was part of the orphaned inode list. FIXED.
Inode 524294 was part of the orphaned inode list. FIXED.
Inode 534273 is in use, but has dtime set. Fix<y>? yes
...
Inode 534275 has INDEX_FL flag set but is not a directory.
Clear HTree index<y>? yes
Inode 534275 should not have EOFBLOCKS_FL set (size 2750915995060022687, lblk -1)
Clear<y>? y
y
yes
Inode 534275, i_size is 2750915995060022687, should be 0. Fix<y>? yes
Inode 534275, i_blocks is 1606023128, should be 0. Fix<y>? y
y
yes
Restarting e2fsck from the beginning...
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Inode 534273 (/data/com.nubelacorp.javelin/app_webview/Local Storage/http_download.paranoidandroid.co_0.localstorage-journal) has invalid mode (0176337).
Clear<y>? yes
Inode 534274 (/data/com.nubelacorp.javelin/app_webview/Local Storage/http_android.stackexchange.com_0.localstorage) is an illegal socket.
Clear<y>? y
y
yes
Inode 534275 (/data/com.nubelacorp.javelin/app_webview/Local Storage/http_android.stackexchange.com_0.localstorage-journal) has invalid mode (0131667).
Clear<y>? yes
Inode 534276 (/data/com.nubelacorp.javelin/app_webview/Local Storage/https_support.mozilla.org_0.localstorage) has invalid mode (0113763).
Clear<y>? y
y
yes
Inode 534277 (/data/com.nubelacorp.javelin/app_webview/Local Storage/https_support.mozilla.org_0.localstorage-journal) has invalid mode (0130770).
Clear<y>? yes
Entry 'databases' in /data/com.nubelacorp.javelin (533973) has deleted/unused inode 534278. Clear<y>? y
y
yes
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Inode 533973 ref count is 4, should be 3. Fix<y>? yes
Inode 534279 (...) has invalid mode (0113741).
Clear<y>? y
y
yes
Unattached inode 534280
Connect to /lost+found<y>? yes
Inode 534280 ref count is 57602, should be 1. Fix<y>? y
y
yes
Unattached inode 534281
Connect to /lost+found<y>? yes
Inode 534281 ref count is 2, should be 1. Fix<y>? y
y
yes
...
Pass 5: Checking group summary information
Block bitmap differences: -2130956 -(2131936--2131942) -(2142616--2142620)
Fix<y>? yes
Free blocks count wrong for group #65 (11321, counted=11334).
Fix<y>? y
y
yes
Free blocks count wrong (12163563, counted=12163576).
Fix<y>? yes
Inode bitmap differences: -534278
Fix<y>? y
y
yes
Free inodes count wrong for group #65 (6036, counted=6037).
Fix<y>? yes
Directories count wrong for group #65 (100, counted=99).
Fix<y>? y
y
yes
Free inodes count wrong (3645496, counted=3645497).
Fix<y>? yes
/dev/block/platform/msm_sdcc.1/by-name/userdata: ***** FILE SYSTEM WAS MODIFIED
*****
/dev/block/platform/msm_sdcc.1/by-name/userdata: 16327/3661824 files (5.1% non-contiguous), 2464055/14627631 blocks
~ #
Now I go back to PhilZ and mount /data again
this time IO error is gone
and I can remove directory without error
Code:
/data/data # pwd
pwd
/data/data
/data/data # ls com.nubelacorp.javelin
ls com.nubelacorp.javelin
app_webview
/data/data # busybox ls -al com.nubelacorp.javelin
busybox ls -al com.nubelacorp.javelin
__bionic_open_tzdata: couldn't find any tzdata when looking for localtime!
__bionic_open_tzdata: couldn't find any tzdata when looking for GMT!
__bionic_open_tzdata: couldn't find any tzdata when looking for posixrules!
drwxr-x--x 3 u0_a137 u0_a137 4096 Aug 31 11:08 .
drwxrwx--x 188 system system 8192 Aug 31 11:01 ..
drwxrwx--x 3 u0_a137 u0_a137 4096 Aug 31 11:07 app_webview
/data/data #
/data/data/com.nubelacorp.javelin/app_webview/Local Storage # pwd
pwd
/data/data/com.nubelacorp.javelin/app_webview/Local Storage
/data/data/com.nubelacorp.javelin/app_webview/Local Storage # cd ..
cd ..
/data/data/com.nubelacorp.javelin/app_webview # rmdir 'Local Storage'
rmdir 'Local Storage'
/data/data/com.nubelacorp.javelin/app_webview # cd ..
cd ..
/data/data/com.nubelacorp.javelin # rmdir app_webview
rmdir app_webview
/data/data/com.nubelacorp.javelin # cd ..
cd ..
/data/data # rmdir com.nubelacorp.javelin
rmdir com.nubelacorp.javelin
/data/data #
and now I can nandroid without error!

Mi 4C stuck on preparing apps boot loop

Hi,
years ago i installed the Teamsuperluminal's CM13 on my Xiaomi Mi 4c and it it worked for a long time without major issues. Lately the phone started to auto power down when the battery reached appr. 50% charge. I would hook it up to a charger and reboot it and charge it back up again. Then it was fine again, this has been going on for months now. But yesterday it auto powered down again and after reboot it showed the CM boot logo for an unusual amount of time, after that it started preparing apps for start. When it was done with that it would just immediately reboot and start over again. So it is now stuck on a preparing apps reboot loop.
What i have tried so far:
1. Wipe cache and dalvik in TWRP and reboot. Didn't help
2. Tried to reformat a partition that might be corrupted due to brown out with:
Code:
make_ext4fs /dev/block/mmcblk0p15
It shows the following error:
Code:
Creating filesystem with parameters:
Size: 131072
Block size: 4096
Blocks per group: 32768
Inodes per group: 16
Inode size: 256
Journal blocks:1024
Label:
Blocks: 32
Block groups: 1
Reserved block group size: 7
error: ext4_allocate_best_fit_partial: failed to allocate 1005 blocks, out of space?
But there are more than 2GB of free space available and mmblk0p15 is then missing from /dev/block/ , so if i run the same command again i get:
Code:
Need size of filesystem
How can i repair this or what log file might be interesting?

[TUTORIAL] How to Edit Unpack & Repack Samsung system.img or system.img.ext4

Follow https://stackoverflow.com/questions...ack-and-flash-system-img-ext4-file-using-odin
a) Modifying
With
Code:
simg2img system.img.ext4 system.img
, you will get a raw image file named system.img
With
Code:
mkdir system
, create directory to mount system.img
With
Code:
sudo mount -t ext4 -o loop system.img system/
you will get all files of system.img in system folder
example: edit init.rc
With
Code:
ls -l system/init.rc
note permissions: 750
With
Code:
sudo chmod 777 system/init.rc
give write permissions
With
Code:
sudo echo "#MODIFICATION " >> system/init.rc
done some modification in init.rc
With
Code:
sudo chmod 750 init.rc
reset init.rc to the noted permissions
b) Calculate system sector size (Example)
With
Code:
tune2fs -l system.img | grep "Block size\|Block count"
you will get block size and count
With
Code:
echo $((1553064 * 4096))
multiply both results. I got 6361350144
c) Packing (Example)
With
Code:
sudo make_ext4fs -s -l 6361350144 -a system system_new.img sys/
you will get system_new.img “Android Sparse Image” that has all changes
With
Code:
sudo umount system
unmount the system directory
With
Code:
rm -fr system
delete the system directory
If you have a system.img file not system.img.ext4, maybe it's ext4 type just rename and delete ext4 after ".img" then follow the instructions. You may want to edit or delete but stumble on permissions, just type
Code:
sudo nautilus
and you can do it with nautilus explorer as it is root explorer.
this method is wrong
Could not build the correct package
Specifically, you can compare tune2fs -l system.img
Like this
```
Filesystem volume name: system
Last mounted on: /home/xs/tools/roms/SM-G892A_ATT/images/system
Filesystem UUID: 4c64e17e-22c3-54ec-bc54-14deddbf5036
Filesystem magic number: 0xEF53
Filesystem revision #: 1 (dynamic)
Filesystem features: has_journal ext_attr dir_index filetype extent flex_bg sparse_super large_file huge_file uninit_bg dir_nlink extra_isize
Filesystem flags: signed_directory_hash
Default mount options: journal_data_ordered user_xattr acl discard
Filesystem state: clean
Errors behavior: Panic
Filesystem OS type: Linux
Inode count: 289152
Block count: 1156446
Reserved block count: 0
Free blocks: 81485
Free inodes: 281937
First block: 0
Block size: 4096
Fragment size: 4096
Blocks per group: 32768
Fragments per group: 32768
Inodes per group: 8032
Inode blocks per group: 502
Flex block group size: 16
Filesystem created: Wed Dec 31 23:00:00 2008
Last mount time: Sun Jul 17 18:00:08 2022
Last write time: Sun Jul 17 18:12:50 2022
Mount count: 2
Maximum mount count: 36
Last checked: Wed Dec 31 23:00:00 2008
Check interval: 15552000 (6 months)
Next check after: Mon Jun 29 23:00:00 2009
Lifetime writes: 69 MB
Reserved blocks uid: 0 (user root)
Reserved blocks gid: 0 (group root)
First inode: 11
Inode size: 256
Required extra isize: 32
Desired extra isize: 32
Journal inode: 8
Default directory hash: half_md4
Directory Hash Seed: 0b0112c3-9689-5f54-ab9d-304e9f9e0ec7
Journal backup: inode blocks
```
xs23933 said:
this method is wrong
Could not build the correct package
Specifically, you can compare tune2fs -l system.img
Like this
```
Filesystem volume name: system
Last mounted on: /home/xs/tools/roms/SM-G892A_ATT/images/system
Filesystem UUID: 4c64e17e-22c3-54ec-bc54-14deddbf5036
Filesystem magic number: 0xEF53
Filesystem revision #: 1 (dynamic)
Filesystem features: has_journal ext_attr dir_index filetype extent flex_bg sparse_super large_file huge_file uninit_bg dir_nlink extra_isize
Filesystem flags: signed_directory_hash
Default mount options: journal_data_ordered user_xattr acl discard
Filesystem state: clean
Errors behavior: Panic
Filesystem OS type: Linux
Inode count: 289152
Block count: 1156446
Reserved block count: 0
Free blocks: 81485
Free inodes: 281937
First block: 0
Block size: 4096
Fragment size: 4096
Blocks per group: 32768
Fragments per group: 32768
Inodes per group: 8032
Inode blocks per group: 502
Flex block group size: 16
Filesystem created: Wed Dec 31 23:00:00 2008
Last mount time: Sun Jul 17 18:00:08 2022
Last write time: Sun Jul 17 18:12:50 2022
Mount count: 2
Maximum mount count: 36
Last checked: Wed Dec 31 23:00:00 2008
Check interval: 15552000 (6 months)
Next check after: Mon Jun 29 23:00:00 2009
Lifetime writes: 69 MB
Reserved blocks uid: 0 (user root)
Reserved blocks gid: 0 (group root)
First inode: 11
Inode size: 256
Required extra isize: 32
Desired extra isize: 32
Journal inode: 8
Default directory hash: half_md4
Directory Hash Seed: 0b0112c3-9689-5f54-ab9d-304e9f9e0ec7
Journal backup: inode blocks
```
Click to expand...
Click to collapse
Use tune2fs -l system.img to view system.img.
found the original system.img
Default mount options: journal_data_ordered user_xattr acl discard
Errors behavior: Panic
Unpack (do nothing) the repacked system_new.img
Default mount options: user_xattr acl
Errors behavior: Continue
What's going on here?
Can make "Default mount options: user_xattr acl" packaged as "Default mount options: journal_data_ordered user_xattr acl discard"
?
You are missing the fs_config and file_context files when calling the make_ext4fs binary. Anyone know how to generate those on the fly?
how do get a system.img from a super.img file?

Categories

Resources