Now that I installed LEDE I just figured out that this lede-build can just allocate 4MB of flash. As far as I know my device should have 8MB of flash. How can I find out the real size of flash?
In LuCi in the software tab there is written:
Free space: 89% (432.00 KB)
and running df -h
via ssh right after install:
Filesystem Size Used Available Use% Mounted on
/dev/root 2.3M 2.3M 0 100% /rom
tmpfs 14.1M 540.0K 13.5M 4% /tmp
tmpfs 14.1M 48.0K 14.0M 0% /tmp/root
tmpfs 512.0K 0 512.0K 0% /dev
/dev/mtdblock6 484.0K 52.0K 432.0K 11% /overlay
overlayfs:/overlay 484.0K 52.0K 432.0K 11% /
And more information I can not interpret: cat /proc/mtd
dev: size erasesize name
mtd0: 00030000 00001000 "u-boot"
mtd1: 00010000 00001000 "u-boot-env"
mtd2: 00010000 00001000 "factory"
mtd3: 003b0000 00001000 "firmware"
mtd4: 0011af62 00001000 "kernel"
mtd5: 0029509e 00001000 "rootfs"
mtd6: 00079000 00001000 "rootfs_data"
Question:
How can I check how much flash the device has in real?
How can I tell LEDE to use all of it?
You can look at the kernel log to see how the flash chip is detected and how the mtd partitions are detected.
dmesg | less
Two examples from different devices:
128 MB NAND flash found:
[ 1.131260] nand: device found, Manufacturer ID: 0x2c, Chip ID: 0xa1
[ 1.131295] nand: Micron MT29F1G08ABBEAH4
[ 1.137707] nand: 128 MiB, SLC, erase size: 128 KiB, page size: 2048, OOB size: 64
[ 1.141816] 10 ofpart partitions found on MTD device qcom_nand.0
[ 1.149079] Creating 10 MTD partitions on "qcom_nand.0":
[ 1.155332] 0x000000000000-0x000000c80000 : "qcadata"
[ 1.166108] random: fast init done
[ 1.179453] 0x000000c80000-0x000001180000 : "APPSBL"
[ 1.187852] 0x000001180000-0x000001200000 : "APPSBLENV"
[ 1.190446] 0x000001200000-0x000001340000 : "art"
[ 1.195397] 0x000001340000-0x000001480000 : "artbak"
[ 1.200419] 0x000001480000-0x000001680000 : "kernel"
[ 1.206441] 0x000001680000-0x000003480000 : "ubi"
[ 1.254675] 0x000003480000-0x000007900000 : "netgear"
[ 1.362556] 0x000007900000-0x000008000000 : "reserve"
[ 1.375174] 0x000001480000-0x000003480000 : "firmware"
[ 1.427692] no rootfs found after FIT image in "firmware"
8 MB flash detected
[ 2.986743] m25p80 spi0.0: found s25sl064p, expected m25p80
[ 2.992315] m25p80 spi0.0: s25sl064p (8192 Kbytes)
[ 2.997173] 4 cmdlinepart partitions found on MTD device spi0.0
[ 3.003078] Creating 4 MTD partitions on "spi0.0":
[ 3.007889] 0x000000000000-0x000000050000 : "u-boot"
[ 3.014710] 0x000000050000-0x000000070000 : "u-boot-env"
[ 3.021437] 0x000000070000-0x0000007f0000 : "firmware"
[ 3.033504] 2 netgear-fw partitions found on MTD device firmware
[ 3.039562] 0x000000070000-0x0000001b7440 : "kernel"
[ 3.045842] 0x0000001b7440-0x0000007f0000 : "rootfs"
[ 3.052120] mtd: device 4 (rootfs) set to be root filesystem
[ 3.057856] 1 squashfs-split partitions found on MTD device rootfs
[ 3.064026] 0x0000006b0000-0x0000007f0000 : "rootfs_data"
[ 3.070792] 0x0000007f0000-0x000000800000 : "art"
I guess I found it
[ 0.627169] spi spi0.0: force spi mode3
[ 0.635829] m25p80 spi0.0: pm25lq032 (4096 Kbytes)
[ 0.645579] 4 ofpart partitions found on MTD device spi0.0
[ 0.656564] Creating 4 MTD partitions on "spi0.0":
[ 0.666176] 0x000000000000-0x000000030000 : "u-boot"
[ 0.679792] 0x000000030000-0x000000040000 : "u-boot-env"
[ 0.694567] 0x000000040000-0x000000050000 : "factory"
[ 0.708638] 0x000000050000-0x000000400000 : "firmware"
[ 1.015178] 2 uimage-fw partitions found on MTD device firmware
[ 1.027115] 0x000000050000-0x00000016af62 : "kernel"
[ 1.040328] 0x00000016af62-0x000000400000 : "rootfs"
[ 1.054216] mtd: device 5 (rootfs) set to be root filesystem
[ 1.065834] 1 squashfs-split partitions found on MTD device rootfs
[ 1.078255] 0x000000387000-0x000000400000 : "rootfs_data"
just 4MB of flash Good to know! Thank's for your help!
Uqbar
May 2, 2017, 12:46pm
5
Well, for a project like this I would expect to have some details in the Status-->Overview web UI page.
I can see the amount of RAM, but cannot see the amount of total/available/free flash.
But this is just wishful thinking.
jow
May 2, 2017, 1:04pm
6
The amount of usable RAM is shown in the status overview page.