search for: add_drive_standard_param

Displaying 15 results from an estimated 15 matches for "add_drive_standard_param".

2017 Sep 05
4
[PATCH] lib: direct: Disable qemu locking when opening drives
Incomplete fix for https://bugzilla.redhat.com/show_bug.cgi?id=1417306 The full fix is waiting for a libvirt change, but this can still go upstream. Rich.
2017 Sep 12
1
Re: [PATCH v2 5/5] launch: direct: Disable qemu locking when opening drives readonly (RHBZ#1417306).
On Tuesday, 12 September 2017 14:29:16 CEST Richard W.M. Jones wrote: > @@ -255,11 +256,13 @@ add_drive_standard_params (guestfs_h *g, struct backend_direct_data *data, > } > else { > /* Writable qcow2 overlay on top of read-only drive. */ > - append_list_format ("file=%s", drv->overlay); > + append_list_format ("file.file.filename=%s", drv->overlay); > +...
2017 Sep 05
1
Re: [PATCH] lib: direct: Disable qemu locking when opening drives readonly.
...last paragraph? > lib/launch-direct.c | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/lib/launch-direct.c b/lib/launch-direct.c > index 3b848165c..e5465539d 100644 > --- a/lib/launch-direct.c > +++ b/lib/launch-direct.c > @@ -221,8 +221,11 @@ add_drive_standard_params (guestfs_h *g, struct backend_direct_data *data, > file = guestfs_int_drive_source_qemu_param (g, &drv->src); > append_list_format ("file=%s", file); > > - if (drv->readonly) > + if (drv->readonly) { > append_list ("snapshot=on...
2017 Sep 05
0
[PATCH] lib: direct: Disable qemu locking when opening drives readonly.
...r https://bugzilla.redhat.com/show_bug.cgi?id=1417306 --- lib/launch-direct.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/launch-direct.c b/lib/launch-direct.c index 3b848165c..e5465539d 100644 --- a/lib/launch-direct.c +++ b/lib/launch-direct.c @@ -221,8 +221,11 @@ add_drive_standard_params (guestfs_h *g, struct backend_direct_data *data, file = guestfs_int_drive_source_qemu_param (g, &drv->src); append_list_format ("file=%s", file); - if (drv->readonly) + if (drv->readonly) { append_list ("snapshot=on"); + if (guestfs_in...
2017 Sep 12
0
Re: [PATCH] lib: direct: Disable qemu locking when opening drives readonly.
...direct.c | 5 ++++- > > 1 file changed, 4 insertions(+), 1 deletion(-) > > > > diff --git a/lib/launch-direct.c b/lib/launch-direct.c > > index 3b848165c..e5465539d 100644 > > --- a/lib/launch-direct.c > > +++ b/lib/launch-direct.c > > @@ -221,8 +221,11 @@ add_drive_standard_params (guestfs_h *g, struct backend_direct_data *data, > > file = guestfs_int_drive_source_qemu_param (g, &drv->src); > > append_list_format ("file=%s", file); > > > > - if (drv->readonly) > > + if (drv->readonly) { > >...
2017 Sep 12
0
[PATCH v2 5/5] launch: direct: Disable qemu locking when opening drives readonly (RHBZ#1417306).
...ct version qemu_version; /* qemu version (0 if unable to parse). */ + int qemu_mandatory_locking; /* qemu >= 2.10 does mandatory locking */ struct qemu_data *qemu_data; /* qemu -help output etc. */ char guestfsd_sock[UNIX_PATH_MAX]; /* Path to daemon socket. */ @@ -255,11 +256,13 @@ add_drive_standard_params (guestfs_h *g, struct backend_direct_data *data, } else { /* Writable qcow2 overlay on top of read-only drive. */ - append_list_format ("file=%s", drv->overlay); + append_list_format ("file.file.filename=%s", drv->overlay); + append_list ("file.dr...
2017 Nov 23
0
[PATCH] launch: direct: Omit locking option for non-file disks (RHBZ#1516094)
...Signed-off-by: Lars Seipel <ls@slrz.net> --- lib/launch-direct.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --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,...
2018 Jan 17
1
[PATCH] launch: direct: Use old-style file= and format= parameters when not disabling locking (RHBZ#1503497).
...i Guo, Václav Kadlčík. --- lib/launch-direct.c | 31 +++++++++++++++++++++---------- 1 file changed, 21 insertions(+), 10 deletions(-) diff --git a/lib/launch-direct.c b/lib/launch-direct.c index aa4139359..47e8f37de 100644 --- a/lib/launch-direct.c +++ b/lib/launch-direct.c @@ -255,17 +255,28 @@ add_drive_standard_params (guestfs_h *g, 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");...
2020 Feb 10
0
Re: [RFC] lib: allow to specify physical/logical block size for disks
...int pblocksize; > + int lblocksize; > }; > > /* Extra hv parameters (from guestfs_config). */ > diff --git a/lib/launch-direct.c b/lib/launch-direct.c > index ae6ca093b..518bd24fc 100644 > --- a/lib/launch-direct.c > +++ b/lib/launch-direct.c > @@ -273,6 +273,26 @@ add_drive_standard_params (guestfs_h *g, struct backend_direct_data *data, > return -1; > } > > +/** > + * Add the blockio elements of the C<-device> parameter. > + */ > +static int > +add_device_blockio_params (guestfs_h *g, struct qemuopts *qopts, > + struc...
2020 Feb 07
8
[RFC] lib: allow to specify physical/logical block size for disks
...enum discard discard; bool copyonread; + int pblocksize; + int lblocksize; }; /* Extra hv parameters (from guestfs_config). */ diff --git a/lib/launch-direct.c b/lib/launch-direct.c index ae6ca093b..518bd24fc 100644 --- a/lib/launch-direct.c +++ b/lib/launch-direct.c @@ -273,6 +273,26 @@ add_drive_standard_params (guestfs_h *g, struct backend_direct_data *data, return -1; } +/** + * Add the blockio elements of the C<-device> parameter. + */ +static int +add_device_blockio_params (guestfs_h *g, struct qemuopts *qopts, + struct drive *drv) +{ + if (drv->pblocksize) +...
2017 Apr 27
4
[PATCH 0/4] common: Add a simple mini-library for handling qemu command and config files.
Currently we have an OCaml library for generating the qemu command line (used only by ‘virt-v2v -o qemu’). However we also generate a qemu command line in ‘lib/launch-direct.c’, and we might in future need to generate a ‘-readconfig’-compatible configuration file if we want to go beyond 10,000 drives for scalability testing. Therefore this patch series reimplements the qemu command line code as
2017 Sep 12
9
[PATCH v2 0/5] launch: direct: Disable qemu locking when opening drives readonly (RHBZ#1417306)
Patches 1-4 are almost the same as they are when previously posted here: https://www.redhat.com/archives/libguestfs/2017-September/msg00039.html Patch 5 actually uses the mandatory locking test to turn off locking in the narrow case where a drive is opened readonly, and then only for the drive being inspected. Passes ordinary tests (‘check-direct’ and ‘check-valgrind-direct’). Rich.
2020 Feb 11
2
[PATCH v2] lib: add support for disks with 4096 bytes sector size
...char *cachemode; enum discard discard; bool copyonread; + int blocksize; }; /* Extra hv parameters (from guestfs_config). */ diff --git a/lib/launch-direct.c b/lib/launch-direct.c index ae6ca093b..0f4bbf15f 100644 --- a/lib/launch-direct.c +++ b/lib/launch-direct.c @@ -273,6 +273,27 @@ add_drive_standard_params (guestfs_h *g, struct backend_direct_data *data, return -1; } +/** + * Add the physical_block_size and logical_block_size elements of the C<-device> + * parameter. + */ +static int +add_device_blocksize_params (guestfs_h *g, struct qemuopts *qopts, + struct dr...
2020 Feb 10
1
[PATCH] lib: allow to specify physical/logical block size for disks
...char *cachemode; enum discard discard; bool copyonread; + int blocksize; }; /* Extra hv parameters (from guestfs_config). */ diff --git a/lib/launch-direct.c b/lib/launch-direct.c index ae6ca093b..0f4bbf15f 100644 --- a/lib/launch-direct.c +++ b/lib/launch-direct.c @@ -273,6 +273,27 @@ add_drive_standard_params (guestfs_h *g, struct backend_direct_data *data, return -1; } +/** + * Add the physical_block_size and logical_block_size elements of the C<-device> + * parameter. + */ +static int +add_device_blocksize_params (guestfs_h *g, struct qemuopts *qopts, + struct dr...
2017 Sep 12
8
[PATCH v3 0/6] launch: direct: Disable qemu locking when opening drives readonly.
v2 -> v3: - I addressed everything that Pino mentioned last time. - It's tricky to get a stable run when multiple copies of qemu are involved, because the same cache files get overwritten by parallel libguestfs. So I changed the names of the cache files to include the qemu binary key (size, mtime), which removes this conflict. This is in new patch 4/6. Rich.