man-pages/man8/ntfstruncate.8.html
2021-03-31 01:06:50 +01:00

177 lines
5.7 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML><HEAD><TITLE>Man page of NTFSTRUNCATE</TITLE>
</HEAD><BODY>
<H1>NTFSTRUNCATE</H1>
Section: Maintenance Commands (8)<BR>Updated: June 2014<BR><A HREF="#index">Index</A>
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
<A NAME="lbAB">&nbsp;</A>
<H2>NAME</H2>
ntfstruncate - truncate a file on an NTFS volume
<A NAME="lbAC">&nbsp;</A>
<H2>SYNOPSIS</H2>
<B>ntfstruncate</B> [<I>options</I>] <I>device</I> <I>file</I> <I>[attr-type</I> [<I>attr-name</I>]] <I>new-length</I>
<A NAME="lbAD">&nbsp;</A>
<H2>DESCRIPTION</H2>
<B>ntfstruncate</B>
truncates (or extends) a specified attribute belonging to a
file or directory, to a specified length.
<A NAME="lbAE">&nbsp;</A>
<H2>OPTIONS</H2>
Below is a summary of all the options that
<B>ntfstruncate</B>
accepts. Nearly all options have two equivalent names. The short name is
preceded by
<B>-</B>
and the long name is preceded by
<B>--</B>.
Any single letter options, that don't take an argument, can be combined into a
single command, e.g.
<B>-fv</B>
is equivalent to
<B>-f -v</B>.
Long named options can be abbreviated to any unique prefix of their name.
<DL COMPACT>
<DT id="1"><B>-f</B>, <B>--force</B><DD>
This will override some sensible defaults, such as not using a mounted volume.
Use this option with caution.
<DT id="2"><B>-h</B>, <B>--help</B><DD>
Show a list of options with a brief description of each one.
<DT id="3"><B>-l</B><DD>
Display licensing information.
<DT id="4"><B>-n</B>, <B>--no-action</B><DD>
Simulate the truncation without actually write to device.
<DT id="5"><B>-q</B>, <B>--quiet</B><DD>
Suppress some debug/warning/error messages.
<DT id="6"><B>-v</B>, <B>--verbose</B><DD>
Display more debug/warning/error messages.
<DT id="7"><B>-V</B>, <B>--version</B><DD>
Show the version number, copyright and license of
<B>ntfstruncate</B>.
<DT id="8"><B>attr-type</B><DD>
Define a particular attribute type to be truncated (advanced use only).
By default, the unnamed $DATA attribute (the contents of a plain file) will
be truncated. The attribute has to be specified by a number in decimal
or hexadecimal :
<TABLE BORDER><TR><TD><TABLE>
<TR VALIGN=top><TD><B>Hex</B></TD><TD><B>Decimal</B></TD><TD><B>Name</B><BR></TD></TR>
<TR VALIGN=top><TD>0x10</TD><TD>16</TD><TD>&quot;$STANDARD_INFORMATION&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0x20</TD><TD>32</TD><TD>&quot;$ATTRIBUTE_LIST&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0x30</TD><TD>48</TD><TD>&quot;$FILE_NAME&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0x40</TD><TD>64</TD><TD>&quot;$OBJECT_ID&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0x50</TD><TD>80</TD><TD>&quot;$SECURITY_DESCRIPTOR&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0x60</TD><TD>96</TD><TD>&quot;$VOLUME_NAME&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0x70</TD><TD>112</TD><TD>&quot;$VOLUME_INFORMATION&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0x80</TD><TD>128</TD><TD>&quot;$DATA&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0x90</TD><TD>144</TD><TD>&quot;$INDEX_ROOT&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0xA0</TD><TD>160</TD><TD>&quot;$INDEX_ALLOCATION&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0xB0</TD><TD>176</TD><TD>&quot;$BITMAP&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0xC0</TD><TD>192</TD><TD>&quot;$REPARSE_POINT&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0xD0</TD><TD>208</TD><TD>&quot;$EA_INFORMATION&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0xE0</TD><TD>224</TD><TD>&quot;$EA&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0xF0</TD><TD>240</TD><TD>&quot;$PROPERTY_SET&quot;<BR></TD></TR>
<TR VALIGN=top><TD>0x100</TD><TD>256</TD><TD>&quot;$LOGGED_UTILITY_STREAM&quot;<BR></TD></TR>
</TABLE></TABLE>
<P>
<DT id="9"><B>attr-name</B><DD>
Define the name of the particular attribute type to be truncated
(advanced use only).
<P>
<DT id="10"><B>new-length</B><DD>
Specify the target size of the file.
It will be rounded up to a multiple of the cluster size.
A suffix of K, M, G, T, P or E may be appended to
mean a multiplicative factor of a power of 1000. Similarly a suffix of
Ki, Mi, Gi, Ti, Pi or Ei may be appended to mean a multiplicative factor
of a power of 1024.
</DL>
<A NAME="lbAF">&nbsp;</A>
<H2>EXAMPLES</H2>
Resize to 100MB the file database.db located in the Data directory
which is at the root of an NTFS file system.
<DL COMPACT><DT id="11"><DD>
<P>
<B>ntfstruncate /dev/sda1 Data/database.db 100M</B>
<P>
</DL>
<A NAME="lbAG">&nbsp;</A>
<H2>BUGS</H2>
There are no known problems with
<B>ntfstruncate</B>.
If you find a bug, please send an email
describing the problem to the development team:
<BR>
<A HREF="mailto:ntfs-3g-devel@lists.sf.net">ntfs-3g-devel@lists.sf.net</A>
<A NAME="lbAH">&nbsp;</A>
<H2>AUTHORS</H2>
<B>ntfstruncate</B>
was written by Anton Altaparmakov.
<A NAME="lbAI">&nbsp;</A>
<H2>AVAILABILITY</H2>
<B>ntfstruncate</B>
is part of the
<B>ntfs-3g</B>
package and is available from:
<BR>
<A HREF="http://www.tuxera.com/community/">http://www.tuxera.com/community/</A>
<A NAME="lbAJ">&nbsp;</A>
<H2>SEE ALSO</H2>
<B><A HREF="/cgi-bin/man/man2html?8+ntfs-3g">ntfs-3g</A></B>(8),
<B><A HREF="/cgi-bin/man/man2html?8+ntfsfallocate">ntfsfallocate</A></B>(8),
<B><A HREF="/cgi-bin/man/man2html?8+ntfsprogs">ntfsprogs</A></B>(8).
<P>
<HR>
<A NAME="index">&nbsp;</A><H2>Index</H2>
<DL>
<DT id="12"><A HREF="#lbAB">NAME</A><DD>
<DT id="13"><A HREF="#lbAC">SYNOPSIS</A><DD>
<DT id="14"><A HREF="#lbAD">DESCRIPTION</A><DD>
<DT id="15"><A HREF="#lbAE">OPTIONS</A><DD>
<DT id="16"><A HREF="#lbAF">EXAMPLES</A><DD>
<DT id="17"><A HREF="#lbAG">BUGS</A><DD>
<DT id="18"><A HREF="#lbAH">AUTHORS</A><DD>
<DT id="19"><A HREF="#lbAI">AVAILABILITY</A><DD>
<DT id="20"><A HREF="#lbAJ">SEE ALSO</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:14 GMT, March 31, 2021
</BODY>
</HTML>