search for: disk_label

Displaying 20 results from an estimated 41 matches for "disk_label".

2014 Mar 12
3
Re: [PATCH v2 03/18] New API parameter: Add discard parameter to guestfs_add_drive_opts.
...src/drives.c > +++ b/src/drives.c > @@ -115,7 +115,8 @@ static struct drive * > create_drive_file (guestfs_h *g, const char *path, > bool readonly, const char *format, > const char *iface, const char *name, > - const char *disk_label, const char *cachemode) > + const char *disk_label, const char *cachemode, > + enum discard discard) > { > struct drive *drv = safe_calloc (g, 1, sizeof *drv); > (and others) It seems like these functions, albeit internal and private to this...
2014 Mar 10
5
[PATCH 0/3] Add discard support.
These patches contain the beginnings of discard (a.k.a. trim or unmap) support. This will allow us to change virt-sparsify to work on disk images in-place (instead of using slow & inefficient copying). The approach used is to add an optional 'discard' parameter to add-drive. It has 3 possible settings: - 'disable' : the default, no discard is done - 'besteffort' :
2013 Mar 15
0
[PATCH] lib: Add direct support for the NBD (Network Block Device) protocol.
...@@ -41,21 +43,51 @@ /* Create and free the 'drive' struct. */ static struct drive * -create_drive_struct (guestfs_h *g, const char *path, - bool readonly, const char *format, - const char *iface, const char *name, - const char *disk_label, - bool use_cache_none) +create_drive_file (guestfs_h *g, const char *path, + bool readonly, const char *format, + const char *iface, const char *name, + const char *disk_label, + bool use_cache_none) {...
2013 Apr 05
3
[PATCH] Add support for SSH (Secure Shell) block device.
Note this patch requires a non-upstream qemu patch that I've been experimenting with. See qemu-devel list. Rich.
2013 May 07
7
[PATCH 0/5] rbd improvements
This series improves ceph rbd support in libguestfs. It uses the servers list, adds support for a custom username, and starts to add support for custom secret.
2014 Mar 11
21
[PATCH v2 00/18] Add discard support.
This still isn't working at the moment. See: http://marc.info/?t=139457409300003&r=1&w=2 This set of patches: - Adds new APIs to support discard in libguestfs. - Adds discard support to virt-format. - Adds discard support to virt-sysprep. - Implements virt-sparsify --in-place. Rich.
2017 Sep 12
1
Re: [PATCH v2 5/5] launch: direct: Disable qemu locking when opening drives readonly (RHBZ#1417306).
...("file=%s", drv->overlay); > + append_list_format ("file.file.filename=%s", drv->overlay); > + append_list ("file.driver=qcow2"); > append_list ("cache=unsafe"); > - append_list ("format=qcow2"); > if (drv->disk_label) > append_list_format ("serial=%s", drv->disk_label); > + if (data->qemu_mandatory_locking) > + append_list ("file.backing.file.locking=off"); > } The same ought to be done for the appliance drive too. -- Pino Toscano
2018 Jan 17
1
[PATCH] launch: direct: Use old-style file= and format= parameters when not disabling locking (RHBZ#1503497).
...struct backend_direct_data *data, } else { /* Writable qcow2 overlay on top of read-only drive. */ - append_list_format ("file.file.filename=%s", drv->overlay); - append_list ("file.driver=qcow2"); - append_list ("cache=unsafe"); - if (drv->disk_label) - append_list_format ("serial=%s", drv->disk_label); - - /* Add the file-specific locking option only for files, as qemu - * won't accept options unknown to the block driver in use. - */ - if (data->qemu_mandatory_locking && drv->src.protocol == dr...
2012 Oct 08
3
[PATCH v3 0/3] Add support for disk labels and hotplugging.
This is, I guess, version 3 of this patch series which adds disk labels and hotplugging (only hot-add implemented so far). The good news is .. it works! Rich.
2009 Sep 14
2
[PATCH node-image] add livecd-iso-to-iscsi script to support iscsi root booting setup
...ot;) +parser.add_option("--reverse_password", dest="reverse_password", help="Reverse CHAP password(optional)") +parser.add_option("--disk", dest="disk", help="iSCSI disk device name") +parser.add_option("--disk-label", dest="disk_label", default="ovirt-node-root", help="file system label") + +(options, args) = parser.parse_args() + +def fail(msg): + print(msg) + sys.exit(1) + +if os.geteuid () != 0: + fail("You must run as root") + +if options.iso is None: + fail("ERROR: iso fil...
2013 Feb 28
7
[PATCH 0/7] Fix SELinux security contexts so we can access shared disks (RHBZ#912499).
https://bugzilla.redhat.com/show_bug.cgi?id=912499 (especially comments 7 & 10) This patch set is the final fix so that we can access disks in use by other guests when SELinux and sVirt are enabled. Previously such disks were inaccessible because sVirt labels the disks with a random SELinux label to prevent other instances of qemu from being able to read them. So naturally the libguestfs
2018 Nov 02
0
[PATCH v3 4/4] lib, p2v: Use single_element() macro where possible.
...string (QEMU); - } end_element (); - } + else + single_element ("emulator", QEMU); #endif /* Add a random number generator (backend for virtio-rng). This @@ -1533,11 +1501,8 @@ construct_libvirt_xml_disk (guestfs_h *g, return -1; } - if (drv->disk_label) { - start_element ("serial") { - string (drv->disk_label); - } end_element (); - } + if (drv->disk_label) + single_element ("serial", drv->disk_label); if (construct_libvirt_xml_disk_address (g, xo, drv_index) == -1) return -1;...
2012 Oct 08
5
[PATCH v4 0/5] Finish hotplugging support.
This rounds off hotplugging support by allowing you to add and remove drives at any stage (before and after launch). Rich.
2014 Jan 16
3
[PATCH 0/2] Don't use snapshot=on
QEMU upstream has broken snapshot=on ... again. These two patches stop using it entirely. Instead we run 'qemu-img create' to create overlay disks as required. Note that the libvirt and UML backends were already doing this: The libvirt backend because <transient/> has never worked, and the UML backend was running uml_mkcow because the UML-equivalent syntax of snapshot=on was
2019 Oct 29
2
[PATCH] fish: add option --blocksize for disks
...tart_list ("-device") { append_list ("scsi-hd"); append_list_format ("drive=hd%zu", i); + append_list_format ("physical_block_size=%d", blocksize); + append_list_format ("logical_block_size=%d", blocksize); if (drv->disk_label) append_list_format ("serial=%s", drv->disk_label); } end_list (); -- 2.21.0
2016 Dec 24
0
[PATCH] lib: Use a common function to validate strings.
...true, true, "-_") /** * Check the disk label is reasonable. It can't contain certain * characters, eg. C<'/'>, C<','>. However be stricter here and * ensure it's just alphabetic and E<le> 20 characters in length. */ -static int -valid_disk_label (const char *str) -{ - size_t len = strlen (str); - - if (len == 0 || len > 20) - return 0; - - while (len > 0) { - char c = *str++; - len--; - if (!c_isalpha (c)) - return 0; - } - return 1; -} +#define VALID_DISK_LABEL(str) \ + guestfs_int_string_is_valid ((str), 1, 2...
2020 Feb 10
0
Re: [RFC] lib: allow to specify physical/logical block size for disks
...add_drive (guestfs_h *g, struct backend_direct_data *data, > struct qemuopts *qopts, size_t i, struct drive *drv) > @@ -291,6 +311,8 @@ add_drive (guestfs_h *g, struct backend_direct_data *data, > append_list_format ("drive=hd%zu", i); > if (drv->disk_label) > append_list_format ("serial=%s", drv->disk_label); > + if (add_device_blockio_params (g, qopts, drv) == -1) > + return -1; > } end_list (); > } > #if defined(__arm__) || defined(__aarch64__) || defined(__powerpc__) > @@ -317,6 +339,...
2016 Dec 24
2
[PATCH] lib: Use a common function to validate strings.
As discussed in the thread on validating $TERM, it would be good to have a common function to do this. This is such a function. The main advantage is it includes unit tests which the previous functions did not. Rich.
2017 Sep 12
0
[PATCH v2 5/5] launch: direct: Disable qemu locking when opening drives readonly (RHBZ#1417306).
...- append_list_format ("file=%s", drv->overlay); + append_list_format ("file.file.filename=%s", drv->overlay); + append_list ("file.driver=qcow2"); append_list ("cache=unsafe"); - append_list ("format=qcow2"); if (drv->disk_label) append_list_format ("serial=%s", drv->disk_label); + if (data->qemu_mandatory_locking) + append_list ("file.backing.file.locking=off"); } append_list_format ("id=hd%zu", i); @@ -408,6 +411,10 @@ launch_direct (guestfs_h *g, void *datav, co...
2017 Nov 23
0
[PATCH] launch: direct: Omit locking option for non-file disks (RHBZ#1516094)
...--git a/lib/launch-direct.c b/lib/launch-direct.c index 87ac121c7558..678c8c68d59d 100644 --- a/lib/launch-direct.c +++ b/lib/launch-direct.c @@ -260,7 +260,11 @@ add_drive_standard_params (guestfs_h *g, struct backend_direct_data *data, append_list ("cache=unsafe"); if (drv->disk_label) append_list_format ("serial=%s", drv->disk_label); - if (data->qemu_mandatory_locking) + + /* Add the file-specific locking option only for files, as qemu + * won't accept options unknown to the block driver in use. + */ + if (data->qemu_mandatory_loc...