Displaying 20 results from an estimated 78 matches for "guestfs_add_domain".
2019 Sep 07
0
[PATCH] drives: Typo fix
...ves.c b/lib/drives.c
index 82ef30093..5a8d29ab4 100644
--- a/lib/drives.c
+++ b/lib/drives.c
@@ -1064,7 +1064,7 @@ guestfs_impl_remove_drive (guestfs_h *g, const char *label)
/**
* Checkpoint and roll back drives, so that groups of drives can be
- * added atomicly. Only used by L<guestfs(3)/guestfs_add_domain>.
+ * added atomically. Only used by L<guestfs(3)/guestfs_add_domain>.
*/
size_t
guestfs_int_checkpoint_drives (guestfs_h *g)
--
2.21.0
2014 Nov 07
2
Re: libguestfs-tools with libvirt SASL authentication
...nd line, then virt-df will call libvirt to get them. That happens in
df/domains.c:get_all_libvirt_domains:
https://github.com/libguestfs/libguestfs/blob/master/df/domains.c#L72
If you supply a domain name, then this is not used.
(2) Secondly, virt-df calls into libguestfs (the C library) call
guestfs_add_domain() with a domain name parameter as a literal string, either one fetched from (1) or one you passed on the command line.
Libguestfs then looks that up with libvirt to check it exists and to get the list of disks. That happens in
src/libvirt-auth.c:guestfs___open_libvirt_connection:
https://github...
2014 Nov 04
2
libguestfs-tools with libvirt SASL authentication
Hello,
I'm running into an issue using the 'virt-df' command when SASL is enabled in libvirt. I'm running version 1.26.5 of libguestfs on an Ubuntu 14.04 OS.
I'm running 'virt-df' for all guests at one time, not specifying a domain or image to use. I was expecting a SASL authentication prompt but to no avail. Below is a sample run:
root@all-in-one:~# virt-df -P 15
2012 Oct 13
2
Proposed libguestfs API for implementing libvirt virConnectOpenAuth
...[] = { "authname", "passphrase", NULL };
g = guestfs_create ();
guestfs_set_libvirt_supported_credentials (g, creds);
guestfs_set_event_callback (g, do_auth,
GUESTFS_EVENT_LIBVIRT_AUTH, 0, NULL);
// An example of a function that would open a libvirt connection:
guestfs_add_domain (g, "dom",
GUESTFS_ADD_DOMAIN_LIBVIRTURI, "qemu:///system",
-1);
}
----------------------------------------------------------------------
By the way, some of the virt tools can open multiple connections to
libvirt, and it is architecturally hard to change this:
htt...
2014 Nov 05
0
Re: libguestfs-tools with libvirt SASL authentication
...nd line,
then virt-df will call libvirt to get them. That happens in
df/domains.c:get_all_libvirt_domains:
https://github.com/libguestfs/libguestfs/blob/master/df/domains.c#L72
If you supply a domain name, then this is not used.
(2) Secondly, virt-df calls into libguestfs (the C library) call
guestfs_add_domain() with a domain name parameter as a literal string,
either one fetched from (1) or one you passed on the command line.
Libguestfs then looks that up with libvirt to check it exists and to
get the list of disks. That happens in
src/libvirt-auth.c:guestfs___open_libvirt_connection:
https://github...
2020 Feb 20
0
buffer overflow detected in collectd using libguestfs
...estfs.so.0
#17 0x00007ffff4813cd6 in ?? () from
/usr/lib/x86_64-linux-gnu/libguestfs.so.0
#18 0x00007ffff47ab2c3 in guestfs_add_libvirt_dom_argv () from
/usr/lib/x86_64-linux-gnu/libguestfs.so.0
#19 0x00007ffff4812cf6 in ?? () from
/usr/lib/x86_64-linux-gnu/libguestfs.so.0
#20 0x00007ffff4760368 in guestfs_add_domain_argv () from
/usr/lib/x86_64-linux-gnu/libguestfs.so.0
#21 0x00007ffff47dfc38 in guestfs_add_domain_va () from
/usr/lib/x86_64-linux-gnu/libguestfs.so.0
#22 0x00007ffff47dfee4 in guestfs_add_domain () from
/usr/lib/x86_64-linux-gnu/libguestfs.so.0
#23 0x00007ffff4a78bec in refresh_lists (inst=inst@...
2012 Oct 13
0
[PATCH] New APIs: Model libvirt authentication events through the API.
...) creds);
+ if (r == -1)
+ exit (EXIT_FAILURE);
+
+ /* Set up the event handler. */
+ eh = guestfs_set_event_callback (g, auth_callback,
+ GUESTFS_EVENT_LIBVIRT_AUTH, 0, NULL);
+ if (eh == -1)
+ exit (EXIT_FAILURE);
+
+ /* Add the named domain. */
+ r = guestfs_add_domain (g, dom,
+ GUESTFS_ADD_DOMAIN_LIBVIRTURI, uri,
+ -1);
+ if (r == -1)
+ exit (EXIT_FAILURE);
+
+ /* Launch and do some simple inspection. */
+ r = guestfs_launch (g);
+ if (r == -1)
+ exit (EXIT_FAILURE);
+
+ filesystems = guestfs_list_fil...
2010 Nov 10
7
[PATCH 0/7] Add libvirt domain to core API
...PIs allow you to add the disks from a libvirt domain.
The higher level add-domain API takes the name of the libvirt domain
as a string and connects to libvirt itself. The lower level
add-libvirt-dom API relies on the program to connect to libvirt and
pass the virDomainPtr into the API call.
int guestfs_add_domain (guestfs_h *g, const char *dom, ...);
int guestfs_add_libvirt_dom (guestfs_h *g, virDomainPtr dom, ...);
In guestfish you can use the 'domain' command to access the higher
level API, eg:
><fs> domain Fedora14 libvirturi:qemu:///system
1
(The returned number is the numb...
2015 May 26
6
[PATCH 0/6] Update the way that API versions are generated for the man page.
The existing mechanism was clunky, slow and used ~ 10 MB of
local disk.
Rich.
2014 Nov 13
0
Re: libguestfs-tools with libvirt SASL authentication
...to get them. That happens in
> df/domains.c:get_all_libvirt_domains:
>
> https://github.com/libguestfs/libguestfs/blob/master/df/domains.c#L72
>
> If you supply a domain name, then this is not used.
>
> (2) Secondly, virt-df calls into libguestfs (the C library) call
> guestfs_add_domain() with a domain name parameter as a literal string, either one fetched from (1) or one you passed on the command line.
> Libguestfs then looks that up with libvirt to check it exists and to get the list of disks. That happens in
> src/libvirt-auth.c:guestfs___open_libvirt_connection:
>
&...
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
-
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.
2012 Mar 08
2
mounting using guestfish
[Please remember to post all questions on the mailing list]
On Thu, Mar 08, 2012 at 09:41:19PM +0700, Tho Huynh wrote:
> Can I mount the guest's file system into a folder/path (mountpoint)
> in the host machine using guestfish?
No, but you don't need to.
> And accessing that folder equal to accessing the guest's file
> system. What I'm trying to do is to copy a file
2013 Feb 28
7
[PATCH 0/7] Fix SELinux security contexts so we can access shared disks (RHBZ#912499).
...om
being able to read them. So naturally the libguestfs appliance
(ie. qemu) cannot read these disks, not even if it is running as root.
The fix is to read that SELinux label from libvirt, then label the
libguestfs appliance the same way, so it can access the disks.
This is done by modifying the guestfs_add_domain call so that it reads
the label from libvirt, and passes the label through to the libvirt
back end which uses it when creating the appliance. It's actually a
bit more complex than this because we have to label the overlay disks
and the appliance disk correctly.
These patches are only the fina...
2020 Feb 24
3
*** buffer overflow detected *** accessing invalid FD in libguestfs
...fffca7fb790) at
../../../lib/actions-4.c:174
#21 0x00007ffff4812cf6 in guestfs_impl_add_domain (g=g@entry=0x7fffbc008d60,
domain_name=domain_name@entry=0x7fffbc0338e0 "tve50:00000013",
optargs=optargs@entry=0x7fffca7fb8c0)
at ../../../lib/libvirt-domain.c:163
#22 0x00007ffff4760368 in guestfs_add_domain_argv (g=0x7fffbc008d60,
dom=0x7fffbc0338e0 "tve50:00000013", optargs=optargs@entry=0x7fffca7fb8c0)
at ../../../lib/actions-0.c:139
#23 0x00007ffff47dfc38 in guestfs_add_domain_va (g=<optimized out>,
dom=<optimized out>, args=args@entry=0x7fffca7fb920) at
../../../lib/actions-v...
2012 Mar 09
1
[PATCH 1/2] Close all file descriptors in the recovery process.
From: "Richard W.M. Jones" <rjones at redhat.com>
If the parent process uses a pipe (or any fd, but pipes are a
particular problem), then the recovery process would hold open the
file descriptor(s) of the pipe, meaning that it could not be fully
closed in the parent. Because the recovery process doesn't use
exec(2), this wasn't avoidable even using FD_CLOEXEC.
Avoid this
2014 Mar 27
4
ANNOUNCE: libguestfs 1.26 released
...dd_drive_opts: new discard parameter
The new discard parameter allows fine-grained control over
discard/trim support for a particular disk. This allows the host file
to become more sparse (or thin-provisioned) when you delete files or
issue the guestfs_fstrim API call.
guestfs_add_domain: new parameters: cachemode, discard
These parameters are passed through when adding the domain's disks.
guestfs_blkdiscard
Discard all blocks on a guestfs device. Combined with the discard
parameter above, this makes the host file sparse.
guestfs_blkdiscardzeroes...
2018 Nov 02
2
guestfs_launch() fails when C application is started as a systemd service
Hello,
I have a simple C program that uses libguestfs to extract info about disk
usage from a libvirt domain. It works when ran manually as root, but fails
when started as a systemd service.
I'm attaching the service file, source code and verbose logs from both the
successful manual run and from the service journal.
SELinix is disabled.
Error messages:
libguestfs:
2012 Mar 27
16
[PATCH 01/16] generator: Fix unescaped '<' and '>' in api descriptions
---
generator/generator_actions.ml | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/generator/generator_actions.ml b/generator/generator_actions.ml
index 68a7bf6..fcf363f 100644
--- a/generator/generator_actions.ml
+++ b/generator/generator_actions.ml
@@ -4664,7 +4664,7 @@ This creates an ext2/3/4 filesystem on C<device> with
an external journal on
2018 Nov 07
2
Re: guestfs_launch() fails when C application is started as a systemd service
...output from collectd:
[2018-11-07 12:21:54] plugin_load: plugin "logfile" successfully loaded.
[2018-11-07 12:21:54] plugin_load: plugin "syslog" successfully loaded.
Before guestfs_create()
UID: 0
Effective UID: 0
Before guestfs_set_verbose()
Before guestfs_set_trace()
Before guestfs_add_domain()
libguestfs: trace: add_domain "wer" "readonly:true"
libguestfs: opening libvirt handle: URI = NULL, auth = default+wrapper,
flags = 0
libguestfs: successfully opened libvirt handle: conn = 0x7f7e70005210
libguestfs: trace: add_libvirt_dom (virDomainPtr)0x7f7e70005fa0
"rea...