226 lines
6.2 KiB
HTML
226 lines
6.2 KiB
HTML
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<HTML><HEAD><TITLE>Man page of WIPEFS</TITLE>
|
|
</HEAD><BODY>
|
|
<H1>WIPEFS</H1>
|
|
Section: System Administration (8)<BR>Updated: December 2014<BR><A HREF="#index">Index</A>
|
|
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
|
|
|
|
<A NAME="lbAB"> </A>
|
|
<H2>NAME</H2>
|
|
|
|
wipefs - wipe a signature from a device
|
|
<A NAME="lbAC"> </A>
|
|
<H2>SYNOPSIS</H2>
|
|
|
|
<B>wipefs</B>
|
|
|
|
[<B>options</B>]
|
|
|
|
<I>device</I>...
|
|
|
|
<P>
|
|
<B>wipefs</B>
|
|
|
|
[<B>--backup</B>]
|
|
|
|
<B>-o</B>
|
|
|
|
<I>offset</I>
|
|
|
|
<I>device</I>...
|
|
|
|
<P>
|
|
<B>wipefs</B>
|
|
|
|
[<B>--backup</B>]
|
|
|
|
<B>-a</B>
|
|
|
|
<I>device</I>...
|
|
|
|
<A NAME="lbAD"> </A>
|
|
<H2>DESCRIPTION</H2>
|
|
|
|
<B>wipefs</B>
|
|
|
|
can erase filesystem, raid or partition-table signatures (magic strings) from
|
|
the specified
|
|
<I>device</I>
|
|
|
|
to make the signatures invisible for libblkid.
|
|
<B>wipefs</B>
|
|
|
|
does not erase the filesystem itself nor any other data from the device.
|
|
<P>
|
|
When used without any options, wipefs lists all visible filesystems and the
|
|
offsets of their basic signatures. The default output is subject to change.
|
|
So whenever possible, you should avoid using default outputs in your scripts.
|
|
Always explicitly define expected columns by using
|
|
<B>--output</B>
|
|
|
|
<I>columns-list</I>
|
|
|
|
in environments where a stable output is required.
|
|
<P>
|
|
<B>wipefs</B>
|
|
|
|
calls the BLKRRPART ioctl when it has erased a partition-table signature
|
|
to inform the kernel about the change. The ioctl is called as the last step
|
|
and when all specified signatures from all specified devices are already erased.
|
|
<P>
|
|
Note that some filesystems and some partition tables store more magic strings on
|
|
the device (e.g. FAT, ZFS, GPT). The
|
|
<B>wipefs</B>
|
|
|
|
command (since v2.31) lists all the offset where a magic strings have been
|
|
detected.
|
|
<P>
|
|
When option <B>-a</B> is used, all magic strings that are visible for libblkid are
|
|
erased. In this case the
|
|
<B>wipefs</B>
|
|
|
|
scans the device again after each modification (erase) until no magic string is found.
|
|
<P>
|
|
Note that by default
|
|
<B>wipefs</B>
|
|
|
|
does not erase nested partition tables on non-whole disk devices.
|
|
For this the option <B>--force</B> is required.
|
|
<P>
|
|
<A NAME="lbAE"> </A>
|
|
<H2>OPTIONS</H2>
|
|
|
|
<DL COMPACT>
|
|
<DT id="1"><B>-a</B>,<B> --all</B>
|
|
|
|
<DD>
|
|
Erase all available signatures. The set of erased signatures can be
|
|
restricted with the <B>-t</B> option.
|
|
<DT id="2"><B>-b</B>,<B> --backup</B>
|
|
|
|
<DD>
|
|
Create a signature backup to the file $HOME/wipefs-<devname>-<offset>.bak.
|
|
For more details see the <B>EXAMPLES</B> section.
|
|
<DT id="3"><B>-f</B>,<B> --force</B>
|
|
|
|
<DD>
|
|
Force erasure, even if the filesystem is mounted. This is required in
|
|
order to erase a partition-table signature on a block device.
|
|
<DT id="4"><B>-h</B>,<B> --help</B>
|
|
|
|
<DD>
|
|
Display help text and exit.
|
|
<DT id="5"><B>-J</B>,<B> --json</B>
|
|
|
|
<DD>
|
|
Use JSON output format.
|
|
<DT id="6"><B>-n</B>,<B> --noheadings</B>
|
|
|
|
<DD>
|
|
Do not print a header line.
|
|
<DT id="7"><B>-O</B>,<B> --output </B><I>list</I>
|
|
|
|
<DD>
|
|
Specify which output columns to print. Use --help to
|
|
get a list of all supported columns.
|
|
<DT id="8"><B>-n</B>,<B> --no-act</B>
|
|
|
|
<DD>
|
|
Causes everything to be done except for the write() call.
|
|
<DT id="9"><B>-o</B>,<B> --offset </B><I>offset</I>
|
|
|
|
<DD>
|
|
Specify the location (in bytes) of the signature which should be erased from the
|
|
device. The <I>offset</I> number may include a "0x" prefix; then the number will be
|
|
interpreted as a hex value. It is possible to specify multiple <B>-o</B> options.
|
|
<P>
|
|
The <I>offset</I> argument may be followed by the multiplicative
|
|
suffixes KiB (=1024), MiB (=1024*1024), and so on for GiB, TiB, PiB, EiB, ZiB and YiB
|
|
(the "iB" is optional, e.g. "K" has the same meaning as "KiB"), or the suffixes
|
|
KB (=1000), MB (=1000*1000), and so on for GB, TB, PB, EB, ZB and YB.
|
|
<DT id="10"><B>-p</B>,<B> --parsable</B>
|
|
|
|
<DD>
|
|
Print out in parsable instead of printable format. Encode all potentially unsafe
|
|
characters of a string to the corresponding hex value prefixed by '\x'.
|
|
<DT id="11"><B>-q</B>,<B> --quiet</B>
|
|
|
|
<DD>
|
|
Suppress any messages after a successful signature wipe.
|
|
<DT id="12"><B>-t</B>,<B> --types </B><I>list</I>
|
|
|
|
<DD>
|
|
Limit the set of printed or erased signatures. More than one type may
|
|
be specified in a comma-separated list. The list or individual types
|
|
can be prefixed with 'no' to specify the types on which no action should be
|
|
taken. For more details see <A HREF="/cgi-bin/man/man2html?8+mount">mount</A>(8).
|
|
<DT id="13"><B>-V</B>,<B> --version</B>
|
|
|
|
<DD>
|
|
Display version information and exit.
|
|
</DL>
|
|
<A NAME="lbAF"> </A>
|
|
<H2>EXAMPLES</H2>
|
|
|
|
<DL COMPACT>
|
|
<DT id="14"><B>wipefs /dev/sda*</B>
|
|
|
|
<DD>
|
|
Prints information about sda and all partitions on sda.
|
|
<DT id="15"><B>wipefs --all --backup /dev/sdb</B>
|
|
|
|
<DD>
|
|
Erases all signatures from the device /dev/sdb and creates a signature backup
|
|
file ~/wipefs-sdb-<offset>.bak for each signature.
|
|
<DT id="16"><B>dd if=~/wipefs-sdb-0x00000438.bak of=/dev/sdb seek=$((0x00000438)) bs=1 conv=notrunc</B>
|
|
|
|
<DD>
|
|
Restores an ext2 signature from the backup file ~/wipefs-sdb-0x00000438.bak.
|
|
</DL>
|
|
<A NAME="lbAG"> </A>
|
|
<H2>AUTHOR</H2>
|
|
|
|
Karel Zak <<A HREF="mailto:kzak@redhat.com">kzak@redhat.com</A>>
|
|
<A NAME="lbAH"> </A>
|
|
<H2>ENVIRONMENT</H2>
|
|
|
|
<DL COMPACT>
|
|
<DT id="17">LIBBLKID_DEBUG=all<DD>
|
|
enables libblkid debug output.
|
|
</DL>
|
|
<A NAME="lbAI"> </A>
|
|
<H2>SEE ALSO</H2>
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?8+blkid">blkid</A></B>(8),
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?8+findfs">findfs</A></B>(8)
|
|
|
|
<A NAME="lbAJ"> </A>
|
|
<H2>AVAILABILITY</H2>
|
|
|
|
The wipefs command is part of the util-linux package and is available from
|
|
<A HREF="https://www.kernel.org/pub/linux/utils/util-linux/.">https://www.kernel.org/pub/linux/utils/util-linux/.</A>
|
|
<P>
|
|
|
|
<HR>
|
|
<A NAME="index"> </A><H2>Index</H2>
|
|
<DL>
|
|
<DT id="18"><A HREF="#lbAB">NAME</A><DD>
|
|
<DT id="19"><A HREF="#lbAC">SYNOPSIS</A><DD>
|
|
<DT id="20"><A HREF="#lbAD">DESCRIPTION</A><DD>
|
|
<DT id="21"><A HREF="#lbAE">OPTIONS</A><DD>
|
|
<DT id="22"><A HREF="#lbAF">EXAMPLES</A><DD>
|
|
<DT id="23"><A HREF="#lbAG">AUTHOR</A><DD>
|
|
<DT id="24"><A HREF="#lbAH">ENVIRONMENT</A><DD>
|
|
<DT id="25"><A HREF="#lbAI">SEE ALSO</A><DD>
|
|
<DT id="26"><A HREF="#lbAJ">AVAILABILITY</A><DD>
|
|
</DL>
|
|
<HR>
|
|
This document was created by
|
|
<A HREF="/cgi-bin/man/man2html">man2html</A>,
|
|
using the manual pages.<BR>
|
|
Time: 00:06:18 GMT, March 31, 2021
|
|
</BODY>
|
|
</HTML>
|