1 .\" Copyright (C) 2002, 2004, 2007 Silicon Graphics, Inc. All rights reserved.
2 .\" Copyright (C) 2002, 2004, 2007 Andreas Gruenbacher <agruen@suse.de>
4 .\" This is free documentation; you can redistribute it and/or
5 .\" modify it under the terms of the GNU General Public License as
6 .\" published by the Free Software Foundation; either version 2 of
7 .\" the License, or (at your option) any later version.
9 .\" The GNU General Public License's references to "object code"
10 .\" and "executables" are to be interpreted as the output of any
11 .\" document formatting or typesetting system, including
12 .\" intermediate and printed output.
14 .\" This manual is distributed in the hope that it will be useful,
15 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
16 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 .\" GNU General Public License for more details.
19 .\" You should have received a copy of the GNU General Public
20 .\" License along with this manual. If not, see
21 .\" <http://www.gnu.org/licenses/>.
23 .TH GETFATTR 1 "Extended Attributes" "Dec 2001" "File Utilities"
25 getfattr \- get extended attributes of filesystem objects
28 \f3getfattr\f1 [\f3\-hRLP\f1] \f3\-n name\f1 [\f3\-e en\f1] \c
30 \f3getfattr\f1 [\f3\-hRLP\f1] \f3\-d\f1 [\f3\-e en\f1] \c
31 [\f3\-m pattern\f1] \f3pathname\f1...
36 displays the file name,
37 and the set of extended attribute names (and optionally values) which
38 are associated with that file.
47 2: user.name0="value0"
48 3: user.name1="value1"
49 4: user.name2="value2"
55 Line 1 identifies the file name for which the
56 following lines are being reported.
57 The remaining lines (lines 2 to 4 above) show the
61 pairs associated with the specified file.
64 .BR \-n " \f2name\f1, " \-\-name "=\f2name\f1"
65 Dump the value of the named extended attribute extended attribute.
68 Dump the values of all extended attributes associated with
71 .BR \-e " \f2en\f1, " \-\-encoding "=\f2en\f1"
72 Encode values after retrieving them.
75 are "text", "hex", and "base64".
76 Values encoded as text strings are enclosed in double quotes ("),
77 while strings encoded as hexidecimal and base64 are prefixed with
78 0x and 0s, respectively.
80 .BR \-h ", " \-\-no-dereference
81 Do not dereference symlinks. Instead of the file a symlink refers to, the
82 symlink itself is examined.
84 .BR \-m " \f2pattern\f1, " \-\-match "=\f2pattern\f1"
85 Only include attributes with names matching the regular expression
90 which includes all the attributes in the user namespace. Specify "\-" for
91 including all attributes. Refer to
93 for a more detailed discussion of namespaces.
96 Do not strip leading slash characters ('/').
97 The default behaviour is to strip leading slash characters.
100 Dump out the extended attribute value(s) only.
102 .BR \-R ", " \-\-recursive
103 List the attributes of all files and directories recursively.
105 .BR \-L ", " \-\-logical
106 Logical walk, follow symbolic links to directories.
107 The default behaviour is to follow symbolic link arguments, and to
108 skip symbolic links encountered in subdirectories.
109 Only effective in combination with \-R.
111 .BR \-P ", " \-\-physical
112 Physical walk, do not follow symbolic links to directories.
113 This also skips symbolic link arguments.
114 Only effective in combination with \-R.
122 Print help explaining the command line options.
125 End of command line options.
126 All remaining parameters are interpreted as file names, even if they
127 start with a dash character.
130 .RI < a.gruenbacher@bestbits.at >
131 and the SGI XFS development team,
132 .RI < linux-xfs@oss.sgi.com >.
134 Please send your bug reports or comments to these addresses.
136 setfattr(1), and attr(5).