@@ -1263,6 +1266,29 @@ class XFS(FS):
argv.extend([label, self.device])
return argv
+ def sync(self, root='/'):
+ """ Ensure that data we've written is at least in the journal.
+
+ This is a little odd because xfs_freeze will only be
+ available under the install root.
+ """
+ if not self.status or not self._mountpoint.startswith(root):
+ return
+
+ try:
+ iutil.execWithRedirect("xfs_freeze", ["-f", self.mountpoint],
+ stdout="/dev/tty5", stderr="/dev/tty5",
+ root=root)
+ except (RuntimeError, OSError) as e:
+ log.error("failed to run xfs_freeze: %s" % e)
+
+ try:
+ iutil.execWithRedirect("xfs_freeze", ["-u", self.mountpoint],
+ stdout="/dev/tty5", stderr="/dev/tty5",
+ root=root)
+ except (RuntimeError, OSError) as e:
+ log.error("failed to run xfs_freeze: %s" % e)
+
register_device_format(XFS)
--
1.7.3.4
_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list