Details on individual partitions
Details on individual partitions
Boot.img details
The boot.img is generated using umulti.sh script (also shown below)
./mkbootimg --kernel zImage --ramdisk ramdisk.img --base 0x80000000 --cmdline "console=ttyO2,115200n8 mem=456M@0x80000000 mem=512M@0xA0000000 init=/init vram=10M omapfb.vram=0:4M androidboot.console=ttyO2" --board omap4 -o boot.img
As you see in the line above, the kernel image used is zImage instead of uImage that we usually use.
TIP: If you have a uImage, you can create a zImage from it using the following command
dd if=uImage bs=64 skip=1 of=zImage
The zImage is combined with ramdisk.img, which contains all the initial boot up programs (init, init.rc etc).
If you have to edit ramdisk.img, it can be done by following this
Opening and changing files in ramdisk.img for debugging
A ramdisk is basically a small filesystem containing the core files needed to initialize the system. It includes the critical init process, as well as init.rc, which is where you can set many system-wide properties. If you really want to know more about it, here is the documentation. Here's a list of files on a typical ramdisk:
data default.prop dev env.txt init init.goldfish.rc init.omapzoom2.rc init.rc proc sbin\ sbin\adbd sbin\hotplug
Here are the steps to open, edit and create a new ramdisk.img
- Copy the ramdisk.img to your UBuntu (Linux) machine
- Back up ramdisk.img and Create a temporary folder, say tmp
# cp ramdisk.img ramdisk.img.bkup # mkdir tmp && cd tmp
- Extract the ramdisk using the command below
# gunzip -c ../ramdisk.img | cpio -i
- Modify the contents of tmp folder. The contents of tmp folder will get into the ramdisk.img
Modify the contents of file in tmp folder eg. init.rc
- Recreate the ramdisk.cpio with command:
# find . | cpio -o -H newc | gzip > ../ramdisk.img
Once the ramdisk.img is re-generated, you need to regenerate the boot.img using mkbootimg command shown above, and flash it for your init.rc changes to get reflected. Similarly, for updating the kernel you should regenerate boot.img with new zImage and flash it using fastboot command in earlier section.
TIP: If you want to just test your boot.img, without flashing you can use the command below
./fastboot boot ./boot.img
System image is a sparsed ext4 loop mounted file system. To open (mount) system image use the commands below
./simg2img system.img system.img.raw mkdir tmp sudo mount -t ext4 -o loop system.img.raw tmp/
After this, all your system image files are part of tmp folder.
Make any changes you need in the tmp folder. To re-create the parsed system image (system.img.new) use the command below. This can be individually flashed using fastboot command
sudo ./make_ext4fs -s -l 512M -a system system.img.new tmp/ sudo umount tmp rm -rf tmp
Userdata.img details
This partition contains user-installed applications and data, including customization data
Again this is a sparsed ext4 loop mounted filesystem. To extract the sparesed image, use the command below
./simg2img userdata.img userdata.img.raw ./mkdir tmp sudo mount -t ext4 -o loop userdata.img.raw tmp/
Now you can make any changed in the tmp folder. To re-create a new userdata.img, use the command below to generate userdata.img.new, which can be flashed using fastboot.
sudo ./make_ext4fs -s -l 512M -a userdata userdata.img.new tmp/ sudo umount tmp rm -rf tmp
Cache.img details
This partition can be used to store temporary data. It is currently an empty ext4 image.
Commands to create this image
mkdir tmp/ sudo ./make_ext4fs -s -l 256M -a cache cache.img tmp/
Frequently used Commands for eMMC
To remount system partition in R/W mode for OMAP4
adb remount - remounts the /system partition on the device read-write
To remount rootfs as R/W mode
mount -o rw,remount -t auto /dev/block/mmcblk0p1 /
To add busybox run the commands below
adb shell 'chmod 0755 /data/busybox/bin/* /data/busybox/sbin/*' adb shell '/data/busybox/bin/mount -oremount,rw /' adb shell '/data/busybox/bin/mount -oremount,rw /system' adb shell 'ln -s /data/busybox/bin /system/vendor/bin' adb shell 'ln -s /data/busybox/sbin /system/vendor/sbin'
相關文章
- 個人專案 Individual ProjectProject
- Individual Project - Word_frequencyProject
- Individual Project - Word frequency programProject
- Record for Individual Project ( Word frequency program )Project
- Backing Up Individual Tablespaces with RMAN
- Partitioned Indexes on Composite PartitionsIndex
- ClickHouse 的 Parts 和 Partitions
- 7.46 CLUSTER_DETAILSAI
- Writing on important detailsImportAI
- 如何修改table及partitions Table
- Getting More Information about PartitionsORM
- 7.89 FEATURE_DETAILSAI
- SAP Purchasing Group in DetailsAI
- PostgreSQL DBA(39) - PG 12 Functions for partitionsSQLFunction
- V$RMAN_BACKUP_JOB_DETAILSAI
- angular4 反向代理detailsAngularAI
- Using Statspack to Record Explain Plan DetailsAI
- MySQL5.6 新效能之二(exchange partitions)MySql
- Some indexes or index partitions of table have been marked unusableIndex
- AAPT2 error: check logs for detailsAPTErrorAI
- Oracle Clusterware Software Component Processing DetailsOracleAI
- SEGMENT SHRINK and Details. (文件 ID 242090.1)AI
- Oracle11g維護分割槽(八)——Renaming PartitionsOracle
- Oracle11g維護分割槽(四)——Exchanging PartitionsOracle
- Oracle11g維護分割槽(二)——Coalescing PartitionsOracle
- Oracle11g維護分割槽(三)——Dropping PartitionsOracle
- SAP Cloud for Customer Account和individual customer的區別Cloud
- http://blog.csdn.net/blwinner/article/details/53637932HTTPAI
- 三個不常用的HTML元素:<details>、<summary>、<dialog>HTMLAI
- ASP.NET MVC 5 - 查詢Details和Delete方法ASP.NETMVCAIdelete
- Please Check VKTM Trace File for More Details (文件 ID 1347586.1)AI
- Oracle分割槽表基礎運維-08Coalescing PartitionsOracle運維
- Oracle 19c Concepts(04):Partitions, Views, and Other Schema ObjectsOracleViewObject
- Oracle11g維護分割槽(九)——Truncatinging PartitionsOracle
- Oracle11g維護分割槽(五)——Merging PartitionsOracle
- Oracle11g維護分割槽(一)——Adding PartitionsOracle
- http://blog.csdn.net/buoll/article/details/54150865HTTPAI
- 如何為Kafka叢集選擇合適的Topic/Partitions數量Kafka