[Buildroot] Creating a bootable filesystem image?

Guillaume Dargaud dargaud at lpsc.in2p3.fr
Tue Apr 15 08:35:36 UTC 2008


I normally just use dd to transfer the filesystem image onto a larger one.
Say you have /dev/sdc2 which is 500Mb and rootfs.powerpc.ext2 which is 10Mb 
like in my case. I just do
dd if=rootfs.powerpc.ext2 of=/dev/sdc2

There may be some hidden problems with that, but I never ran into them. Even 
a subsequent chkdsk runs without errors (you'd assume it would at least tell 
you the free space is missreported).

If you really want an ext2 at a specific size, just do the opposite:
dd if=/dev/sdc2 of=- | bzip2 > test.ext2.bz2

You may be able to use a loopback mount to do this, but I haven't tried it.
-- 
Guillaume Dargaud
http://www.gdargaud.net/





More information about the buildroot mailing list