Commit e64a5809 authored by Thibault VINCENT's avatar Thibault VINCENT
Browse files

fix: DM table change followed by a suspend/resume

parent 7913589d
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -242,11 +242,17 @@ class LVM(object):
        '''
        '''
        with self._mutex.write:
            rc = Exec.silent([self.DMSETUP,
            rc1 = Exec.silent([self.DMSETUP,
                              'load',
                              name],
                              input=table)
            if rc:
            rc2 = Exec.silent([self.DMSETUP,
                              'suspend',
                              name])
            rc3 = Exec.silent([self.DMSETUP,
                              'resume',
                              name])
            if rc1 or rc2 or rc3:
                raise LVMError('failed to change DM table')