|
NAMEnbdkit-offset-filter - nbdkit offset filterSYNOPSISnbdkit --filter=offset plugin offset=OFFSET range=LENGTH [plugin-args...] DESCRIPTION"nbdkit-offset-filter" is a filter that limits requests to the byte range "[offset .. offset+range-1]" within another plugin.PARAMETERS
Note it is an error if the offset and/or range specify data which lies beyond the end of the underlying device. Use nbdkit-truncate-filter(1) to truncate or extend the size of plugins. EXAMPLESServe part of a fileUsing nbdkit-file-plugin(1), serve the file "disk.img" starting at offset "1M". The total length served is "100M" (the underlying file must therefore be at least "101M" in length):nbdkit --filter=offset file disk.img offset=1M range=100M Serve a single partitionAn easier way to do this is with nbdkit-partition-filter(1).One way to serve a single partition from a disk is to find the start and length of the partition, eg using: $ parted disk.img -- unit b print ... Number Start End Size Type File system Flags 1 65536B 104792575B 104727040B primary ext2 You can then serve the partition only using: nbdkit --filter=offset file disk.img offset=65536 range=104727040 FILES
VERSION"nbdkit-offset-filter" first appeared in nbdkit 1.2.SEE ALSOnbdkit(1), nbdkit-file-plugin(1), nbdkit-filter(3), nbdkit-partition-filter(1), nbdkit-tar-plugin(1), nbdkit-truncate-filter(1).AUTHORSEric BlakeRichard W.M. Jones COPYRIGHTCopyright (C) 2018 Red Hat Inc.LICENSERedistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Visit the GSP FreeBSD Man Page Interface. |