[libvirt] [PATCH 2/3] Format FS pools

Jim Fehlig jfehlig at novell.com
Sun Feb 21 22:40:35 UTC 2010


Daniel Veillard wrote:
> On Thu, Feb 18, 2010 at 05:58:06PM -0500, David Allan wrote:
>   
>> * If the user supplies the appropriate flag, create the filesystem on the partition used by the pool.
>> ---
>>  configure.ac                     |    5 +++++
>>  include/libvirt/libvirt.h.in     |    3 ++-
>>  src/storage/storage_backend_fs.c |   25 ++++++++++++++++++++++++-
>>  3 files changed, 31 insertions(+), 2 deletions(-)
>>
>> diff --git a/configure.ac b/configure.ac
>> index 743a357..616bd03 100644
>> --- a/configure.ac
>> +++ b/configure.ac
>> @@ -1252,12 +1252,15 @@ AM_CONDITIONAL([WITH_STORAGE_DIR], [test "$with_storage_dir" = "yes"])
>>  if test "$with_storage_fs" = "yes" -o "$with_storage_fs" = "check"; then
>>    AC_PATH_PROG([MOUNT], [mount], [], [$PATH:/sbin:/usr/sbin])
>>    AC_PATH_PROG([UMOUNT], [umount], [], [$PATH:/sbin:/usr/sbin])
>> +  AC_PATH_PROG([MKE2FS], [mke2fs], [], [$PATH:/sbin:/usr/sbin])
>>    if test "$with_storage_fs" = "yes" ; then
>>      if test -z "$MOUNT" ; then AC_MSG_ERROR([We need mount for FS storage driver]) ; fi
>>      if test -z "$UMOUNT" ; then AC_MSG_ERROR([We need umount for FS storage driver]) ; fi
>> +    if test -z "$MKE2FS" ; then AC_MSG_ERROR([We need mke2fs for FS storage driver]) ; fi
>>    else
>>      if test -z "$MOUNT" ; then with_storage_fs=no ; fi
>>      if test -z "$UMOUNT" ; then with_storage_fs=no ; fi
>> +    if test -z "$MKE2FS" ; then with_storage_fs=no ; fi
>>     
>
>   That's where things starts to be nasty, why ext2, and not say ext3,
> then someone surely will want ext4 or xfs :-)
> I'm afraid we probably need to implement those 4 and give them different
> enums (below).
>   

How about all file systems defined in virStoragePoolFormatFileSystem
that support formatting.

Regards,
Jim




More information about the libvir-list mailing list