storage/reflink: delete all images at beginning of create()
Ensure that there are no leftover image files for the volume, e.g. from an unsuccessful removal of a previous incarnation of this vid, or from an messily restored pool filesystem backup. We don't want to preserve any stale data (revisions) or metadata (size) in the new incarnation.
This commit is contained in:
parent
56f6a6ef65
commit
6659ed8d39
@ -154,6 +154,7 @@ class ReflinkVolume(qubes.storage.Volume):
|
||||
@_coroutinized
|
||||
@_locked
|
||||
def create(self):
|
||||
self._remove_all_images()
|
||||
if self.save_on_stop and not self.snap_on_start:
|
||||
_create_sparse_file(self._path_clean, self._get_size())
|
||||
return self
|
||||
|
Loading…
Reference in New Issue
Block a user