search for: uri_quot

Displaying 20 results from an estimated 28 matches for "uri_quot".

Did you mean: uri_quote
2019 Jun 26
3
[nbdkit PATCH v2 0/2] adding nbdkit --run '$uri'
Since v1: - new patch to add uri_quote() - rebase on top of other recent patches needed while auditing shell_quote() - use uri_quote() instead of shell_quote() for producing $uri Eric Blake (2): common/utils: Add uri_quote and tests captive: Support $uri in --run docs/nbdkit-captive.pod | 8 ++- common/utils/utils.h |...
2015 Aug 28
3
[PATCH 0/2] v2v: vcenter: Calculate dcPath correctly (RHBZ#1256823).
Calculate dcPath correctly for vCenter conversions. Rich.
2017 Jun 29
0
[PATCH] v2v: Allow -i libvirtxml to open network disks over http or https.
...-> "" + | "http", Some 80 -> "" + | _, Some port when port >= 1 -> ":" ^ string_of_int port + | _, Some port -> invalid_arg "invalid port number in libvirt XML" in + sprintf "%s://%s%s%s" driver host port (uri_quote path) in + + let json_params = [ + "file.driver", JSON.String driver; (* "http" or "https" *) + "file.url", JSON.String url; + "file.timeout", JSON.Int 2000; + "file.readahead", JSON.Int (1024 * 1024); + (* "file.ssl...
2020 Jul 21
0
Re: [PATCH nbdkit] server: Deprecate the -e/--exportname parameter.
...perror ("open_memstream"); > @@ -74,27 +72,13 @@ run_command (void) > if (port) { > fprintf (fp, "nbd://localhost:"); > shell_quote (port, fp); > - if (strcmp (exportname, "") != 0) { > - putc ('/', fp); > - uri_quote (exportname, fp); > - } > } > else if (unixsocket) { > - fprintf (fp, "nbd+unix://"); > - if (strcmp (exportname, "") != 0) { > - putc ('/', fp); > - uri_quote (exportname, fp); > - } > - fprintf (fp, "\\?...
2017 Oct 13
7
[PATCH 0/5] v2v: Handle disks with snapshots (RHBZ#1172425).
The first commit removes the --dcpath parameter, which just makes the following stuff simpler. Since libvirt has supported getting datacenterpath from VMware since Oct 2015, it's time to drop this hairy parameter. The rest is quite a complicated series of refactorings, followed by a very simple change to add handling of snapshots taken from old virt-v2v. Rich.
2019 Apr 08
0
[PATCH 01/11] v2v: Move have_selinux to utils.
...--- a/v2v/utils.ml +++ b/v2v/utils.ml @@ -24,6 +24,10 @@ open Std_utils open Tools_utils open Common_gettext.Gettext +(* Is SELinux enabled and enforcing on the host? *) +let have_selinux = + 0 = Sys.command "getenforce 2>/dev/null | grep -isq Enforcing" + (* URI quoting. *) let uri_quote str = let len = String.length str in diff --git a/v2v/utils.mli b/v2v/utils.mli index 4635d4808..61cba1bbd 100644 --- a/v2v/utils.mli +++ b/v2v/utils.mli @@ -18,6 +18,9 @@ (** Utilities used in virt-v2v only. *) +val have_selinux : bool +(** True if SELinux is enabled and enforcing on the...
2020 Jul 21
3
[PATCH nbdkit] server: Deprecate the -e/--exportname parameter.
...cmd, &len); if (fp == NULL) { perror ("open_memstream"); @@ -74,27 +72,13 @@ run_command (void) if (port) { fprintf (fp, "nbd://localhost:"); shell_quote (port, fp); - if (strcmp (exportname, "") != 0) { - putc ('/', fp); - uri_quote (exportname, fp); - } } else if (unixsocket) { - fprintf (fp, "nbd+unix://"); - if (strcmp (exportname, "") != 0) { - putc ('/', fp); - uri_quote (exportname, fp); - } - fprintf (fp, "\\?socket="); + fprintf (fp, "nbd+uni...
2020 Jul 22
2
[nbdkit PATCH] server: Reinstate limited use of -e/-exportname.
...md, &len); if (fp == NULL) { perror ("open_memstream"); @@ -72,15 +75,26 @@ run_command (void) if (port) { fprintf (fp, "nbd://localhost:"); shell_quote (port, fp); + if (strcmp (export_name, "") != 0) { + putc ('/', fp); + uri_quote (export_name, fp); + } } else if (unixsocket) { - fprintf (fp, "nbd+unix://\\?socket="); + fprintf (fp, "nbd+unix://"); + if (strcmp (export_name, "") != 0) { + putc ('/', fp); + uri_quote (export_name, fp); + } + fprintf (fp,...
2020 Apr 15
2
Re: [PATCH nbdkit 6/9] common/utils: Add a copy_environ utility function.
...ue) pairs to it. > --- > common/utils/Makefile.am | 2 + > common/utils/utils.h | 1 + > common/utils/environ.c | 116 +++++++++++++++++++++++++++++++++++++++ > 3 files changed, 119 insertions(+) > > +++ b/common/utils/utils.h > @@ -38,5 +38,6 @@ extern void uri_quote (const char *str, FILE *fp); > extern int exit_status_to_nbd_error (int status, const char *cmd); > extern int set_cloexec (int fd); > extern int set_nonblock (int fd); > +extern char **copy_environ (char **env, ...); Should use __attribute__((sentinel)), to let the compiler enf...
2020 Sep 24
4
[PATCH v2v 0/4] v2v: vcenter: Implement cookie scripts.
Patch 1 was previously posted here: https://www.redhat.com/archives/libguestfs/2020-June/msg00086.html to handle this bug: https://bugzilla.redhat.com/show_bug.cgi?id=1848862 I was able to observe this bug and for me at least disabling readahead seems to cure it. Patches 2 and 3 are simplifications, removing a now-undocumented feature of virt-v2v-copy-to-local and thus simplifying greatly the
2015 Oct 09
4
[PATCH 0/4] v2v: Use libvirt-supplied <vmware:datacenterpath> if available.
See earlier thread on libvir-list: https://www.redhat.com/archives/libvir-list/2015-September/thread.html#00201 Libvirt >= 1.2.20 supplies the correct dcPath parameter. If it is available in the libvirt XML, use it, otherwise fall back to the old method of trying to guess it from the vpx:// path. Patches 1, 2 and 4 are just refactoring around this change. Rich.
2019 Aug 27
1
[PATCH nbdkit] server: Try hard to maintain invariant that fds 0, 1 and 2 are always open.
...+++++++++++++++++++ common/utils/utils.c | 29 +++++++++++++++++++++++++++++ 5 files changed, 58 insertions(+), 4 deletions(-) diff --git a/common/utils/utils.h b/common/utils/utils.h index ebd5f66..a77d2cd 100644 --- a/common/utils/utils.h +++ b/common/utils/utils.h @@ -38,5 +38,6 @@ extern void uri_quote (const char *str, FILE *fp); extern int exit_status_to_nbd_error (int status, const char *cmd); extern int set_cloexec (int fd); extern int set_nonblock (int fd); +extern void close_or_nullify_fd (int fd); #endif /* NBDKIT_UTILS_H */ diff --git a/server/connections.c b/server/connections.c i...
2019 Jun 26
0
[nbdkit PATCH v2 2/2] captive: Support $uri in --run
..."URL". Unfortunately guestfish and qemu take + /* Construct $uri. */ + fprintf (fp, "uri="); + if (port) { + fprintf (fp, "nbd://localhost:"); + shell_quote (port, fp); + } + else if (unixsocket) { + fprintf (fp, "nbd+unix://\\?socket="); + uri_quote (unixsocket, fp); + } + fprintf (fp, "\n"); + + /* Construct older $nbd "URL". Unfortunately guestfish and qemu take * different syntax, so try to guess which one we need. */ fprintf (fp, "nbd="); -- 2.20.1
2020 Apr 15
0
Re: [PATCH nbdkit 6/9] common/utils: Add a copy_environ utility function.
...t; common/utils/Makefile.am | 2 + > > common/utils/utils.h | 1 + > > common/utils/environ.c | 116 +++++++++++++++++++++++++++++++++++++++ > > 3 files changed, 119 insertions(+) > > > > >+++ b/common/utils/utils.h > >@@ -38,5 +38,6 @@ extern void uri_quote (const char *str, FILE *fp); > > extern int exit_status_to_nbd_error (int status, const char *cmd); > > extern int set_cloexec (int fd); > > extern int set_nonblock (int fd); > >+extern char **copy_environ (char **env, ...); > > Should use __attribute__((sentinel)...
2018 Mar 27
6
[PATCH FOR DISCUSSION ONLY v2] v2v: Add -o kubevirt output mode.
Fixes some of the more egregious problems with v1, and also applies properly to the head of git without needing any other patches. Rich.
2020 Apr 15
0
[PATCH nbdkit 6/9] common/utils: Add a copy_environ utility function.
...PFLAGS = \ -I$(top_srcdir)/include \ + -I$(top_srcdir)/common/include \ $(NULL) libutils_la_CFLAGS = $(WARNINGS_CFLAGS) diff --git a/common/utils/utils.h b/common/utils/utils.h index ebd5f66b..5c121ccb 100644 --- a/common/utils/utils.h +++ b/common/utils/utils.h @@ -38,5 +38,6 @@ extern void uri_quote (const char *str, FILE *fp); extern int exit_status_to_nbd_error (int status, const char *cmd); extern int set_cloexec (int fd); extern int set_nonblock (int fd); +extern char **copy_environ (char **env, ...); #endif /* NBDKIT_UTILS_H */ diff --git a/common/utils/environ.c b/common/utils/env...
2018 Jun 05
4
[PATCH 0/3] v2v: Various refactorings.
Use -ip instead of --password-file, and various refactorings. It strikes me that we should probably deprecate and eventually remove virt-v2v-copy-to-local. With the introduction of the new SSH and VDDK transports, and with RHEL 5 Xen becoming more irrelevant, it's no longer needed. Rich.
2019 Sep 28
11
[nbdkit PATCH v2 0/7] Spec compliance patches
Since the v1 series (0/4, at [1]), I've applied patches 1 and 2, rewritten patch 3 [Forbid NUL in export and context names] into patch 4 here, patch 4 there turned into patch 6 here, and everything else here is new. [1]https://www.redhat.com/archives/libguestfs/2019-September/msg00180.html I don't know if there is a handy reusable function for checking whether a string contains valid
2015 Oct 29
7
[PATCH 0/7] v2v: Miscellaneous refactorings.
Just refactoring. Rich.
2019 Apr 08
12
[PATCH 00/11] v2v: Change virt-v2v to use nbdkit for input in several modes.
This series (except the last one) changes virt-v2v to use nbdkit for several input modes: -i vmx -it vddk: No change in functionality, as this already uses nbdkit-vddk-plugin, but the code is refactored for the other modes to use. -i libvirtxml: Use nbdkit-curl-plugin instead of qemu curl. vCenter: Use nbdkit-curl-plugin instead of qemu curl. xen: Use nbdkit-ssh-plugin instead of qemu