Displaying 3 results from an estimated 3 matches for "get_root_uuid_with_file".
2020 Aug 13
2
[PATCH v3] appliance: extract UUID from QCOW2 disk image
...x fbeb4f4..e088fc0 100644
--- a/lib/appliance-kcmdline.c
+++ b/lib/appliance-kcmdline.c
@@ -71,7 +71,7 @@ read_uuid (guestfs_h *g, void *retv, const char *line, size_t len)
* The L<file(1)> command does the hard work.
*/
static char *
-get_root_uuid (guestfs_h *g, const char *appliance)
+get_root_uuid_with_file (guestfs_h *g, const char *appliance)
{
CLEANUP_CMD_CLOSE struct command *cmd = guestfs_int_new_command (g);
char *ret = NULL;
@@ -96,6 +96,72 @@ get_root_uuid (guestfs_h *g, const char *appliance)
}
/**
+ * Read the first 256k bytes of the in_file with L<qemu-img(1)> command
+ * a...
2020 Aug 13
0
Re: [PATCH v3] appliance: extract UUID from QCOW2 disk image
.../appliance-kcmdline.c
> +++ b/lib/appliance-kcmdline.c
> @@ -71,7 +71,7 @@ read_uuid (guestfs_h *g, void *retv, const char *line, size_t len)
> * The L<file(1)> command does the hard work.
> */
> static char *
> -get_root_uuid (guestfs_h *g, const char *appliance)
> +get_root_uuid_with_file (guestfs_h *g, const char *appliance)
> {
> CLEANUP_CMD_CLOSE struct command *cmd = guestfs_int_new_command (g);
> char *ret = NULL;
> @@ -96,6 +96,72 @@ get_root_uuid (guestfs_h *g, const char *appliance)
> }
>
> /**
> + * Read the first 256k bytes of the in_file...
2020 Aug 12
2
[PATCH v2] appliance: extract UUID from QCOW2 disk image
For the appliance of the QCOW2 format, get the UUID of the disk by
reading the first 256k bytes with 'qemu-img dd' command. Then pass the
read block to the 'file' command. In case of failure, run the 'file'
command again directly.
Suggested-by: Denis V. Lunev <den@openvz.org>
Signed-off-by: Andrey Shinkevich <andrey.shinkevich@virtuozzo.com>
---
v2:
01: The