OpenWrt Forum Archive

Topic: default partitioning?

The content of this topic has been archived on 20 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Hi,

I've searched the forum to look for some guide lines about partitioning flash for OpenWrt.
I'm trying to get my AT91SAM9260-EK dev board running OpenWrt.
I already succeeded to boot with jffs2 filesystem.
But I do not understand the partitioning scheme very well.
Can someone point me to some good explanations of partitions used and for which filesystem? And how they should be sized (relative).
What does rootfs_data do and how this works with squashfs ???
Some partitioning rules and explanations would be appreciated.

As soon I have my port working properly, I'll post it.

BTW: I had to change the image.mk include file in order to set the right jffs2 page and erease size for my AT45 SPI flash. Is it possible someone makes this configurable in OpenWrt menuconfig?

Kind regards

Bart

I am using an AsusGL500gP.  Your board is not a router/gateway without wifi, so it is quite atypical from what most of us are trying to achieve.  I am not sure you have to provide more than one partition for the flash. What would be the advantage? Is there a need due to the memory structure of your unit?

Try Wikipedia to get a quick start with squashfs.  From what I understand is OpenWrt stores a boot image at RO and it is copied into RAM for actual use. As I reside in Taiwan, I rely heavily on Wikipedia and OReily books to get answers as diverse issues keep popping up as one gets into this.  Wikipedia will help you learn quickly.

Before you even consider partitioning, you should be looking at required mount points.  I suspect that further partitioning is unnecessary.

You may be confused by discussions of outboard mass storage expansion, like USBsticks or USB HDD. If you have USB HDD there may be advantages to having multiple partitions.  In particular, one might provide a swap partition.  But with solid-state memory, a swap partition is said to actually shorten the life of the memory.

I am trying to decide on partitioning for a 160Gbyte external HDD.  It seems to me that it is a good idea to have smaller partitions as it takes several hours to run fschk of the one big partition due to the small ram and slower clock rate.  It even takes hours on a desktop PC.  So I am considering nothing bigger than 20Gbyte.  And if at startup a partition is going to run fschk, much smaller than that would be wise -- maybe 1Gbyte or less.  You could wait for hours before a complete boot.

At this point, I am still trying to understand how to usefully configure the mount points.  I am not in a rush, but I'd like to have a system that allows most of the changes occuring on the HDD rather than internal firmware.  I suspect that flashing the firmware repeatedly is going to shorten the life of the router.

The discussion might have continued from here.