nbddiscard, nbdzero - discard or zero all data on a Network Block Device
nbddiscard [-z] [-q] [-v] [-y] [-o OFFSET] [-l LENGTH] NBD-URI
nbddiscard --version
nbddiscard --help
nbdzero [-q] [-v] [-y] [-o OFFSET] [-l LENGTH] NBD-URI
nbdzero --version
nbdzero --help
nbddiscard discards all data on a Network Block Device (NBD) endpoint. If supported, this frees up the backing storage and makes the device completely sparse. For example, if an NBD server is running locally on port 10809 you could do:
$ nbddiscard nbd://localhost
PERMANENTLY ERASE everything on nbd://localhost bytes 0 - 1073741823
(y/N)? y
nbdzero is the same, but the data is replaced by allocated, zeroed blocks.
All data in the discarded or zeroed region is PERMANENTLY ERASED.
For information about NBD URIs, see nbd_connect_uri(3).
Display brief command line help and exit.
Instead of discarding to the end of the disk, discard only length bytes. You can use the normal suffixes like K, M etc.
Instead of starting from the beginning of the disk, start at the given offset. You can use the normal suffixes like K, M etc.
Quiet mode, do not print any warnings.
Enable verbose libnbd messages. This has the same effect as setting the environment variable LIBNBD_DEBUG=1
Display the package name and version and exit.
Assume yes to all questions. This will proceed straight to erasing your data. Use this in scripts to avoid interactivity.
Zero, instead of discarding. nbdzero is just nbddiscard with -z.
libnbd(3), libnbd-python(3), nbd_connect_uri(3), nbdcopy(1), nbddump(1), nbdfuse(1), nbdinfo(1), nbdsh(1), nbdublk(1), blkdiscard(8), qemu-img(1).
Richard W.M. Jones
Copyright Red Hat
This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA