search for: nbd_open_handle

Displaying 8 results from an estimated 8 matches for "nbd_open_handle".

2019 May 25
0
[nbdkit PATCH 2/2] nbd: Add shared=true parameter
...e name of Unix socket */ static char *sockname; @@ -73,9 +104,18 @@ static const char *export; /* Number of retries */ static unsigned long retry; +/* True to share single server connection among all clients */ +static bool shared; +static struct handle *shared_handle; + +static struct handle *nbd_open_handle (int readonly); +static void nbd_close_handle (struct handle *h); + static void nbd_unload (void) { + if (shared) + nbd_close_handle (shared_handle); free (sockname); free (servname); } @@ -89,6 +129,7 @@ static int nbd_config (const char *key, const char *value) { char *end; +...
2019 May 25
3
[RFC nbdkit PATCH 0/2] Add 'nbdkit nbd shared=1' mode
I got annoyed by qemu-nbd's default of only allowing a single connection; combine that with nbdkit's nbd plugin, and even 'qemu-nbd --list' of nbdkit counts as the single connection and immediately hangs up. If we introduce a shared mode, then 'qemu-nbd --list' can connect as many times as it wants without killing the original qemu-nbd wrapped by nbdkit. But this in turn
2019 May 30
2
[PATCH nbdkit 1/2] nbd: Fix -Werror=maybe-uninitialized warning.
GCC is concerned that if we never go round the loop then fd will be uninitialized. By asserting that getaddrinfo set result != NULL we can avoid this. nbd.c: In function ‘nbd_open_handle’: nbd.c:974:5: error: ‘fd’ may be used uninitialized in this function [-Werror=maybe-uninitialized] 974 | close (fd); | ^~~~~~~~~~ nbd.c:954:7: note: ‘fd’ was declared here 954 | int fd; | ^~ cc1: all warnings being treated as errors --- plugins/nbd/nbd.c | 2 ++ 1...
2019 May 30
5
[nbdkit PATCH 0/4] Play with libnbd for nbdkit-add
Patch 1 played with an early draft of Rich's Fedora 30 libnbd package: https://bugzilla.redhat.com/show_bug.cgi?id=1713767#c17 Note that comment 21 provides a newer package 0.1.1-1 with a different API; and that libnbd has more unreleased API changes in the pipeline (whether that will be called 0.2 or 0.1.2); so we'll have to tweak things based on what is actually available in distros.
2019 Jun 02
5
[nbdkit PATCH v2 0/5] Play with libnbd for nbdkit-nbd
libnbd-0.1.2-1 is now available in Fedora 29/30 updates-testing, although it was not compiled against libxml2 so it lacks uri support (I ended up testing patch 4 with a self-built libnbd). Diffs since v1 - rebase to master, bump from libnbd 0.1 to 0.1.2, add URI support, better timing results Still not done - patch 5 needs associated tests Eric Blake (5): nbd: Check for libnbd nbd:
2020 Mar 19
1
[nbdkit PATCH] nbd: Drop nbd-standalone fallback
...f export on remote server, default '', ignored for oldstyle */ -static const char *export; - -/* Number of retries */ -static unsigned retry; - -/* True to share single server connection among all clients */ -static bool shared; -static struct handle *shared_handle; - -static struct handle *nbd_open_handle (int readonly); -static void nbd_close_handle (struct handle *h); - -static void -nbd_unload (void) -{ - if (shared) - nbd_close_handle (shared_handle); - free (sockname); - free (servname); -} - -/* Called for each key=value passed on the command line. This plugin - * accepts socket=<soc...
2019 Sep 25
3
[nbdkit PATCH 0/2] more protocol.h tweaks
More nbd-protocol.h improvements Eric Blake (2): common/protocol: Switch nbdmagic to uint64_t common/protocol: Declare additional constants common/protocol/nbd-protocol.h | 16 ++++++++++------ server/protocol-handshake-newstyle.c | 2 +- server/protocol-handshake-oldstyle.c | 2 +- plugins/nbd/nbd-standalone.c | 2 +- tests/test-layers.c | 2 +- 5 files
2019 Jun 12
8
[nbdkit PATCH v3 0/5] Play with libnbd for nbdkit-nbd
libnbd-0.1.4-1 is now available in Fedora 29/30 updates testing. Diffs since v2 - rebase to master, bump from libnbd 0.1.2 to 0.1.3+, add tests to TLS usage which flushed out the need to turn relative pathnames into absolute, doc tweaks Now that the testsuite covers TLS and libnbd has been fixed to provide the things I found lacking when developing v2, I'm leaning towards pushing this on