Quantcast
Channel: Processors forum - Recent Threads
Viewing all articles
Browse latest Browse all 17527

Linux: Relation between eMMC Flash partition size and squash rootfs size

$
0
0

Tool/software: Linux

Hi All,

I would like to understand partition size with respect to rootfs size.

My device has 128 MB eMMC Flash and which has partationed as below.

/ # fdisk -l

Disk /dev/mmcblk0: 116 MB, 116523008 bytes
4 heads, 16 sectors/track, 3556 cylinders
Units = cylinders of 64 * 512 = 32768 bytes

Device Boot Start End Blocks Id System
/dev/mmcblk0p1 73 200 4096 83 Linux
/dev/mmcblk0p2 201 328 4096 83 Linux
/dev/mmcblk0p3 329 872 17408 83 Linux
/dev/mmcblk0p4 873 3556 85888 5 Extended
/dev/mmcblk0p5 877 1420 17408 83 Linux
/dev/mmcblk0p6 1425 1488 2048 83 Linux
/dev/mmcblk0p7 1493 1556 2048 83 Linux
/dev/mmcblk0p8 1573 1668 3072 83 Linux
/dev/mmcblk0p9 1673 1768 3072 83 Linux
/dev/mmcblk0p10 1773 1836 2048 83 Linux
/dev/mmcblk0p11 1841 1904 2048 83 Linux
/dev/mmcblk0p12 1909 2196 9216 83 Linux
/dev/mmcblk0p13 2201 2488 9216 83 Linux
/dev/mmcblk0p14 2493 2940 14336 83 Linux
/dev/mmcblk0p15 2945 3392 14336 83 Linux


/ # df -h
Filesystem Size Used Available Use% Mounted on
/dev/root 7.8M 7.8M 0 100% /
devtmpfs 121.9M 4.0K 121.9M 0% /dev
tmpfs 122.0M 140.0K 121.9M 0% /run
tmpfs 122.0M 0 122.0M 0% /fss
tmpfs 122.0M 2.9M 119.1M 2% /tmp
tmpfs 2.0M 192.0K 1.8M 9% /rdklogs
tmpfs 2.0M 0 2.0M 0% /minidumps
tmpfs 2.0M 0 2.0M 0% /telemetry

1) From above command found that /dev/root rootfs size is 7.8 MB which is based on squashfs.

2) While checking, entire rootfs size using du command which returns 122 MB.

# du -sh /
121.4M /

3) # fdisk /dev/mmcblk0p12
Device contains neither a valid DOS partition table, nor Sun, SGI, OSF or GPT disklabel
Building a new DOS disklabel. Changes will remain in memory only,
until you decide to write them. After that the previous content
won't be recoverable.


Command (m for help): p

Disk /dev/mmcblk0p12: 9 MB, 9437184 bytes
4 heads, 16 sectors/track, 288 cylinders
Units = cylinders of 64 * 512 = 32768 bytes


cat /proc/cmdline
root=/dev/mmcblk0p12 rootwait ro console=ttyS0,115200n8

My query :

1) How does entire rootfs size is 122 MB when /dev/root size 7.8M

2) Please clarify relation between du -sh / (122 MB) and /dev/root size 7.8M

/ # mount
rootfs on / type rootfs (rw)
/dev/root on / type squashfs (ro,relatime)
devtmpfs on /dev type devtmpfs (rw,relatime,size=124856k,nr_inodes=31214,mode=755)
proc on /proc type proc (rw,relatime)
devpts on /dev/pts type devpts (rw,relatime,gid=5,mode=620)
tmpfs on /run type tmpfs (rw,nosuid,nodev,mode=755)
sysfs on /sys type sysfs (rw,relatime)
tmpfs on /fss type tmpfs (rw,relatime)
tmpfs on /tmp type tmpfs (rw,relatime)
tmpfs on /rdklogs type tmpfs (rw,relatime,size=2048k)
tmpfs on /minidumps type tmpfs (rw,relatime,size=2048k)
tmpfs on /telemetry type tmpfs (rw,relatime,size=2048k)

Thanks

Murali.S


Viewing all articles
Browse latest Browse all 17527

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>