Penguin
Annotated edit history of chattr(1) version 2, including all changes. View license author blame.
Rev Author # Line
1 perry 1 CHATTR
2 !!!CHATTR
3 NAME
4 SYNOPSIS
5 DESCRIPTION
6 OPTIONS
7 ATTRIBUTES
8 AUTHOR
9 BUGS AND LIMITATIONS
10 AVAILABILITY
11 SEE ALSO
12 ----
13 !!NAME
14
15
16 chattr - change file attributes on a Linux second extended file system
17 !!SYNOPSIS
18
19
20 __chattr__ [[ __-RV__ ] [[ __-v__ ''version'' ] [[
21 ''mode'' ] ''files...''
22 !!DESCRIPTION
23
24
25 __chattr__ changes the file attributes on a Linux second
26 extended file system.
27
28
29 The format of a symbolic mode is
30 +-=[[ASacdistu].
31
32
33 The operator `+' causes the selected attributes to be added
34 to the existing attributes of the files; `-' causes them to
35 be removed; and `=' causes them to be the only attributes
36 that the files have.
37
38
39 The letters `ASacdijsu' select the new attributes for the
40 files: don't update atime (A), synchronous updates (S),
41 append only (a), compressed (c), no dump (d), immutable (i),
42 data journalling (j), secure deletion (s), and undeletable
43 (u).
44 !!OPTIONS
45
46
47 __-R__
48
49
50 Recursively change attributes of directories and their
51 contents. Symbolic links encountered during recursive
52 directory traversals are ignored.
53
54
55 __-V__
56
57
58 Be verbose with chattr's output and print the program
59 version.
60
61
62 __-v__ ''version''
63
64
65 Set the file's version/generation number.
66 !!ATTRIBUTES
67
68
69 When a file with the 'A' attribute set is modified, its
70 atime record is not modified. This avoids a certain amount
71 of disk I/O for laptop systems.
72
73
74 A file with the `a' attribute set can only be open in append
75 mode for writing. Only the superuser can set or clear this
76 attribute.
77
78
79 A file with the `c' attribute set is automatically
80 compressed on the disk by the kernel. A read from this file
81 returns uncompressed data. A write to this file compresses
82 data before storing them on the disk.
83
84
85 A file with the `d' attribute set is not candidate for
86 backup when the dump(8) program is run.
87
88
89 A file with the `i' attribute cannot be modified: it cannot
90 be deleted or renamed, no link can be created to this file
91 and no data can be written to the file. Only the superuser
92 can set or clear this attribute.
93
94
95 A file with the `j' attribute has all of its data written to
96 the ext3 journal before being written to the file itself, if
97 the filesystem is mounted with the
98
99
100 When a file with the `s' attribute set is deleted, its
101 blocks are zeroed and written back to the disk.
102
103
104 When a file with the `S' attribute set is modified, the
105 changes are written synchronously on the disk; this is
106 equivalent to the `sync' mount option applied to a subset of
107 the files.
108
109
110 A file with the 't' attribute will not have a partial block
111 fragment at the of the file merged with other files (for
112 those filesystems which support tail-merging). This is
113 necessary for applications such as LILO which read the
114 filesystem directly, and who don't understand tail-merged
115 files.
116
117
118 When a file with the `u' attribute set is deleted, its
119 contents are saved. This allows the user to ask for its
120 undeletion.
2 JohnHewitt 121 At current only the ext2 file system supports this flag. No known kernel actually yet supports backing up the file though.
1 perry 122 !!AUTHOR
123
124
125 __chattr__ was written by Remy Card
126 __
127 !!BUGS AND LIMITATIONS
128
129
130 As of Linux 2.2, the `c', 's', and `u' attribute are not
131 honored by the kernel filesystem code. These attributes will
132 be implemented in a future ext2 fs version.
133
134
135 The `j' option is only useful if the filesystem is mounted
136 as ext3.
137 !!AVAILABILITY
138
139
140 __chattr__ is part of the e2fsprogs package and is
141 available from
142 http://e2fsprogs.sourceforge.net.
143 !!SEE ALSO
144
145
146 lsattr(1)
147 ----
This page is a man page (or other imported legacy content). We are unable to automatically determine the license status of this page.