mirror of
https://github.com/valitydev/salt.git
synced 2024-11-09 01:36:48 +00:00
Issue #20235: blockdev.format fails when succeeding
After a mkfs is issued, an immediate lsblk will show the device as unformatted. Issuing a sync before lsblk will allow the check to succeed.
This commit is contained in:
parent
34e0cab774
commit
9ea76ed9c1
@ -130,6 +130,7 @@ def formatted(name, fs_type='ext4', **kwargs):
|
||||
cmd += '-i size={0} '.format(kwargs['inode_size'])
|
||||
cmd += name
|
||||
__salt__['cmd.run'](cmd).splitlines()
|
||||
__salt__['cmd.run']('sync').splitlines()
|
||||
blk = __salt__['cmd.run']('lsblk -o fstype {0}'.format(name)).splitlines()
|
||||
|
||||
if len(blk) == 1:
|
||||
|
Loading…
Reference in New Issue
Block a user