BSD 4_1_snap development
[unix-history] / usr / man / man1 / tp.1
CommitLineData
e3758c96
C
1.TH TP 1 deprecated
2.SH NAME
3tp \- manipulate tape archive
4.SH SYNOPSIS
5.B tp
6[ key ] [ name ... ]
7.SH DESCRIPTION
8.PP
9.I Tp
10saves and restores files
11on DECtape or magtape.
12Its actions are controlled by the
13.I key
14argument.
15The key is a string of characters containing
16at most one function letter and possibly
17one or more function modifiers.
18Other arguments to the command are file or directory
19names specifying which files are to be dumped, restored,
20or listed.
21In all cases, appearance of a directory name refers to
22the files and (recursively) subdirectories of that directory.
23.PP
24The function portion of
25the key is specified by one of the following letters:
26.TP 8
27.B r
28The named files
29are written
30on the tape.
31If files with the same names
32already exist, they are replaced.
33`Same' is determined by string comparison, so
34`./abc' can never be the same as `/usr/dmr/abc' even
35if `/usr/dmr' is the current directory.
36If no file argument is given, `\fB.\fR' is the default.
37.TP 8
38.B u
39updates the tape.
40.B u
41is like
42.B r,
43but a file is replaced only if its
44modification date is later than the date stored on the tape;
45that is to say, if it has changed since it was dumped.
46.B u
47is the default command if none is given.
48.TP 8
49.B d
50deletes the named files from
51the tape.
52At least one name argument must be given.
53This function is not permitted on magtapes.
54.TP 8
55.B x
56extracts the named files from the tape to the file system.
57The owner and mode are restored.
58If no file argument is given, the entire contents of the
59tape are extracted.
60.TP 8
61.B t
62lists the names of the specified files.
63If no file argument is given,
64the entire contents of the tape is listed.
65.PP
66The following characters may be used in addition to the letter
67which selects the function desired.
68.TP 10
69.B m
70Specifies magtape as opposed to DECtape.
71.TP 10
72.B 0,...,7
73This
74modifier selects the drive on which the tape is mounted.
75For DECtape,
76.B x
77is default; for magtape
78`0' is the default.
79.TP 10
80.B v
81Normally
82.I tp
83does its work silently.
84The
85.B v
86(verbose)
87option causes it to type the name of each file it treats
88preceded by the function letter.
89With the
90.B t
91function,
92.B v
93gives more information about the
94tape entries than just the name.
95.TP 10
96.B c
97means a fresh dump is being created; the tape directory
98is cleared before beginning.
99Usable only with
100.B r
101and
102.B u.
103This option is assumed with magtape since
104it is impossible to selectively overwrite
105magtape.
106.TP 10
107.B i
108Errors reading and writing the
109tape are noted, but no action is taken.
110Normally, errors cause a return to the command level.
111.TP 10
112.B f
113Use the first named file, rather than a tape,
114as the archive.
115This option currently acts like
116.BR m ;
117.I i.e.
118.BR r
119implies
120.BR c ,
121and neither
122.BR d
123nor
124.BR u
125are permitted.
126.TP 10
127.B w
128causes
129.I tp
130to pause before treating each file, type
131the indicative letter and the file name (as with
132.BR v )
133and await the user's response.
134Response
135.B y
136means `yes', so the file is treated.
137Null response
138means `no', and the file does not take part
139in whatever is being done.
140Response
141.B x
142means `exit';
143the
144.I tp
145command terminates immediately.
146In the
147.B x
148function,
149files previously asked about
150have been extracted already.
151With
152.B "r, u,"
153and
154.B d
155no change has been made to the tape.
156.PP
157.SH FILES
158/dev/tap?
159.br
160/dev/rmt?
161.SH SEE ALSO
162ar(1), tar(1)
163.SH DIAGNOSTICS
164Several; the non-obvious one is
165`Phase error', which means the file changed after it was selected for
166dumping but before it was dumped.
167.SH BUGS
168A single file with several links to it is treated like several files.
169.PP
170Binary-coded control information makes
171magnetic tapes written by
172.I tp
173difficult to carry to other machines;
174.IR tar (1)
175avoids the problem.