Improving CF-IDE boot times by using unsquashed fs

Help with booting MiniMyth

Moderator: Pablo

Post Reply
Bill
New Member
Posts: 4
Joined: Tue Nov 11, 2008 11:40 am

Improving CF-IDE boot times by using unsquashed fs

Post by Bill » Tue Nov 11, 2008 11:56 am

I am using an EPIA M1000 and I have noticed that the uncompressing root file system phase of the boot takes ~20 seconds. Seeing as there's plenty of space on the 2G CF card I'm using I thought it might be a neat way to speed the boot by unsquashing the file system off-line, copying the unsquashed files into a directory on the CF card and using these files instead of the squashed files ystem image.

I did have a go at running unsquashfs (as root) on a copy of the rootfs image on a different machine to see what would happen, but it generated loads of errors ('operation not permitted' if I remember rightly).

Would doing this right actually boot, or am I barking up the wrong tree?

Any tips on doing this would be gratefully received,
Cheers,

Bill.

Pablo
Site Admin
Posts: 4182
Joined: Tue Dec 14, 2004 2:13 am
Location: La Jolla
Contact:

Post by Pablo » Tue Nov 11, 2008 2:35 pm

20s sounds like a long time. Even on my VIA EPIA SP8000E, downloading and decompressing the squashfs root file system takes 10s. Therefore, I think a large portion of the 20s is CF access.

As for booting from an uncompressed image, that will take some work.

First, in order to mount the uncompressed root file system on the CF, the kernel must have access to all the kernel drivers needed to mount and read the file system. This means that the kernel needs the ATA driver (to use the the IDE interface) and the file system driver (to mount the file system). Neither are compiled into the kernel. Therefore, you would either need to recompile the kernel with these drivers compiled in or create an initrd with these drivers. By the way, the reason the squashfs image does not have this problem is that it is the initrd.

Second, you would want to format the CF as ext3 rather than vfat. Otherwise, you will not have any real file system access control.
MiniMyth running on an Acer ApireRevo 3610 and a Zotac ZBOX-ID80-U. Find out more at my MythTV page.

Bill
New Member
Posts: 4
Joined: Tue Nov 11, 2008 11:40 am

Post by Bill » Thu Nov 13, 2008 10:27 pm

Hi Pablo,

Thanks for the advice.

Bill.

Post Reply