doc: replace hostnames with IETF example hostnames
[openafs.git] / doc / man-pages / pod1 / fs_copyacl.pod
1 =head1 NAME
2
3 fs_copyacl - Copies an ACL from a directory to one or more other directories
4
5 =head1 SYNOPSIS
6
7 =for html
8 <div class="synopsis">
9
10 B<fs copyacl> S<<< B<-fromdir> <I<source directory (or DFS file)>> >>>
11     S<<< B<-todir> <I<destination directory (or DFS file)>>+ >>>
12     [B<-clear>] [B<-id>] [B<-if>] [-help]
13
14 B<fs co> S<<< B<-f> <I<source directory (or DFS file)>> >>>
15     S<<< B<-t> <I<destination directory (or DFS file)>>+ >>>
16     [B<-c>] [B<-id>] [B<-if>] [-h]
17
18 =for html
19 </div>
20
21 =head1 DESCRIPTION
22
23 The fs copyacl command copies the access control list (ACL) from a source
24 directory to each specified destination directory. The source directory's
25 ACL is unchanged, and changes to the destination directory's ACL obey the
26 following rules:
27
28 =over 4
29
30 =item *
31
32 If an entry on the source ACL does not already exist on the destination
33 ACL, it is added.
34
35 =item *
36
37 If an entry exists on both the source and destination ACLs, the
38 permissions from the source ACL entry replace the current permissions on
39 the destination ACL entry.
40
41 =item *
42
43 If an entry on the destination ACL has no corresponding entry on the
44 source ACL, it is removed if the B<-clear> flag is included and is
45 unchanged otherwise. In other words, if the B<-clear> flag is provided,
46 the source ACL completely replaces the destination ACL.
47
48 =back
49
50 When using this command to copy ACLs between objects in DFS filespace
51 accessed via the AFS/DFS Migration Toolkit Protocol Translator, it is
52 possible to specify files, as well as directories, with the B<-fromdir>
53 and B<-todir> arguments.
54
55 =head1 CAUTIONS
56
57 Do not copy ACLs between AFS and DFS files or directories. The ACL formats
58 are incompatible.
59
60 =head1 OPTIONS
61
62 =over 4
63
64 =item B<-fromdir> <I<source directory>>
65
66 Specifies the source directory from which to copy the ACL.  (Specifying an
67 AFS file copies its directory's ACL, but specifying a DFS file copies its
68 own ACL.) A partial pathname is interpreted relative to the current
69 working directory.
70
71 =item B<-todir> <I<destination directory>>
72
73 Specifies each directory for which to alter the ACL to match the source
74 ACL. (Specifying an AFS file halts the command with an error, but
75 specifying a DFS file alters the file's ACL). A partial pathname is
76 interpreted relative to the current working directory.
77
78 Specify the read/write path to each directory (or DFS file), to avoid the
79 failure that results from attempting to change a read-only volume. By
80 convention, the read/write path is indicated by placing a period before
81 the cell name at the pathname's second level (for example,
82 C</afs/.example.com>). For further discussion of the concept of read/write and
83 read-only paths through the filespace, see the B<fs mkmount> reference
84 page.
85
86 =item B<-clear>
87
88 Replaces the ACL of each destination directory with the source ACL.
89
90 =item B<-id>
91
92 Modifies the Initial Container ACL of each DFS directory named by the
93 B<-todir> argument, rather than the regular Object ACL. This argument is
94 supported only when both the source and each destination directory reside
95 in DFS and are accessed via the AFS/DFS Migration Toolkit Protocol
96 Translator.
97
98 =item B<-if>
99
100 Modifies the Initial Object ACL of each DFS directory named by the
101 B<-todir> argument, rather than the regular Object ACL. This argument is
102 supported only when both the source and each destination directory reside
103 in DFS and are accessed via the AFS/DFS Migration Toolkit Protocol
104 Translator.
105
106 =item B<-help>
107
108 Prints the online help for this command. All other valid options are
109 ignored.
110
111 =back
112
113 =head1 EXAMPLES
114
115 The following example command copies the current working directory's ACL
116 to its subdirectory called F<reports>. Note that the source directory's
117 ACL is unaffected. Entries on the F<reports> directory's that are not on
118 the source ACL of the current directory remain unaffected as well, because
119 the B<-clear> flag is not used.
120
121    % fs listacl . reports
122    Access list for . is
123    Normal rights:
124       pat rlidwka
125       smith rlidwk
126    Access list for reports is
127    Normal rights:
128       pat rl
129       pat:friends rl
130    Negative rights
131       jones rlidwka
132
133    % fs copyacl -fromdir . -todir reports
134
135    % fs listacl . reports
136    Access list for . is
137    Normal rights:
138       pat rlidwka
139       smith rlidwk
140    Access list for reports is
141    Normal rights:
142       pat rlidwka
143       pat:friends rl
144       smith rlidwk
145    Negative rights
146       jones rlidwka
147
148 =head1 PRIVILEGE REQUIRED
149
150 To copy an ACL between AFS objects, the issuer must have the C<l> (lookup)
151 permission on the source directory's ACL and the C<a> (administer)
152 permission on each destination directory's ACL. If the B<-fromdir>
153 argument names a file rather than a directory, the issuer must have both
154 the C<l> and C<r> (read) permissions on the ACL of the file's directory.
155
156 To copy an ACL between DFS objects, the issuer must have the r permission
157 on the source directory or file's ACL and the C<c> (control) permission on
158 each destination directory or file's ACL.
159
160 =head1 SEE ALSO
161
162 L<fs_listacl(1)>,
163 L<fs_mkmount(1)>,
164 L<fs_setacl(1)>
165
166 =head1 COPYRIGHT
167
168 IBM Corporation 2000. <http://www.ibm.com/> All Rights Reserved.
169
170 This documentation is covered by the IBM Public License Version 1.0.  It was
171 converted from HTML to POD by software written by Chas Williams and Russ
172 Allbery, based on work by Alf Wachsmann and Elizabeth Cassell.