Displaying 20 results from an estimated 1000 matches similar to: "[nbdkit PATCH] file: Diagnose a missing file earlier"
2020 Aug 07
0
[nbdkit PATCH 2/4] file: Add .list_exports support
Add a new mode to the file plugin, using directory=DIR instead of
[file=]FILE, to allow it to serve all regular/block files in a given
directory, as well as advertising the names of those files it will be
serving.
Signed-off-by: Eric Blake <eblake@redhat.com>
---
plugins/file/nbdkit-file-plugin.pod | 28 +++++-
tests/Makefile.am | 4 +-
plugins/file/file.c
2018 Feb 14
2
[nbdkit PATCH v2] plugin: add and use nbdkit_realpath
Introduce a new helper function to resolve a path name, calling
nbdkit_error on failure: other than doing what nbdkit_absolute_path
does, it also checks that the file exists (and thus avoids errors later
on). To help distinguish it from nbdkit_absolute_path, improve the
documentation of the latter.
Apply it where an existing path is required, both in nbdkit itself and
in plugins.
Related to:
2018 Apr 12
4
[nbdkit PATCH v3 0/2] Add nbdkit_realpath
Hi,
this is the v3 of my series for nbdkit_realpath; this series adds an
extra documentation update to nbdkit_absolute_path, documenting when it
can only be used, and then adds nbdkit_realpath.
Thanks,
Pino Toscano (2):
docs: improve documentation of nbdkit_absolute_path
plugin: add and use nbdkit_realpath
docs/nbdkit-plugin.pod | 24 +++++++++++++++++++++++-
include/nbdkit-common.h
2018 Feb 13
3
[nbdkit PATCH] plugin: add and use nbdkit_realpath
Introduce a new helper function to resolve a path name, calling
nbdkit_error on failure: other than doing what nbdkit_absolute_path
does, it also checks that the file exist (and thus avoid errors later
on).
Apply it where an existing path is required, both in nbdkit itself and
in plugins.
Related to: https://bugzilla.redhat.com/show_bug.cgi?id=1527334
---
docs/nbdkit-plugin.pod | 13
2020 Aug 25
0
[RFC nbdkit PATCH 4/5] file: Utilize nbdkit_string_intern
Instead of needing to provide .unload, we can let nbdkit manage the
lifetime for us. However, if we like this approach, it may be wiser
to introduce new variants of nbdkit_realpath/absolute_path which
return const char * already intern'd.
Signed-off-by: Eric Blake <eblake@redhat.com>
---
See the cover letter: if we like this, there are several other plugins
that could also reduce
2018 Aug 02
2
Re: [PATCH 1/3] file: Avoid unsupported fallocate() calls
On 08/02/2018 02:05 PM, Nir Soffer wrote:
> When using file systems not supporting ZERO_RANGE (e.g. NFS 4.2) or
> block device on kernel < 4.9, we used to call fallocate() for every
> zero, fail with EOPNOTSUPP, and fallback to manual zeroing. When
> trimming, we used to try unsupported fallocate() on every call.
>
> Change file handle to remember if punching holes or
2018 Aug 02
10
[PATCH 0/3] file: Zero for block devices and older file systems
This is the second version to support efficient zero for block devices
on older kernels (e.g. RHEL 7.5), and file systems that do not support
yet FALLOC_FS_ZERO_RANGE (e.g. NFS 4.2).
Changes since v1:
- Split to smaller patches
- Skip linux only includes on other systems
- Skip code using BLKZEROOUT if the macro is not defined
- Try BLKZEROOUT only if the offset and count are aligned to device
2018 Jan 17
0
[PATCH 9/9] filters: Move rdelay/wdelay from file plugin to new delay filter.
Previously the file plugin supported ‘rdelay’ and ‘wdelay’ parameters
for injecting delays (for testing) into read and write requests. This
moves the functionality to a new delay filter so that it can be used
with any plugin.
---
TODO | 3 -
configure.ac | 1 +
filters/Makefile.am | 1 +
filters/delay/Makefile.am
2018 Aug 19
9
[PATCH v3 0/4] file: Zero for block devices and older file systems
This version addresses comments on v3.
Changes since v3:
- Finally got spacing right (Eric)
- Reorder includes (Richard)
- Return 0 or -1 instead of r (Richard)
- Add common/include/isaligned.h to Makefile.am (Richard)
v3 was here:
https://www.redhat.com/archives/libguestfs/2018-August/msg00177.html
Nir Soffer (4):
file: Avoid unsupported fallocate() calls
file: Support zero without
2020 Aug 07
8
[nbdkit PATCH 0/4] More .list_exports uses
Here's changes to the file plugin (which I'm happy with) and a new
exportname filter (which is still at RFC stage; I need to finish
implementing strict mode in .open, and add tests).
I also discovered that we really want .list_exports and .open to know
when they are used on plaintext vs. tls clients for --tls=on, and we
may want to split out a new .default_export callback rather than
2018 Aug 19
0
[PATCH v4 4/4] file: Zero for block devices on old kernels
fallocate(FALLOC_FL_ZERO_RANGE) is supported for block devices with
modern kernel, but when it is not, we fall back to manual zeroing.
For block device, try also to use ioctl(BLKZEROOUT) if offset and count
are aligned to block device sector size.
Here is an example run without this change on RHEL 7.5:
$ export SOCK=/tmp/nbd.sock
$ export
2018 Aug 03
0
[PATCH v2 4/4] file: Zero for block devices on old kernels
fallocate(FALLOC_FL_ZERO_RANGE) is supportd for block devices with
modern kernel, but when it is not, we fall back to manual zeroing.
For block device, try also to use ioctl(BLKZEROOUT) if offset and count
are aligned to block device sector size.
Here is an example run without this change on RHEL 7.5:
$ export SOCK=/tmp/nbd.sock
$ export
2018 Aug 02
0
[PATCH 3/3] file: Zero for block devices on old kernels
fallocate(FALLOC_FL_ZERO_RANGE) is supportd for block devices with
modern kernel, but when it is not, we fall back to manual zeroing.
Check if the underlying file is a block device when opening the file,
and fall back to ioctl(BLKZEROOUT) for aligned zero requests for a
block device.
Here is an example run without this change on RHEL 7.5:
$ export SOCK=/tmp/nbd.sock
$ export
2018 Aug 03
0
[PATCH v2 1/4] file: Avoid unsupported fallocate() calls
When using file systems not supporting ZERO_RANGE (e.g. NFS 4.2) or
block device on kernel < 4.9, we used to call fallocate() for every
zero, fail with EOPNOTSUPP, and fallback to manual zeroing. When
trimming, we used to try unsupported fallocate() on every call.
Change file handle to remember if punching holes or zeroing range are
supported, and avoid unsupported calls.
- zero changed to:
2018 Aug 18
0
[PATCH v3 1/4] file: Avoid unsupported fallocate() calls
When using file systems not supporting ZERO_RANGE (e.g. NFS 4.2) or
block device on kernel < 4.9, we used to call fallocate() for every
zero, fail with EOPNOTSUPP, and fallback to manual zeroing. When
trimming, we used to try unsupported fallocate() on every call.
Change file handle to remember if punching holes or zeroing range are
supported, and avoid unsupported calls.
- zero changed to:
2018 Aug 19
0
[PATCH v4 1/4] file: Avoid unsupported fallocate() calls
When using file systems not supporting ZERO_RANGE (e.g. NFS 4.2) or
block device on kernel < 4.9, we used to call fallocate() for every
zero, fail with EOPNOTSUPP, and fallback to manual zeroing. When
trimming, we used to try unsupported fallocate() on every call.
Change file handle to remember if punching holes or zeroing range are
supported, and avoid unsupported calls.
- zero changed to:
2018 Aug 18
7
[PATCH v3 0/4] file: Zero for block devices and older file systems
This version addresses some of the comments on v2.
Changes since v2:
- file_zero: Add missing space in function call
- is_aligned: Assert that align is indeed a power of 2
- Spelling in commit message
Not changed:
- Eric commented that spacing was off:
https://www.redhat.com/archives/libguestfs/2018-August/msg00113.html
but I could not find anything wrong.
- Eric asked if ioctl.h will cause
2018 Aug 02
0
[PATCH] file: Zero support for block devices and NFS 4.2
If we may not trim, we tried ZERO_RANGE, but this is not well supported
yet, for example it is not available on NFS 4.2. ZERO_RANGE and
PUNCH_HOLE are supported now on block devices, but not on RHRL 7, so we
fallback to slow manual zeroing there.
Change the logic to support block devices on RHEL 7, and file systems
that do not support ZERO_RANGE.
The new logic:
- If we may trim, try PUNCH_HOLE
-
2018 Aug 02
0
[PATCH 1/3] file: Avoid unsupported fallocate() calls
When using file systems not supporting ZERO_RANGE (e.g. NFS 4.2) or
block device on kernel < 4.9, we used to call fallocate() for every
zero, fail with EOPNOTSUPP, and fallback to manual zeroing. When
trimming, we used to try unsupported fallocate() on every call.
Change file handle to remember if punching holes or zeroing range are
supported, and avoid unsupported calls.
- can_trim changed
2018 Aug 02
0
Re: [PATCH 1/3] file: Avoid unsupported fallocate() calls
On Thu, Aug 2, 2018 at 10:30 PM Eric Blake <eblake@redhat.com> wrote:
> On 08/02/2018 02:05 PM, Nir Soffer wrote:
> > When using file systems not supporting ZERO_RANGE (e.g. NFS 4.2) or
> > block device on kernel < 4.9, we used to call fallocate() for every
> > zero, fail with EOPNOTSUPP, and fallback to manual zeroing. When
> > trimming, we used to try