search for: for_each_disk

Displaying 17 results from an estimated 17 matches for "for_each_disk".

2016 Sep 20
1
[PATCH] libvirt: read disk paths from pools (RHBZ#1366049)
...ume' is stored as <source pool='pool_name' volume='volume_name'/> and its real location is inside the 'volume_name', as 'pool_name': in this case, query libvirt for the actual path of the specified volume in the specified pool. Adjust the code so that: - for_each_disk gets the virConnectPtr, needed to do operations with libvirt - when extracting the disk filename depending on the type, the code snippet doing it can directly set 'filename', without setting an XPath result variable Only file-based volumes are supported for now; more types can be add...
2016 Nov 16
3
[PATCH 1/2] libvirt: un-duplicate XPath code
...------ 1 file changed, 50 insertions(+), 72 deletions(-) diff --git a/src/libvirt-domain.c b/src/libvirt-domain.c index 4d4142d..baab307 100644 --- a/src/libvirt-domain.c +++ b/src/libvirt-domain.c @@ -43,6 +43,8 @@ static xmlDocPtr get_domain_xml (guestfs_h *g, virDomainPtr dom); static ssize_t for_each_disk (guestfs_h *g, virConnectPtr conn, xmlDocPtr doc, int (*f) (guestfs_h *g, const char *filename, const char *format, int readonly, const char *protocol, char *const *server, const char *username, void *data), void *data); static int libvirt_selinux_label (guestfs_h *g, xmlDocPtr doc, char **label_r...
2016 Sep 22
1
[PATCH v2] libvirt: read disk paths from pools (RHBZ#1366049)
...ume' is stored as <source pool='pool_name' volume='volume_name'/> and its real location is inside the 'volume_name', as 'pool_name': in this case, query libvirt for the actual path of the specified volume in the specified pool. Adjust the code so that: - for_each_disk gets the virConnectPtr, needed to do operations with libvirt - when extracting the disk filename depending on the type, the code snippet doing it can directly set 'filename', without setting an XPath result variable Only file-based volumes are supported for now; more types can be add...
2016 Nov 16
0
[PATCH 2/2] libvirt: read secrets of disks (RHBZ#1392798)
...l/tree.h> +#include "base64.h" + #include "guestfs.h" #include "guestfs-internal.h" #include "guestfs-internal-actions.h" @@ -40,7 +42,7 @@ #if defined(HAVE_LIBVIRT) static xmlDocPtr get_domain_xml (guestfs_h *g, virDomainPtr dom); -static ssize_t for_each_disk (guestfs_h *g, virConnectPtr conn, xmlDocPtr doc, int (*f) (guestfs_h *g, const char *filename, const char *format, int readonly, const char *protocol, char *const *server, const char *username, void *data), void *data); +static ssize_t for_each_disk (guestfs_h *g, virConnectPtr conn, xmlDocPtr doc...
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
2016 Aug 27
3
[PATCH 0/3] lib: Don't assert fail if port is missing in XML (RHBZ#1370424).
Simple fix for this assert-fail found in: https://bugzilla.redhat.com/show_bug.cgi?id=1370424 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.
2020 Feb 11
2
[PATCH v2] lib: add support for disks with 4096 bytes sector size
...} return true; diff --git a/lib/libvirt-domain.c b/lib/libvirt-domain.c index 37c0b49b2..009a22ad6 100644 --- a/lib/libvirt-domain.c +++ b/lib/libvirt-domain.c @@ -42,11 +42,12 @@ #if defined(HAVE_LIBVIRT) static xmlDocPtr get_domain_xml (guestfs_h *g, virDomainPtr dom); -static ssize_t for_each_disk (guestfs_h *g, virConnectPtr conn, xmlDocPtr doc, int (*f) (guestfs_h *g, const char *filename, const char *format, int readonly, const char *protocol, char *const *server, const char *username, const char *secret, void *data), void *data); +static ssize_t for_each_disk (guestfs_h *g, virConnectPtr...
2020 Feb 10
1
[PATCH] lib: allow to specify physical/logical block size for disks
...} return true; diff --git a/lib/libvirt-domain.c b/lib/libvirt-domain.c index 37c0b49b2..009a22ad6 100644 --- a/lib/libvirt-domain.c +++ b/lib/libvirt-domain.c @@ -42,11 +42,12 @@ #if defined(HAVE_LIBVIRT) static xmlDocPtr get_domain_xml (guestfs_h *g, virDomainPtr dom); -static ssize_t for_each_disk (guestfs_h *g, virConnectPtr conn, xmlDocPtr doc, int (*f) (guestfs_h *g, const char *filename, const char *format, int readonly, const char *protocol, char *const *server, const char *username, const char *secret, void *data), void *data); +static ssize_t for_each_disk (guestfs_h *g, virConnectPtr...
2014 Jan 23
7
[PATCH 0/7] Various fixes for Ceph drives and parsing libvirt XML.
Miscellaneous fixes to: - Handling of Ceph drives now works end-to-end (RHBZ#1026688). - In particular, you can now use rbd:/// URIs in guestfish (and they work). - Parse Ceph & NBD network drives from libvirt XML correctly, so that existing domains with Ceph/NBD drives can be added (eg. using guestfish -d option). - Add more testing of the above.
2013 Feb 28
5
[PATCH v2 0/5] Fix SELinux security contexts so we can access shared disks (RHBZ#912499).
Link to version 1: https://www.redhat.com/archives/libguestfs/2013-February/thread.html#00122 Changes since version 1: - I've pushed two (of the three) code refactoring patches. The third one proved rather hard to move. - selinuxnorelabel option is no more. Instead there is a second internal API (internal_set_libvirt_selinux_norelabel_disks). - fixed bogus commit message -
2020 Feb 24
3
*** buffer overflow detected *** accessing invalid FD in libguestfs
...ces/5ca86029-d296-4261-9a67-908bdd6c4eab/disk", format=<optimized out>, readonly_in_xml=<optimized out>, protocol=<optimized out>, server=<optimized out>, username=0x0, secret=0x0, datavp=0x7fffca7fb610) at ../../../lib/libvirt-domain.c:396 #18 0x00007ffff4813cd6 in for_each_disk (f=0x7ffff48127e0 <add_disk>, data=0x7fffca7fb610, doc=0x7fffbc10cf80, conn=0x7fffbc01fa10, g=0x7fffbc008d60) at ../../../lib/libvirt-domain.c:782 #19 guestfs_impl_add_libvirt_dom (g=g@entry=0x7fffbc008d60, domvp=domvp@entry=0x7fffbc064000, optargs=optargs@entry=0x7fffca7fb790) at ../../....
2017 Apr 04
1
[PATCH] Use Unicode single quotes ‘’ in place of short single quoted strings throughout.
..., const char *domain_name, if (!dom) { err = virGetLastError (); - error (g, _("no libvirt domain called '%s': %s"), + error (g, _("no libvirt domain called ‘%s’: %s"), domain_name, err->message); goto cleanup; } @@ -614,7 +614,7 @@ for_each_disk (guestfs_h *g, sec = virSecretLookupByUUIDString (conn, uuidstr); if (sec == NULL) { err = virGetLastError (); - error (g, _("no secret with UUID '%s': %s"), + error (g, _("no secret with UUID ‘%s’: %s"),...
2015 Oct 05
0
[PATCH 2/2] Fix whitespace.
...7 @@ struct add_disk_data { int guestfs_impl_add_libvirt_dom (guestfs_h *g, void *domvp, - const struct guestfs_add_libvirt_dom_argv *optargs) + const struct guestfs_add_libvirt_dom_argv *optargs) { virDomainPtr dom = domvp; ssize_t r; @@ -591,7 +591,7 @@ for_each_disk (guestfs_h *g, } xphost = xmlXPathEvalExpression (BAD_CAST "./source/host", - xpathCtx); + xpathCtx); if (xphost == NULL || xphost->nodesetval == NULL) continue; @@ -707,11 +707,11 @@...
2015 Oct 05
3
[PATCH 1/2] Change 'fprintf (stdout,...)' -> printf.
Result of earlier copy and paste. --- align/scan.c | 35 ++++++++++--------- cat/cat.c | 39 +++++++++++---------- cat/filesystems.c | 69 +++++++++++++++++++------------------- cat/log.c | 35 ++++++++++--------- cat/ls.c | 61 +++++++++++++++++---------------- df/main.c | 43 ++++++++++++------------ diff/diff.c | 67
2015 Feb 14
2
[PATCH 0/2] Change guestfs__*
libguestfs has used double and triple underscores in identifiers. These aren't valid for global names in C++. (http://stackoverflow.com/a/228797) These large but completely mechanical patches change the illegal identifiers to legal ones. Rich.
2017 Jun 27
3
[PATCH] libvirt: disallow non-local connections (RHBZ#1347830)
...ot;), + uristr); + return -1; + } + if (!readonly) { virDomainInfo info; virErrorPtr err; @@ -320,7 +354,7 @@ guestfs_impl_add_libvirt_dom (guestfs_h *g, void *domvp, * all disks are added or none are added. */ ckp = guestfs_int_checkpoint_drives (g); - r = for_each_disk (g, virDomainGetConnect (dom), doc, add_disk, &data); + r = for_each_disk (g, conn, doc, add_disk, &data); if (r == -1) guestfs_int_rollback_drives (g, ckp); -- 2.9.4