[Libguestfs] PATCH: daemon mkfs.c Add option "inode" for setting -I flag on mkfs_opts command

Richard W.M. Jones rjones at redhat.com
Mon Jul 4 09:39:19 UTC 2011


On Mon, Jul 04, 2011 at 01:05:04PM +0400, Nikita A Menkovich wrote:
> Hello,
> 
> Patch implements inode option to mkfs_opts command.
> This is needed because older versions of grub(for example in centos)
> do not understand filesystems created with newer version of e2fsprogs.
> By default in e2fsprogs 1.4+ creates partitions with 256 bit inode
> size, and grub expect 128 bit size.
> Usage:
> $ guestfish
> ><fs> add-drive test.img 1G #for small images by default used 128 bit
> ><fs> run
> ><fs> part-disk /dev/vda mbr
> ><fs> mkfs ext3 /dev/vda1
> ><fs> tune2fs-l /dev/vda1 | grep "Inode size"
> Inode size: 256
> ><fs> mkfs-opts ext3 /dev/vda1 inode:128
> ><fs> tune2fs-l /dev/vda1 | grep "Inode size"
> Inode size: 128

Thanks, I have pushed the patch with a few adjustments:

http://git.annexia.org/?p=libguestfs.git;a=commitdiff;h=24fb2c1255f751dad98dd1739b3ed3a52ce06f70

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
libguestfs lets you edit virtual machines.  Supports shell scripting,
bindings from many languages.  http://libguestfs.org




More information about the Libguestfs mailing list