1STAT(1)                          User Commands                         STAT(1)
2
3
4

NAME

6       stat - display file or file system status
7

SYNOPSIS

9       stat [OPTION]... FILE...
10

DESCRIPTION

12       Display file or file system status.
13
14       Mandatory  arguments  to  long  options are mandatory for short options
15       too.
16
17       -L, --dereference
18              follow links
19
20       -f, --file-system
21              display file system status instead of file status
22
23       -c  --format=FORMAT
24              use the specified FORMAT instead of the default; output  a  new‐
25              line after each use of FORMAT
26
27       --printf=FORMAT
28              like  --format, but interpret backslash escapes, and do not out‐
29              put a mandatory trailing newline; if you want a newline, include
30              \n in FORMAT
31
32       -t, --terse
33              print the information in terse form
34
35       --help display this help and exit
36
37       --version
38              output version information and exit
39
40       The valid format sequences for files (without --file-system):
41
42       %a     access rights in octal (note '#' and '0' printf flags)
43
44       %A     access rights in human readable form
45
46       %b     number of blocks allocated (see %B)
47
48       %B     the size in bytes of each block reported by %b
49
50       %C     SELinux security context string
51
52       %d     device number in decimal
53
54       %D     device number in hex
55
56       %f     raw mode in hex
57
58       %F     file type
59
60       %g     group ID of owner
61
62       %G     group name of owner
63
64       %h     number of hard links
65
66       %i     inode number
67
68       %m     mount point
69
70       %n     file name
71
72       %N     quoted file name with dereference if symbolic link
73
74       %o     optimal I/O transfer size hint
75
76       %s     total size, in bytes
77
78       %t     major  device  type  in  hex, for character/block device special
79              files
80
81       %T     minor device type in hex,  for  character/block  device  special
82              files
83
84       %u     user ID of owner
85
86       %U     user name of owner
87
88       %w     time of file birth, human-readable; - if unknown
89
90       %W     time of file birth, seconds since Epoch; 0 if unknown
91
92       %x     time of last access, human-readable
93
94       %X     time of last access, seconds since Epoch
95
96       %y     time of last data modification, human-readable
97
98       %Y     time of last data modification, seconds since Epoch
99
100       %z     time of last status change, human-readable
101
102       %Z     time of last status change, seconds since Epoch
103
104       Valid format sequences for file systems:
105
106       %a     free blocks available to non-superuser
107
108       %b     total data blocks in file system
109
110       %c     total file nodes in file system
111
112       %d     free file nodes in file system
113
114       %f     free blocks in file system
115
116       %i     file system ID in hex
117
118       %l     maximum length of filenames
119
120       %n     file name
121
122       %s     block size (for faster transfers)
123
124       %S     fundamental block size (for block counts)
125
126       %t     file system type in hex
127
128       %T     file system type in human readable form
129
130   --terse is equivalent to the following FORMAT:
131              %n %s %b %f %u %g %D %i %h %t %T %X %Y %Z %W %o %C
132
133   --terse --file-system is equivalent to the following FORMAT:
134              %n %i %l %t %s %S %b %f %a %c %d
135
136       NOTE: your shell may have its own version of stat, which usually super‐
137       sedes the version described here.  Please refer to your  shell's  docu‐
138       mentation for details about the options it supports.
139

AUTHOR

141       Written by Michael Meskes.
142

REPORTING BUGS

144       GNU coreutils online help: <https://www.gnu.org/software/coreutils/>
145       Report any translation bugs to <https://translationproject.org/team/>
146
148       Copyright  ©  2019  Free Software Foundation, Inc.  License GPLv3+: GNU
149       GPL version 3 or later <https://gnu.org/licenses/gpl.html>.
150       This is free software: you are free  to  change  and  redistribute  it.
151       There is NO WARRANTY, to the extent permitted by law.
152

SEE ALSO

154       stat(2), statfs(2)
155
156       Full documentation <https://www.gnu.org/software/coreutils/stat>
157       or available locally via: info '(coreutils) stat invocation'
158
159
160
161GNU coreutils 8.31                March 2019                           STAT(1)
Impressum