[OpenWrt-Devel] Some standard partition name for extra user data?

John Crispin blogic at openwrt.org
Sun Dec 7 10:11:53 EST 2014



On 07/12/2014 16:05, Hauke Mehrtens wrote:
> On 12/07/2014 01:30 AM, Rafał Miłecki wrote:
>> I've bcm53xx device which has two usable flashes:
>> 1) SPI serial flash for CFE + firmware + NVRAM
>> 2) NAND flash for extra data
>>
>> Because of general design of OpenWrt firmware my image contains two
>> partitions: kernel and rootfs (SquashFS). Automatically rootfs_data
>> (JFFS2) is created right after rootfs.
>>
>> I wanted to make space on NAND flash also usable for OpenWrt. Do you
>> have any advice on that?
>>
>> 1) The coolest idea would be to use some LVM solution, but I don't
>> think we have anything like this ready in OpenWrt. Or do we? AFAIK UBI
>> itself can't work as LVM (can't use blocks from several MTD
>> partitions)?
>>
>> 2) So I was thinking about simply registering that NAND partition with
>> some name we could make common across OpenWrt targets. Something like
>> "extra_data" or whatever you prefer. User would need to mount it and
>> use a proper directory for storing his data. Is there anything like
>> this in any other target?
>>
>> Yet another solution could be to ignore this few MiB space on serial
>> flash and simply use NAND for rootfs_data. But this would:
>> 1) Waste some minor space on SPI serial flash
>> 2) Would require hacking partitioner to don't create rootfs_data
>> 3) Hacking UBI a bit I guess
>>
> Hi,
> 
> I assume these device are loading the kernel from serial flash by default.
> 
> Have you looked at extroot:
> http://wiki.openwrt.org/doc/howto/extroot
> This is used to place the root file system on an external storage.
> 
> Hauke

HI,

extroot is the wrong pattern for 2 flash setups.

>> 1) Waste some minor space on SPI serial flash
how big is spi / nand

>> 2) Would require hacking partitioner to don't create rootfs_data
huh ? ubifs ?

>> 3) Hacking UBI a bit I guess
sound like a wrong assumption no idea why you think ubi wont work on
your flash


	John


>>

> _______________________________________________
> openwrt-devel mailing list
> openwrt-devel at lists.openwrt.org
> https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
> 
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


More information about the openwrt-devel mailing list