6253 F_GETLK doesn't always return lock owner
[illumos-gate.git] / usr / src / man / man1m / cachefspack.1m
blobccc602fb042d67672590cc59ad6cad64d746aac3
1 '\" te
2 .\"  Copyright (c) 2004, Sun Microsystems, Inc. All Rights Reserved
3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
5 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 .TH CACHEFSPACK 1M "Mar 18, 2004"
7 .SH NAME
8 cachefspack \- pack files and file systems in the cache
9 .SH SYNOPSIS
10 .LP
11 .nf
12 \fBcachefspack\fR [\fB-h\fR] [\fB-i\fR | \fB-p\fR | \fB-u\fR] [\fB-f\fR \fIpacking-list\fR]
13      [\fB-U\fR \fIcache-directory\fR] [\fIfile\fR]...
14 .fi
16 .SH DESCRIPTION
17 .sp
18 .LP
19 The \fBcachefspack\fR utility is used to set up and maintain files in the
20 cache. This utility affords greater control over the cache, ensuring that the
21 specified files are in the cache whenever possible.
22 .sp
23 .LP
24 \fBcachefspack\fR does not pack files when the backfileystem type for the
25 \fBcachefs\fR mount is NFSv4. This is because only pass-through support is
26 available for \fBcachefs\fR with NFSv4.
27 .SH OPTIONS
28 .sp
29 .LP
30 The following options are supported:
31 .sp
32 .ne 2
33 .na
34 \fB\fB\fR\fB-f\fR\fB \fR\fIpacking-list\fR\fR
35 .ad
36 .RS 22n
37 Specify a file containing a list of files and directories to be packed. Options
38 within subdirectories and files can also be specified. The format and rules
39 governing \fIpacking-list\fR are described on the \fBpackingrules\fR(4) manual
40 page. Directories are packed recursively. Symlinks that match a regular
41 expression on a \fBLIST\fR command are followed. Symlinks encountered while
42 recursively processing directories are not followed.
43 .RE
45 .sp
46 .ne 2
47 .na
48 \fB\fB-h\fR\fR
49 .ad
50 .RS 22n
51 Help. Print a brief summary of all the options.
52 .RE
54 .sp
55 .ne 2
56 .na
57 \fB\fB-i\fR\fR
58 .ad
59 .RS 22n
60 View information about the packed files.
61 .RE
63 .sp
64 .ne 2
65 .na
66 \fB\fB-p\fR\fR
67 .ad
68 .RS 22n
69 Pack the file or files specified by \fBfile\fR. This is the default behavior.
70 .RE
72 .sp
73 .ne 2
74 .na
75 \fB\fB-u\fR\fR
76 .ad
77 .RS 22n
78 Unpack the file or files specified by \fBfile\fR.
79 .RE
81 .sp
82 .ne 2
83 .na
84 \fB\fB\fR\fB-U\fR\fB \fR\fIcache-directory\fR\fR
85 .ad
86 .RS 22n
87 Unpack all files in the specified cache directory.
88 .RE
90 .SH OPERANDS
91 .sp
92 .LP
93 The following operands are supported:
94 .sp
95 .ne 2
96 .na
97 \fB\fBfile\fR\fR
98 .ad
99 .RS 8n
100 A path name of a file to be packed or unpacked.
103 .SH USAGE
106 See \fBlargefile\fR(5) for the description of the behavior of \fBcachefspack\fR
107 when encountering files greater than or equal to 2 Gbyte ( 2^31 bytes).
108 .SH EXAMPLES
110 \fBExample 1 \fRPacking a File in the Cache
113 The following example packs the file \fBprojects\fR in the cache:
116 .in +2
118 % cachefspack \fB-p\fR projects
120 .in -2
124 \fBExample 2 \fRPackint Files in the Cache
127 The following example packs the files \fBprojects\fR, \fBupdates\fR, and
128 \fBmaster_plan\fR in the cache:
131 .in +2
133 % cachefspack \fB-p\fR projects updates master_plan
135 .in -2
139 \fBExample 3 \fRUnpacking a File From the Cache
142 The following example unpacks the file \fBprojects\fR from the cache:
145 .in +2
147 % cachefspack \fB-u\fR projects
149 .in -2
153 \fBExample 4 \fRUnpacking Files From the Cache
156 The following example unpacks the files \fBprojects\fR, \fBupdates\fR, and
157 \fBmaster_plan\fR from the cache:
160 .in +2
162 % cachefspack \fB-u\fR projects updates master_plan
164 .in -2
168 \fBExample 5 \fRUnpacking All Files From in a Cache Directory
171 The following example unpacks all files in the cache directory \fBcache1\fR:
174 .in +2
176 % cachefspack \fB-U\fR /cache/cache1
178 .in -2
182 \fBExample 6 \fRUsing a Packing List
185 The following example illustrates the use of a packing list to specify files to
186 be packed in the cache.
190 The contents of \fBlists.pkg\fR are as follows:
193 .in +2
195 IGNORE SCCS BASE /src/junk LIST *.c LIST *.h
197 .in -2
202 The following command packs all files in the \fB/src/junk\fR directory which
203 have \fB\&.c\fR and \fB\&.h\fR extensions, and do contain the string SCCS in
204 the file's path name:
207 .in +2
209 % cachefspack \fB-f\fR lists.pkg
211 .in -2
214 .SH EXIT STATUS
216 .ne 2
218 \fB\fB0\fR\fR
220 .RS 6n
221 Successful completion.
225 .ne 2
227 \fB\fB>0\fR\fR
229 .RS 6n
230 An error occurred.
233 .SH SEE ALSO
236 \fBcfsadmin\fR(1M), \fBmount_cachefs\fR(1M), \fBpackingrules\fR(4),
237 \fBattributes\fR(5), \fBlargefile\fR(5)