source: box/boxbackup-web/restore.html @ 1901

Revision 1901, 4.6 KB checked in by ben, 5 years ago (diff)

Make box backup web site available.

Line 
1<?xml version="1.0" encoding="iso-8859-1"?>
2<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3<html xmlns="http://www.w3.org/1999/xhtml">
4<head>
5<meta http-equiv="content-type" content="text/html;charset=iso-8859-1" />
6<title>Box Backup verify and restore files</title>
7<link rel="stylesheet" href="bbstyles.css" type="text/css" />
8</head>
9<body>
10<div align="center">
11<div id="header">
12<div id="logo">
13<img src="images/bblogo.png" alt="logo" height="65" width="331" border="0" vspace="5" align="middle" /> <img src="images/stepahead.png" alt="a step ahead in data security" width="182" height="11" hspace="10" vspace="20" border="0" align="middle" /></div>
14</div>
15<div id="page">
16
17<h1>Box Backup verify and restore files</h1>
18
19<p>Backups are no use unless you can restore them. The <tt>bbackupquery</tt> utility does
20this and more.</p>
21
22<p>You don't provide any login information to it, as it just picks up the data it needs
23from <tt>/etc/box/bbackupd.conf</tt>. You should run it as root so it can find everything
24it needs.</p>
25
26<p>Full documentation can be found in <tt>bin/bbackupquery/documentation.txt</tt> in the distribution
27archive. It follows the model of a command line sftp client quite closely.</p>
28
29<p>On systems where GNU readline is available (by default) it uses that for command line history and
30editing. Otherwise it falls back to very basic UNIX text entry.</p>
31
32
33<h2>Verify backups</h2>
34
35<p>Since this is a development system, you'll be keen to verify that your backups are
36correct. This is easy.</p>
37
38<pre>
39/usr/local/bin/bbackupquery "compare -a" quit
40</pre>
41
42<p>It will report all the differences between the store and the files on disc. It will download
43everything, so may take a while. You should expect to see some differences on a typical compare,
44because files which have recently changed are unlikely to have been uploaded yet. Consider checking the
45timestamps on the files, or keeping a record of these messages and comparing them with a future verification.</p>
46
47<p>If you would like to do a "quick" check which just downloads file
48checksums and compares against that, then do</p>
49
50<pre>
51/usr/local/bin/bbackupquery "compare -aq" quit
52</pre>
53
54<p>However, this does not check that the file attributes are correct, and since the checksums are generated
55on the client they may not reflect the data on the server if there is a problem -- the server cannot check
56the encrypted contents. View this as a good indication, rather than a definite check that your backup
57verifies correctly.</p>
58
59<p>You may wish to run either one as a cron job while testing this system.</p>
60
61
62<h2>Restore backups</h2>
63
64<p>You will need the keys file created when you configured the server. Without it, <b>you cannot
65restore the files</b>; this is the downside of encrypted backups. However, by keeping the small
66keys file safe, you indirectly keep your entire backup safe.</p>
67
68<p>The first step is to recreate the configuration of the backup client. It's probably best
69to have stored the /etc/box directory with your keys. But if you're recreating it, all you really
70need is to have got the login infomation correct (ie the certs and keys).</p>
71
72<p><b>Don't run bbackupd yet!</b> It will mark all your files as deleted if you do, which is not
73hugely bad in terms of losing data, just a major inconvenience. (This assumes that
74you are working from a blank slate. If you want to restore some files to a different location,
75it's fine to restore while bbackupd is running, just do it outside a backed up directory to make
76sure it doesn't start uploading the restored files.)</p>
77
78<p>Type <tt>/usr/local/bin/bbackupquery</tt> to run it in interactive mode.</p>
79
80<p>Type <tt>list</tt> to see a list of the locations stored on the server.</p>
81
82<p>For each location you want to restore, type <tt>restore name-on-server local-dir-name</tt>. The
83directory specified by local-dir-name must not exist yet.</p>
84
85<p>If the restore is interrupted for any reason, repeat the above steps, but add the <tt>-r</tt>
86flag to the restore command to tell it to resume.</p>
87
88
89<h2>Other tricks</h2>
90
91<p>bbackupquery can also...
92<ul>
93<li>List files on the server
94<li>Restore arbitary parts of the file system
95<li><a href="retrieve.html">Recover deleted files</a> (either if the backup daemon hasn't deleted them from the store,
96or if they are marked on the store as deleted but not actually gone yet.)
97<li><a href="retrieve.html">Recover old versions</a> of files which are still on the server.
98</ul>
99</p>
100
101<p>Read <tt>bin/bbackupquery/documentation.txt</tt> for more details.</p>
102
103<p>&nbsp;</p>
104<p>&copy; Ben Summers, 2003, 2004</p>
105<p>&nbsp;</p>
106</div>
107</div>
108</body>
109</html>
Note: See TracBrowser for help on using the repository browser.