1 .\" Copyright (C) 2002, 2004 Silicon Graphics, Inc. Al rights reserved.
2 .\" Copyright (C) 2002, 2004 Andreas Gruenbacher <agruen@suse.de>
4 .\" You should have received a copy of the GNU General Public License
5 .\" along with this program. If not, see <http://www.gnu.org/licenses/>.
7 .\" This is free documentation; you can redistribute it and/or
8 .\" modify it under the terms of the GNU General Public License as
9 .\" published by the Free Software Foundation; either version 2 of
10 .\" the License, or (at your option) any later version.
12 .\" The GNU General Public License's references to "object code"
13 .\" and "executables" are to be interpreted as the output of any
14 .\" document formatting or typesetting system, including
15 .\" intermediate and printed output.
17 .\" This manual is distributed in the hope that it will be useful,
18 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
19 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 .\" GNU General Public License for more details.
22 .\" You should have received a copy of the GNU General Public
23 .\" License along with this manual. If not, see
24 .\" <http://www.gnu.org/licenses/>.
26 .TH SETFATTR 1 "Extended Attributes" "Dec 2001" "File Utilities"
28 setfattr \- set extended attributes of filesystem objects
31 \f3setfattr\f1 [\f3\-h\f1] \f3\-n name\f1 [\f3\-v value\f1] \f3pathname\f1...
32 \f3setfattr\f1 [\f3\-h\f1] \f3\-x name\f1 \f3pathname\f1...
33 \f3setfattr\f1 [\f3\-h\f1] \f3\-\-restore=file\f1
38 command associates a new
40 with an extended attribute
42 for each specified file.
45 .BR \-n " \f2name\f1, " \-\-name "=\f2name\f1"
46 Specifies the name of the extended attribute to set.
48 .BR \-v " \f2value\f1, " \-\-value "=\f2value\f1"
49 Specifies the new value of the extended attribute. There are three methods
50 available for encoding the value. If the given string is enclosed in double
51 quotes, the inner string is treated as text. In that case, backslashes and
52 double quotes have special meanings and need to be escaped by a preceding
53 backslash. Any control characters can be encoded as a backslash followed by
54 three digits as its ASCII code in octal. If the given string begins with 0x or
55 0X, it expresses a hexadecimal number. If the given string begins with 0s or
56 0S, base64 encoding is expected. See also the \-\-encoding option of
59 .BR \-x " \f2name\f1, " \-\-remove "=\f2name\f1"
60 Remove the named extended attribute entirely.
62 .BR \-h ", " \-\-no-dereference
63 Do not follow symlinks. If
65 is a symbolic link, it is not followed, but is instead itself the
68 .BR \-\-restore =\f2file\f1
69 Restores extended attributes from file.
70 The file must be in the format generated by the
77 is given as the file name,
79 reads from standard input.
87 Print help explaining the command line options.
90 End of command line options.
91 All remaining parameters are interpreted as file names, even if they
92 start with a dash character.
95 .RI < a.gruenbacher@bestbits.at >
96 and the SGI XFS development team,
97 .RI < linux-xfs@oss.sgi.com >.
99 Please send your bug reports or comments to these addresses.
101 getfattr(1), and attr(5).