summaryrefslogtreecommitdiffstats
path: root/sysprep/sysprep_operation_udev_persistent_net.ml
diff options
context:
space:
mode:
authorRichard W.M. Jones <rjones@redhat.com>2012-07-25 14:17:42 +0100
committerRichard W.M. Jones <rjones@redhat.com>2012-07-25 14:47:15 +0100
commit2b59b5f1d2e36b0ef84b7c7c9ab2c4b602f2ad91 (patch)
tree8aefb9bc2bfb2eee1f851bfdc4655e4dada14777 /sysprep/sysprep_operation_udev_persistent_net.ml
parent1fb95e65661f19c050b928694f750f2406eff2ac (diff)
downloadlibguestfs-2b59b5f1d2e36b0ef84b7c7c9ab2c4b602f2ad91.tar.gz
libguestfs-2b59b5f1d2e36b0ef84b7c7c9ab2c4b602f2ad91.tar.xz
libguestfs-2b59b5f1d2e36b0ef84b7c7c9ab2c4b602f2ad91.zip
sysprep: Change perform callback to perform_on_filesystems and perform_on_devices.
Operations that need to work directly on guest block devices will fail because the block devices are busy. Therefore add a phase with the filesystems unmounted, and allow operations to specify that they need to work in this phase.
Diffstat (limited to 'sysprep/sysprep_operation_udev_persistent_net.ml')
-rw-r--r--sysprep/sysprep_operation_udev_persistent_net.ml3
1 files changed, 2 insertions, 1 deletions
diff --git a/sysprep/sysprep_operation_udev_persistent_net.ml b/sysprep/sysprep_operation_udev_persistent_net.ml
index 6de2589e..6fd7d9e3 100644
--- a/sysprep/sysprep_operation_udev_persistent_net.ml
+++ b/sysprep/sysprep_operation_udev_persistent_net.ml
@@ -43,7 +43,8 @@ old MAC address occupies the old name (eg. eth0), this means the fresh
MAC address is assigned to a new name (eg. eth1) and this is usually
undesirable. Erasing the udev persistent net rules avoids this.");
extra_args = [];
- perform = udev_persistent_net_perform;
+ perform_on_filesystems = Some udev_persistent_net_perform;
+ perform_on_devices = None;
}
let () = register_operation udev_persistent_net_op