|
|
1.1 root 1:
2:
3:
4: PPPPAAAAXXXX((((1111)))) CCCCOOOOHHHHEEEERRRREEEENNNNTTTT PPPPAAAAXXXX((((1111))))
5:
6:
7:
8: NNNNAAAAMMMMEEEE
9: pax - portable archive exchange
10:
11: SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
12: ppppaaaaxxxx [----cccciiiimmmmooooppppuuuuvvvvyyyy] [----ffff _a_r_c_h_i_v_e] [----ssss _r_e_p_l_s_t_r] [----tttt _d_e_v_i_c_e]
13: [_p_a_t_t_e_r_n...]
14:
15: ppppaaaaxxxx ----rrrr [----cccciiiimmmmnnnnooooppppuuuuvvvvyyyy] [----ffff _a_r_c_h_i_v_e] [----ssss _r_e_p_l_s_t_r] [----tttt _d_e_v_i_c_e]
16: [_p_a_t_t_e_r_n...]
17:
18: ppppaaaaxxxx ----wwww [----aaaaddddiiiimmmmuuuuvvvvyyyy] [----bbbb _b_l_o_c_k_i_n_g] [----ffff _a_r_c_h_i_v_e] [----ssss _r_e_p_l_s_t_r]
19: [----tttt _d_e_v_i_c_e] [----xxxx _f_o_r_m_a_t] [_p_a_t_h_n_a_m_e...]
20:
21: ppppaaaaxxxx ----rrrrwwww [----iiiillllmmmmooooppppuuuuvvvvyyyy] [----ssss _r_e_p_l_s_t_r] [_p_a_t_h_n_a_m_e...] directory
22:
23: DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
24: _P_a_x reads and writes archive files which conform to the
25: AAAArrrrcccchhhhiiiivvvveeee////IIIInnnntttteeeerrrrcccchhhhaaaannnnggggeeee FFFFiiiilllleeee FFFFoooorrrrmmmmaaaatttt specified in _I_E_E_E _S_t_d.
26: _1_0_0_3._1-_1_9_8_8. _P_a_x can also read, but not write, a number of
27: other file formats in addition to those specified in the
28: AAAArrrrcccchhhhiiiivvvveeee////IIIInnnntttteeeerrrrcccchhhhaaaannnnggggeeee FFFFiiiilllleeee FFFFoooorrrrmmmmaaaatttt description. Support for
29: these traditional file formats, such as V7 _t_a_r and System V
30: binary _c_p_i_o format archives, is provided for backward
31: compatibility and to maximize portability.
32:
33: _P_a_x will also support traditional _c_p_i_o and System V _t_a_r
34: interfaces if invoked with the name "cpio" or "tar"
35: respectively. See the _c_p_i_o(_1) or _t_a_r(_1) manual pages for
36: more details.
37:
38: Combinations of the ----rrrr and ----wwww command line arguments specify
39: whether _p_a_x will read, write or list the contents of the
40: specified archive, or move the specified files to another
41: directory.
42:
43: The command line arguments are:
44:
45: ----wwww writes the files and directories specified by _p_a_t_h_n_a_m_e
46: operands to the standard output together with the
47: pathname and status information prescribed by the
48: archive format used. A directory _p_a_t_h_n_a_m_e operand
49: refers to the files and (recursively) subdirectories of
50: that directory. If no _p_a_t_h_n_a_m_e operands are given,
51: then the standard input is read to get a list of
52: pathnames to copy, one pathname per line. In this
53: case, only those pathnames appearing on the standard
54: input are copied.
55:
56: ----rrrr _P_a_x reads an archive file from the standard input.
57: Only files with names that match any of the _p_a_t_t_e_r_n
58: operands are selected for extraction. The selected
59: files are conditionally created and copied relative to
60:
61:
62:
63: Page 1 (printed 10/10/90)
64:
65:
66:
67:
68:
69:
70: PPPPAAAAXXXX((((1111)))) CCCCOOOOHHHHEEEERRRREEEENNNNTTTT PPPPAAAAXXXX((((1111))))
71:
72:
73:
74: the current directory tree, subject to the options
75: described below. By default, the owner and group of
76: selected files will be that of the invoking process,
77: and the permissions and modification times will be the
78: sames as those in the archive.
79:
80: The supported archive formats are automatically
81: detected on input. The default output format is _u_s_t_a_r,
82: but may be overridden by the ----xxxx _f_o_r_m_a_t option described
83: below.
84:
85: ----rrrrwwww _P_a_x reads the files and directories named in the
86: _p_a_t_h_n_a_m_e operands and copies them to the destination
87: _d_i_r_e_c_t_o_r_y. A directory _p_a_t_h_n_a_m_e operand refers to the
88: files and (recursively) subdirectories of that
89: directory. If no _p_a_t_h_n_a_m_e operands are given, the
90: standard input is read to get a list of pathnames to
91: copy, one pathname per line. In this case, only those
92: pathnames appearing on the standard input are copied.
93: The directory named by the _d_i_r_e_c_t_o_r_y operand must exist
94: and have the proper permissions before the copy can
95: occur.
96:
97: If neither the ----rrrr or ----wwww options are given, then _p_a_x will
98: list the contents of the specified archive. In this mode,
99: _p_a_x lists normal files one per line, hard link pathnames as
100:
101: _p_a_t_h_n_a_m_e == _l_i_n_k_n_a_m_e
102:
103: and symbolic link pathnames (if supported by the
104: implementation) as
105:
106: _p_a_t_h_n_a_m_e -> _l_i_n_k_n_a_m_e
107:
108: where _p_a_t_h_n_a_m_e is the name of the file being extracted, and
109: _l_i_n_k_n_a_m_e is the name of a file which appeared earlier in the
110: archive.
111:
112: If the ----vvvv option is specified, then _p_a_x list normal
113: pathnames in the same format used by the _l_s utility with the
114: ----llll option. Hard links are shown as
115:
116: <_l_s -_l _l_i_s_t_i_n_g> == _l_i_n_k_n_a_m_e
117:
118: and symbolic links (if supported) are shown as
119:
120: <_l_s -_l _l_i_s_t_i_n_g> -> _l_i_n_k_n_a_m_e
121:
122:
123: _P_a_x is capable of reading and writing archives which span
124: multiple physical volumes. Upon detecting an end of medium
125: on an archive which is not yet completed, _p_a_x will prompt
126:
127:
128:
129: Page 2 (printed 10/10/90)
130:
131:
132:
133:
134:
135:
136: PPPPAAAAXXXX((((1111)))) CCCCOOOOHHHHEEEERRRREEEENNNNTTTT PPPPAAAAXXXX((((1111))))
137:
138:
139:
140: the user for the next volume of the archive and will allow
141: the user to specify the location of the next volume.
142:
143: OOOOppppttttiiiioooonnnnssss
144: The following options are available:
145:
146: ----aaaa The files specified by _p_a_t_h_n_a_m_e are appended to
147: the specified archive.
148:
149: ----bbbb _b_l_o_c_k_i_n_g
150: Block the output at _b_l_o_c_k_i_n_g bytes per write to
151: the archive file. A kkkk suffix multiplies _b_l_o_c_k_i_n_g
152: by 1024, a bbbb suffix multiplies _b_l_o_c_k_i_n_g by 512 and
153: a mmmm suffix multiplies _b_l_o_c_k_i_n_g by 1048576 (1
154: megabyte). For machines with 16-bit int's (VAXen,
155: XENIX-286, etc.), the maximum buffer size is 32k-
156: 1. If not specified, _b_l_o_c_k_i_n_g is automatically
157: determined on input and is ignored for ----rrrrwwww....
158:
159: ----cccc Complement the match sense of the _p_a_t_t_e_r_n
160: operands.
161:
162: ----dddd Intermediate directories not explicitly listed in
163: the archive are not created. This option is
164: ignored unless the ----rrrr option is specified.
165:
166: ----ffff _a_r_c_h_i_v_e
167: The _a_r_c_h_i_v_e option specifies the pathname of the
168: input or output archive, overriding the default of
169: standard input for ----rrrr or standard output for ----wwww.
170:
171: ----iiii Interactively rename files. Substitutions
172: specified by ----ssss options (described below) are
173: performed before requesting the new file name from
174: the user. A file is skipped if an empty line is
175: entered and _p_a_x exits with an exit status of 0 if
176: EEEEOOOOFFFF is encountered.
177:
178: ----llll Files are linked rather than copied when possible.
179:
180: ----mmmm File modification times are not retained.
181:
182: ----nnnn When ----rrrr is specified, but ----wwww is not, the _p_a_t_t_e_r_n
183: arguments are treated as ordinary file names.
184: Only the first occurrence of each of these files
185: in the input archive is read. The ppppaaaaxxxx utility
186: exits with a zero exit status after all files in
187: the list have been read. If one or more files in
188: the list is not found, ppppaaaaxxxx writes a diagnostic to
189: standard error for each of the files and exits
190: with a non-zero exit status. the file names are
191: compared before any of the ----iiii, ----ssss, or ----yyyy options
192:
193:
194:
195: Page 3 (printed 10/10/90)
196:
197:
198:
199:
200:
201:
202: PPPPAAAAXXXX((((1111)))) CCCCOOOOHHHHEEEERRRREEEENNNNTTTT PPPPAAAAXXXX((((1111))))
203:
204:
205:
206: are applied.
207:
208: ----oooo Restore file ownership as specified in the
209: archive. The invoking process must have
210: appropriate privileges to accomplish this.
211:
212: ----pppp Preserve the access time of the input files after
213: they have been copied.
214:
215: ----ssss _r_e_p_l_s_t_r
216: File names are modified according to the
217: substitution expression using the syntax of _e_d(_1)
218: as shown:
219:
220: -s /_o_l_d/_n_e_w/[[[[gp]]]]
221:
222: Any non null character may be used as a delimiter
223: (a / is used here as an example). Multiple ----ssss
224: expressions may be specified; the expressions are
225: applied in the order specified terminating with
226: the first successful substitution. The optional
227: trailing pppp causes successful mappings to be listed
228: on standard error. The optional trailing gggg causes
229: the _o_l_d expression to be replaced each time it
230: occurs in the source string. Files that
231: substitute to an empty string are ignored both on
232: input and output.
233:
234: ----tttt _d_e_v_i_c_e The _d_e_v_i_c_e option argument is an implementation-
235: defined identifier that names the input or output
236: archive device, overriding the default of standard
237: input for ----rrrr and standard output for ----wwww.
238:
239: ----uuuu Copy each file only if it is newer than a pre-
240: existing file with the same name. This implies
241: ----aaaa.
242:
243: ----vvvv List file names as they are encountered. Produces
244: a verbose table of contents listing on the
245: standard output when both ----rrrr and ----wwww are omitted,
246: otherwise the file names are printed to standard
247: error as they are encountered in the archive.
248:
249: ----xxxx _f_o_r_m_a_t Specifies the output archive _f_o_r_m_a_t. The input
250: format, which must be one of the following, is
251: automatically determined when the ----rrrr option is
252: used. The supported formats are:
253:
254: _c_p_i_o The extended _C_P_I_O interchange format
255: specified in EEEExxxxtttteeeennnnddddeeeedddd CCCCPPPPIIIIOOOO FFFFoooorrrrmmmmaaaatttt iiiinnnn _I_E_E_E
256: _S_t_d. _1_0_0_3._1-_1_9_8_8.
257:
258:
259:
260:
261: Page 4 (printed 10/10/90)
262:
263:
264:
265:
266:
267:
268: PPPPAAAAXXXX((((1111)))) CCCCOOOOHHHHEEEERRRREEEENNNNTTTT PPPPAAAAXXXX((((1111))))
269:
270:
271:
272: _u_s_t_a_r The extended _T_A_R interchange format
273: specified in EEEExxxxtttteeeennnnddddeeeedddd TTTTAAAARRRR FFFFoooorrrrmmmmaaaatttt iiiinnnn _I_E_E_E
274: _S_t_d. _1_0_0_3._1-_1_9_8_8. This is the default
275: archive format.
276:
277: ----yyyy Interactively prompt for the disposition of each
278: file. Substitutions specified by ----ssss options
279: (described above) are performed before prompting
280: the user for disposition. EEEEOOOOFFFF or an input line
281: starting with the character qqqq caused _p_a_x to exit.
282: Otherwise, an input line starting with anything
283: other than yyyy causes the file to be ignored. This
284: option cannot be used in conjunction with the ----iiii
285: option.
286:
287: Only the last of multiple ----ffff or ----tttt options take effect.
288:
289: When writing to an archive, the standard input is used as a
290: list of pathnames if no _p_a_t_h_n_a_m_e operands are specified.
291: The format is one pathname per line. Otherwise, the
292: standard input is the archive file, which is formatted
293: according to one of the specifications in
294: AAAArrrrcccchhhhiiiivvvveeee////IIIInnnntttteeeerrrrcccchhhhaaaannnnggggeeee FFFFiiiilllleeee ffffoooorrrrmmmmaaaatttt in _I_E_E_E _S_t_d. _1_0_0_3._1-_1_9_8_8, or
295: some other implementation-defined format.
296:
297: The user ID and group ID of the process, together with the
298: appropriate privileges, affect the ability of _p_a_x to restore
299: ownership and permissions attributes of the archived files.
300: (See _f_o_r_m_a_t-_r_e_a_d_i_n_g _u_t_i_l_i_t_y in AAAArrrrcccchhhhiiiivvvveeee////IIIInnnntttteeeerrrrcccchhhhaaaannnnggggeeee FFFFiiiilllleeee
301: FFFFoooorrrrmmmmaaaatttt in _I_E_E_E _S_t_d. _1_0_0_3._1-_1_9_8_8.)
302:
303: The options ----aaaa, ----cccc, ----dddd, ----iiii, ----llll, ----pppp, ----tttt, ----uuuu, and ----yyyy are
304: provided for functional compatibility with the historical
305: _c_p_i_o and _t_a_r utilities. The option defaults were chosen
306: based on the most common usage of these options, therefore,
307: some of the options have meanings different than those of
308: the historical commands.
309:
310: OOOOppppeeeerrrraaaannnnddddssss
311: The following operands are available:
312:
313: _d_i_r_e_c_t_o_r_y The destination directory pathname for copies when
314: both the ----rrrr and ----wwww options are specified. The
315: directory must exist and be writable before the
316: copy or and error results.
317:
318: _p_a_t_h_n_a_m_e A file whose contents are used instead of the
319: files named on the standard input. When a
320: directory is named, all of its files and
321: (recursively) subdirectories are copied as well.
322:
323: _p_a_t_t_e_r_n A _p_a_t_t_e_r_n is given in the standard shell pattern
324:
325:
326:
327: Page 5 (printed 10/10/90)
328:
329:
330:
331:
332:
333:
334: PPPPAAAAXXXX((((1111)))) CCCCOOOOHHHHEEEERRRREEEENNNNTTTT PPPPAAAAXXXX((((1111))))
335:
336:
337:
338: matching notation. The default if no _p_a_t_t_e_r_n is
339: specified is ****, which selects all files.
340:
341: EEEEXXXXAAAAMMMMPPPPLLLLEEEESSSS
342: The following command
343:
344: pax -w -f /dev/rmt0 .
345:
346: copies the contents of the current directory to tape drive
347: 0.
348:
349: The commands
350:
351: mkdir _n_e_w_d_i_r
352: cd _o_l_d_d_i_r
353: pax -rw . _n_e_w_d_i_r
354:
355: copies the contents of _o_l_d_d_i_r to _n_e_w_d_i_r .
356:
357: The command
358:
359: pax -r -s ',//*usr//*,,' -f pax.out
360:
361: reads the archive ppppaaaaxxxx....oooouuuutttt with all files rooted in "/usr" in
362: the archive extracted relative to the current directory.
363:
364: FFFFIIIILLLLEEEESSSS
365: /dev/tty used to prompt the user for information when the
366: ----iiii or ----yyyy options are specified.
367:
368: SSSSEEEEEEEE AAAALLLLSSSSOOOO
369: cpio(1), find(1), tar(1), cpio(5), tar(5)
370:
371: DDDDIIIIAAAAGGGGNNNNOOOOSSSSTTTTIIIICCCCSSSS
372: _P_a_x will terminate immediately, without processing any
373: additional files on the command line or in the archive.
374:
375: EEEEXXXXIIIITTTT CCCCOOOODDDDEEEESSSS
376: _P_a_x will exit with one of the following values:
377:
378: 0 All files in the archive were processed successfully.
379:
380: >0 _P_a_x aborted due to errors encountered during operation.
381:
382: BBBBUUUUGGGGSSSS
383: Special permissions may be required to copy or extract
384: special files.
385:
386: Device, user ID, and group ID numbers larger than 65535
387: cause additional header records to be output. These records
388: are ignored by some historical version of _c_p_i_o(_1) and
389: _t_a_r(_1).
390:
391:
392:
393: Page 6 (printed 10/10/90)
394:
395:
396:
397:
398:
399:
400: PPPPAAAAXXXX((((1111)))) CCCCOOOOHHHHEEEERRRREEEENNNNTTTT PPPPAAAAXXXX((((1111))))
401:
402:
403:
404: The archive formats described in AAAArrrrcccchhhhiiiivvvveeee////IIIInnnntttteeeerrrrcccchhhhaaaannnnggggeeee FFFFiiiilllleeee
405: FFFFoooorrrrmmmmaaaatttt have certain restrictions that have been carried over
406: from historical usage. For example, there are restrictions
407: on the length of pathnames stored in the archive.
408:
409: When getting an "ls -l" style listing on _t_a_r format
410: archives, link counts are listed as zero since the _u_s_t_a_r
411: archive format does not keep link count information.
412:
413: On 16 bit architectures, the largest buffer size is 32k-1.
414: This is due, in part, to using integers in the buffer
415: allocation schemes, however, on many of these machines, it
416: is not possible to allocate blocks of memory larger than
417: 32k.
418:
419: CCCCOOOOPPPPYYYYRRRRIIIIGGGGHHHHTTTT
420: Copyright (c) 1989 Mark H. Colburn.
421: All rights reserved.
422:
423: Redistribution and use in source and binary forms are
424: permitted provided that the above copyright notice is
425: duplicated in all such forms and that any documentation,
426: advertising materials, and other materials related to such
427: distribution and use acknowledge that the software was
428: developed by Mark H. Colburn and sponsored by The USENIX
429: Association.
430:
431: THE SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS
432: OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE
433: IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
434: PARTICULAR PURPOSE.
435:
436: AAAAUUUUTTTTHHHHOOOORRRR
437: Mark H. Colburn
438: Minnetech Consulting, Inc.
439: 117 Mackubin Street, Suite 1
440: St. Paul, MN 55102
441: [email protected]
442:
443:
444: Sponsored by TTTThhhheeee UUUUSSSSEEEENNNNIIIIXXXX AAAAssssssssoooocccciiiiaaaattttiiiioooonnnn for public distribution.
445:
446:
447:
448:
449:
450:
451:
452:
453:
454:
455:
456:
457:
458:
459: Page 7 (printed 10/10/90)
460:
461:
462:
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.