1 35ed6913 2005-07-13 devnull .TH VBACKUP 8
3 cea719ac 2005-07-18 devnull vbackup, vcat, vftp, vmount, vnfs \-
4 35ed6913 2005-07-13 devnull back up Unix file systems to Venti
5 35ed6913 2005-07-13 devnull .SH SYNOPSIS
6 35ed6913 2005-07-13 devnull .B vbackup
46 35ed6913 2005-07-13 devnull .B vmount
55 3aec33fe 2005-07-18 devnull .B -ELLRVr
63 35ed6913 2005-07-13 devnull .I blocksize
67 35ed6913 2005-07-13 devnull .I cachesize
69 35ed6913 2005-07-13 devnull .I config
70 35ed6913 2005-07-13 devnull .SH DESCRIPTION
71 35ed6913 2005-07-13 devnull These programs back up and restore standard
72 35ed6913 2005-07-13 devnull Unix file system images stored in
73 35ed6913 2005-07-13 devnull .IR venti (8).
74 35ed6913 2005-07-13 devnull Images stored in
76 35ed6913 2005-07-13 devnull are named by
77 35ed6913 2005-07-13 devnull .IR scores ,
78 35ed6913 2005-07-13 devnull which consist of a file system type followed
79 35ed6913 2005-07-13 devnull by a colon and forty hexadecimal digits, as in:
82 35ed6913 2005-07-13 devnull ffs:0123456789abcdef0123456789abcdef01234567
85 35ed6913 2005-07-13 devnull (The hexadecimal data is the SHA1 hash of the Venti
86 35ed6913 2005-07-13 devnull root block representing the file system image.)
88 35ed6913 2005-07-13 devnull These programs expect the environment variable
89 35ed6913 2005-07-13 devnull .B $venti
90 35ed6913 2005-07-13 devnull to be set to the network address of the Venti server to use
91 35ed6913 2005-07-13 devnull (for example,
92 35ed6913 2005-07-13 devnull .B yourhost
94 35ed6913 2005-07-13 devnull .BR tcp!yourhost!venti ).
96 35ed6913 2005-07-13 devnull .I Vbackup
97 35ed6913 2005-07-13 devnull copies the file system stored on
99 35ed6913 2005-07-13 devnull to the Venti server and prints the
100 35ed6913 2005-07-13 devnull score for the newly-stored image.
101 35ed6913 2005-07-13 devnull The argument
103 35ed6913 2005-07-13 devnull should be a disk or disk partition device
104 35ed6913 2005-07-13 devnull that would be appropriate to pass to
105 35ed6913 2005-07-13 devnull .IR mount (8).
107 35ed6913 2005-07-13 devnull The optional argument
108 35ed6913 2005-07-13 devnull .I score
109 35ed6913 2005-07-13 devnull is the score of a previous backup of the disk image.
111 35ed6913 2005-07-13 devnull .I score
112 35ed6913 2005-07-13 devnull is given,
113 35ed6913 2005-07-13 devnull .I vbackup
114 35ed6913 2005-07-13 devnull will not write to Venti any blocks that have not changed
115 35ed6913 2005-07-13 devnull since the previous backup.
116 35ed6913 2005-07-13 devnull This is only a speed optimization: since the blocks are already
117 35ed6913 2005-07-13 devnull stored on Venti they need not be sent to the Venti server again.
119 35ed6913 2005-07-13 devnull The options to
120 35ed6913 2005-07-13 devnull .I vbackup
124 3aec33fe 2005-07-18 devnull Turn on debugging output.
127 3aec33fe 2005-07-18 devnull Trace interactions with Venti server.
129 be81682d 2007-06-12 devnull .B -m \fIhost
130 be81682d 2007-06-12 devnull .B -M \fImtpt
131 be81682d 2007-06-12 devnull Set names used to construct the path in the
132 be81682d 2007-06-12 devnull .B mount command.
133 be81682d 2007-06-12 devnull The default
135 be81682d 2007-06-12 devnull is the name returned by
136 be81682d 2007-06-12 devnull .I sysname
138 be81682d 2007-06-12 devnull .IR getuser (3)).
139 be81682d 2007-06-12 devnull The default
141 be81682d 2007-06-12 devnull is the place where
143 be81682d 2007-06-12 devnull is currently mounted.
145 be81682d 2007-06-12 devnull Set backup mount point:
146 be81682d 2007-06-12 devnull this name is also used in the printed
147 3aec33fe 2005-07-18 devnull .B mount
148 3aec33fe 2005-07-18 devnull command.
149 e5e159fd 2005-07-18 devnull The default is the name returned by
150 e5e159fd 2005-07-18 devnull .I sysname
152 e5e159fd 2005-07-18 devnull .IR getuser (3)).
155 3aec33fe 2005-07-18 devnull No-op mode: do not write any blocks to the server
158 3aec33fe 2005-07-18 devnull Print verbose output.
160 35ed6913 2005-07-13 devnull .B -w \fIn
161 3aec33fe 2005-07-18 devnull Write parallelism: keep
163 3aec33fe 2005-07-18 devnull writes to the server in progress at a time.
165 35ed6913 2005-07-13 devnull .B -s \fIsecs
166 3aec33fe 2005-07-18 devnull Status interval: every
168 3aec33fe 2005-07-18 devnull seconds, print a line tracking progress of the backup.
172 3aec33fe 2005-07-18 devnull .I vbackup
173 3aec33fe 2005-07-18 devnull finishes, it prints a single line of the form
176 be81682d 2007-06-12 devnull mount /\fIhost\fL/\fIyyyy\fL/\fImmdd\fL/\fImtpt\fL \fIscore\fL \fIyyyy\fL/\fImmdd\fL/\fIhhmm
179 3aec33fe 2005-07-18 devnull This line is a valid configuration line for
181 3aec33fe 2005-07-18 devnull .RI ( q.v. ).
182 3aec33fe 2005-07-18 devnull .I Mntpath
183 3aec33fe 2005-07-18 devnull is the path on which
185 3aec33fe 2005-07-18 devnull is currently mounted.
188 35ed6913 2005-07-13 devnull writes the named disk image to standard output.
189 35ed6913 2005-07-13 devnull Unused file system blocks are printed zeroed regardless
190 35ed6913 2005-07-13 devnull of their actual content.
192 3aec33fe 2005-07-18 devnull By default,
194 3aec33fe 2005-07-18 devnull will assume that its standard output is seekable
195 3aec33fe 2005-07-18 devnull .RI ( i.e.,
196 3aec33fe 2005-07-18 devnull it has been redirected to a file or disk)
197 3aec33fe 2005-07-18 devnull and seek over unused blocks instead of writing to them.
200 3aec33fe 2005-07-18 devnull option causes
202 3aec33fe 2005-07-18 devnull to zero unused blocks instead.
205 7b14c113 2005-08-11 devnull presents an
206 7b14c113 2005-08-11 devnull .IR ftp (1)-like
207 7b14c113 2005-08-11 devnull interface to a physical or backed-up disk image.
208 7b14c113 2005-08-11 devnull It is used mainly for debugging.
212 7b14c113 2005-08-11 devnull .B vftp>
213 7b14c113 2005-08-11 devnull prompt for a list of commands.
215 35ed6913 2005-07-13 devnull .I Vmount
216 35ed6913 2005-07-13 devnull mounts the NFS service at the network connection
217 35ed6913 2005-07-13 devnull .I address
219 35ed6913 2005-07-13 devnull .IR mountpoint .
220 35ed6913 2005-07-13 devnull On most operating systems,
221 35ed6913 2005-07-13 devnull .I vmount
222 35ed6913 2005-07-13 devnull must be run by the user
223 35ed6913 2005-07-13 devnull .BR root .
226 35ed6913 2005-07-13 devnull serves, using the
227 35ed6913 2005-07-13 devnull NFS version 3 protocol,
228 35ed6913 2005-07-13 devnull one or more disk images in a synthetic tree defined
229 35ed6913 2005-07-13 devnull by the configuration file
230 35ed6913 2005-07-13 devnull .IR config .
232 3aec33fe 2005-07-18 devnull serves both NFS mount protocol
233 3aec33fe 2005-07-18 devnull and NFS protocol
235 35ed6913 2005-07-13 devnull .IR addr
236 35ed6913 2005-07-13 devnull (default
237 3aec33fe 2005-07-18 devnull .BR udp!*!nfs ).
238 35ed6913 2005-07-13 devnull The options are:
241 3aec33fe 2005-07-18 devnull Disable `encrypted' handles.
242 3aec33fe 2005-07-18 devnull By default handles are encrypted with a random key to avoid
243 3aec33fe 2005-07-18 devnull leaking information about the backed-up file systems.
244 3aec33fe 2005-07-18 devnull If encryption is disabled, the NFS handles exposed to the client
245 3aec33fe 2005-07-18 devnull may leak information about the root scores of the disks as well
246 3aec33fe 2005-07-18 devnull as inode numbers.
249 3aec33fe 2005-07-18 devnull Local service only: serve only requests from the loopback interface (127.0.0.1).
252 3aec33fe 2005-07-18 devnull Local service only, with paranoia: serve only requests from loopback,
253 3aec33fe 2005-07-18 devnull and only from the first source port that sends a request.
254 3aec33fe 2005-07-18 devnull This option is intended to be used to make sure that once the local
255 3aec33fe 2005-07-18 devnull host has mounted the service, no other local users can access it.
258 3aec33fe 2005-07-18 devnull Print all NFS and NFS mount RPCs to standard error.
261 3aec33fe 2005-07-18 devnull Print all Venti transactions to standard error.
263 3aec33fe 2005-07-18 devnull .BI -a " addr
264 3aec33fe 2005-07-18 devnull Serve requests on
265 3aec33fe 2005-07-18 devnull .IR addr
266 3aec33fe 2005-07-18 devnull (see above).
268 3aec33fe 2005-07-18 devnull .BI -b " blocksize
269 3aec33fe 2005-07-18 devnull Set block size used by the in-memory venti block cache.
270 3aec33fe 2005-07-18 devnull Must be as large as the maximum block size in any
271 3aec33fe 2005-07-18 devnull file system mentioned in the configuration.
273 3aec33fe 2005-07-18 devnull .BI -c " cachesize
274 3aec33fe 2005-07-18 devnull Set the number of blocks stored by the in-memory venti cache.
277 3aec33fe 2005-07-18 devnull Respond to all requests with a Sun RPC rejection.
278 3aec33fe 2005-07-18 devnull This is useful during debugging.
281 3aec33fe 2005-07-18 devnull .I Config
282 3aec33fe 2005-07-18 devnull is a text file describing the
283 3aec33fe 2005-07-18 devnull backup hierarchy for
285 3aec33fe 2005-07-18 devnull to serve.
286 3aec33fe 2005-07-18 devnull Lines beginning with a sharp
287 3aec33fe 2005-07-18 devnull .RB ( # )
288 3aec33fe 2005-07-18 devnull are ignored.
289 3aec33fe 2005-07-18 devnull The rest of the file is a sequence of commands, one per line.
290 3aec33fe 2005-07-18 devnull The commands are:
292 3aec33fe 2005-07-18 devnull .BI mount " mtpt score time
293 3aec33fe 2005-07-18 devnull Add the file system with the given
294 3aec33fe 2005-07-18 devnull .I score
295 3aec33fe 2005-07-18 devnull to the tree at the mount point
296 3aec33fe 2005-07-18 devnull .IR mtpt .
297 3aec33fe 2005-07-18 devnull The path to the mount point will be created
298 3aec33fe 2005-07-18 devnull if necessary.
300 3aec33fe 2005-07-18 devnull .B /dev/null
301 3aec33fe 2005-07-18 devnull is given as the score, an empty file system is mounted at
302 3aec33fe 2005-07-18 devnull .IR mtpt ,
303 3aec33fe 2005-07-18 devnull excluding
304 3aec33fe 2005-07-18 devnull .IR mtpt 's
305 3aec33fe 2005-07-18 devnull contents from view.
307 3aec33fe 2005-07-18 devnull is the modification time to return for the directory
308 3aec33fe 2005-07-18 devnull .IR mtpt ,
309 3aec33fe 2005-07-18 devnull either a decimal number of seconds since the epoch
310 3aec33fe 2005-07-18 devnull or a string of the form
311 3aec33fe 2005-07-18 devnull .IB yyyy / mmdd / hhmm
312 3aec33fe 2005-07-18 devnull giving the year, month, day, hour, and minute.
313 3aec33fe 2005-07-18 devnull .RI ( Vnfs
314 3aec33fe 2005-07-18 devnull does not use the modification time of the root in order
315 3aec33fe 2005-07-18 devnull to avoid accessing every mounted file system on common
316 3aec33fe 2005-07-18 devnull actions like
319 3aec33fe 2005-07-18 devnull .BR /dump/sys/2005 .)
321 3aec33fe 2005-07-18 devnull .BI allow " ip\fR[\fL/\fImask\fR]
323 3aec33fe 2005-07-18 devnull .BI deny " ip\fR[\fL/\fImask\fR]
324 3aec33fe 2005-07-18 devnull These two commands define access permissions based on IP address.
325 3aec33fe 2005-07-18 devnull The optional
327 3aec33fe 2005-07-18 devnull can be a decimal number (24) or an equivalent IP mask (255.255.255.0).
328 3aec33fe 2005-07-18 devnull Each request is filtered through the rules listed in the configuration file.
329 3aec33fe 2005-07-18 devnull The first rule that matches is used.
331 3aec33fe 2005-07-18 devnull .B allow
334 3aec33fe 2005-07-18 devnull rules are given, the default action is to reject the request.
335 3aec33fe 2005-07-18 devnull In the absence of any rules, the default action is to accept all requests.
337 35ed6913 2005-07-13 devnull .SH EXAMPLES
339 3aec33fe 2005-07-18 devnull Running on the server
340 3aec33fe 2005-07-18 devnull .IR bob ,
341 3aec33fe 2005-07-18 devnull back up the file system stored on
342 3aec33fe 2005-07-18 devnull .BR /dev/da0s1a ,
343 3aec33fe 2005-07-18 devnull which is mounted on
344 3aec33fe 2005-07-18 devnull .BR /home :
347 35ed6913 2005-07-13 devnull % vbackup /dev/da0s1a
348 3aec33fe 2005-07-18 devnull mount /bob/2005/0510/home ffs:0123456789abcdef\fI...\fP 2005/0510/0831
352 35ed6913 2005-07-13 devnull Serve that backup and a few others in a tree reminiscent
353 35ed6913 2005-07-13 devnull of Plan 9's dump file system, but hide each day's contents of
354 35ed6913 2005-07-13 devnull .B /tmp :
357 35ed6913 2005-07-13 devnull % cat config
358 3aec33fe 2005-07-18 devnull mount /bob/2005/0510 ffs:0123456789abcdef\fI...\fP 2005/0510/0829
359 3aec33fe 2005-07-18 devnull mount /bob/2005/0510/home ffs:0123456789abcdef\fI...\fP 2005/0510/0831
360 3aec33fe 2005-07-18 devnull mount /bob/2005/0510/tmp /dev/null 1
361 3aec33fe 2005-07-18 devnull mount /bob/2005/0511 ffs:0123456789abcdef\fI...\fP 2005/0511/0827
362 3aec33fe 2005-07-18 devnull mount /bob/2005/0511/home ffs:0123456789abcdef\fI...\fP 2005/0511/0828
363 3aec33fe 2005-07-18 devnull mount /bob/2005/0511/tmp /dev/null 1
364 3aec33fe 2005-07-18 devnull % vnfs -b 16k -c 1k config
368 35ed6913 2005-07-13 devnull Mount the backups on a client machine using
369 35ed6913 2005-07-13 devnull .IR vmount :
372 35ed6913 2005-07-13 devnull # vmount udp!yourserver!nfs /dump
373 3aec33fe 2005-07-18 devnull # ls /dump/bob/2005
379 3aec33fe 2005-07-18 devnull (Users of fancy shells may need to quote the address argument.)