cxxsheng@XXXXXXXX SAMFW.COM_SM-A217F_TGY_A217FZHSADWI1_fac % tar -xvf AP_A217FZHSADWI1_CL24202344_QB71112077_REV00_user_low_ship_MULTI_CERT_meta_RKEY_OS12.tar.md5 x boot.img.lz4 x recovery.img.lz4 x dtbo.img.lz4 x super.img.lz4 x userdata.img.lz4 x misc.bin.lz4 x vbmeta.img.lz4 x metadata.img.lz4 x vbmeta_samsung.img.lz4 x meta-data/ x meta-data/fota.zip
继续解压super.img.lz4:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
cxxsheng@XXXXXXXX SAMFW.COM_SM-A217F_TGY_A217FZHSADWI1_fac % 7z x super.img.lz4
7-Zip [64] 17.05 : Copyright (c) 1999-2021 Igor Pavlov : 2017-08-28 p7zip Version 17.05 (locale=utf8,Utf16=on,HugeFiles=on,64 bits,8 CPUs x64)
Scanning the drive for archives: 1 file, 3273506624 bytes (3122 MiB)
Extracting archive: super.img.lz4 -- Path = super.img.lz4 Type = lz4
Everything is Ok
Size: 5351957720 Compressed: 3273506624
最后得出来了一个super.img
2. 解包super.img
1 2 3
cxxsheng@XXXXXXXX SAMFW.COM_SM-A217F_TGY_A217FZHSADWI1_fac % file super.img super.img: Android sparse image, version: 1.0, Total of 1356800 4096-byte output blocks in 101 input chunks. cxxsheng@XXXXXXXX SAMFW.COM_SM-A217F_TGY_A217FZHSADWI1_fac %
cxxsheng@XXXXXXXX SAMFW.COM_SM-A217F_TGY_A217FZHSADWI1_fac % lpunpack.py super.img out/ Sparse image detected. Process conversion to non sparse image ....[ok] Extracting partition [system] .... [ok] Extracting partition [vendor] .... [ok] Extracting partition [product] .... [ok] Extracting partition [odm] .... [ok] cxxsheng@XXXXXXXX SAMFW.COM_SM-A217F_TGY_A217FZHSADWI1_fac % cd out cxxsheng@XXXXXXXX out % ls odm.img product.img system.img vendor.img cxxsheng@XXXXXXXX out % ls -l total 10519552 -rwx------ 1 cxxsheng staff 4349952 Sep 27 17:22 odm.img -rwx------ 1 cxxsheng staff 1065545728 Sep 27 17:22 product.img -rwx------ 1 cxxsheng staff 3826253824 Sep 27 17:22 system.img -rwx------ 1 cxxsheng staff 489086976 Sep 27 17:22 vendor.img
得到system.img,并且用file命令查看这个文件信息。
1 2 3
cxxsheng@XXXXXXXX out % file system.img system.img: Linux rev 1.0 ext2 filesystem data, UUID=5aceb523-09b9-551f-8359-437ee4e7f7e1 (extents) (large files) (huge files) cxxsheng@XXXXXXXX out %
可以看到是ext2的文件系统格式,这个系统可以直接用7z解压就行了,如下:
1
7z x system.img
3. F2FS文件系统
有时候file命令查看文件信息是F2FS的文件系统如下:
1 2 3
cxxsheng@XXXXXXXX out % file system.img system.img: F2FS filesystem, UUID=2e533b9d-cbfe-4c0c-9726-3e45a77dc44a, volume name "/" cxxsheng@XXXXXXXX out %