|
From: <di...@us...> - 2011-10-20 14:42:21
|
Revision: 765
http://safekeep.svn.sourceforge.net/safekeep/?rev=765&view=rev
Author: dimi
Date: 2011-10-20 14:42:14 +0000 (Thu, 20 Oct 2011)
Log Message:
-----------
Frank Crawford <fr...@cr...>
More reliable snapshot removal.
Modified Paths:
--------------
safekeep/trunk/safekeep
Modified: safekeep/trunk/safekeep
===================================================================
--- safekeep/trunk/safekeep 2011-10-16 15:40:41 UTC (rev 764)
+++ safekeep/trunk/safekeep 2011-10-20 14:42:14 UTC (rev 765)
@@ -645,9 +645,13 @@
lvmdev = device;
else:
lvmdev = '/dev/mapper/%s-%s' % (group, volume.replace('-', '--'))
- ret = spawn(['dmsetup', 'remove', lvmdev])
- ret = spawn(['dmsetup', 'remove', lvmdev + '-cow'])
- ret = spawn(['lvremove', '--force', device])
+ for i in range(1,10):
+ ret = spawn(['sync'])
+ ret = spawn(['dmsetup', 'remove', lvmdev])
+ ret = spawn(['dmsetup', 'remove', lvmdev + '-cow'])
+ ret = spawn(['lvremove', '--force', device])
+ if not ret:
+ break
return ret
def gather_snap_information(device, bdir):
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|