@@ -44,7 +44,9 @@ def add_entry_to_filesystem_table(host, mount_name)
4444 # Note: /dev/hd8 is the default jfs logging device on AIX.
4545 on ( host , "echo '/#{ mount_name } :\n dev = /dev/#{ mount_name } \n vfs = #{ fs_type } \n log = /dev/hd8' >> #{ fs_file } " )
4646 when %r{el-|centos|fedora|sles|debian|ubuntu|cumulus}
47- on ( host , "echo '/tmp/#{ mount_name } /#{ mount_name } #{ fs_type } loop 0 0' >> #{ fs_file } " )
47+ # Correctly munge whitespaces in mountpoints
48+ munged_mount_name = mount_name . gsub ( ' ' , '\\\040' )
49+ on ( host , "echo '/tmp/#{ munged_mount_name } /#{ munged_mount_name } #{ fs_type } loop 0 0' >> #{ fs_file } " )
4850 else
4951 # TODO: Add Solaris and OSX support, as per PUP-5201 and PUP-4823
5052 fail_test ( "Adding entries to the filesystem table on #{ host [ 'platform' ] } is not currently supported." )
@@ -63,8 +65,8 @@ def create_filesystem(host, mount_name)
6365 on ( host , "mklv -y #{ mount_name } #{ volume_group } 1M" )
6466 on ( host , "mkfs -V #{ fs_type } -l #{ mount_name } /dev/#{ mount_name } " )
6567 when %r{el-|centos|fedora|sles|debian|ubuntu|cumulus}
66- on ( host , "dd if=/dev/zero of=/tmp/#{ mount_name } count=10240" , acceptable_exit_codes : [ 0 , 1 ] )
67- on ( host , "yes | mkfs -t #{ fs_type } -q /tmp/#{ mount_name } " , acceptable_exit_codes : ( 0 ..254 ) )
68+ on ( host , "dd if=/dev/zero of=' /tmp/#{ mount_name } ' count=10240" , acceptable_exit_codes : [ 0 , 1 ] )
69+ on ( host , "yes | mkfs -t #{ fs_type } -q ' /tmp/#{ mount_name } ' " , acceptable_exit_codes : ( 0 ..254 ) )
6870 else
6971 # TODO: Add Solaris and OSX support, as per PUP-5201 and PUP-4823
7072 fail_test ( "Creating filesystems on #{ host [ 'platform' ] } is not currently supported." )
0 commit comments