summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2002-03-09 00:12:19 +0000
committerAndrew Tridgell <tridge@samba.org>2002-03-09 00:12:19 +0000
commita47e103b859c8c1d3a655fab84514b97cc6a8252 (patch)
treec6bcd5e81be8f0027c423259e9d88ea376545381 /source3
parentd65228687fc355260260d5a72a5fbebc45d2ca0c (diff)
downloadsamba-a47e103b859c8c1d3a655fab84514b97cc6a8252.tar.gz
samba-a47e103b859c8c1d3a655fab84514b97cc6a8252.tar.bz2
samba-a47e103b859c8c1d3a655fab84514b97cc6a8252.zip
added a bunch of explanation about tdbbackup
(This used to be commit 4ac4220e2f60dfac35dc80dcf1830a6a6352ace0)
Diffstat (limited to 'source3')
-rw-r--r--source3/tdb/tdbbackup.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/source3/tdb/tdbbackup.c b/source3/tdb/tdbbackup.c
index 2da81cd213..91bedb5661 100644
--- a/source3/tdb/tdbbackup.c
+++ b/source3/tdb/tdbbackup.c
@@ -18,6 +18,29 @@
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
+/*
+
+ This program is meant for backup/restore of tdb databases. Typical usage would be:
+ tdbbackup /var/lock/samba/*.tdb
+ when Samba shuts down cleanly, which will make a backup of all the local databases
+ to *.bak files. Then on Samba startup you would use:
+ tdbbackup -v /var/lock/samba/*.tdb
+ and this will check the databases for corruption and if corruption is detected then
+ the backup will be restored.
+
+ You may also like to do a backup on a regular basis while Samba is
+ running, perhaps using cron.
+
+ The reason this program is needed is to cope with power failures
+ while Samba is running. A power failure could lead to database
+ corruption and Samba will then not start correctly.
+
+ Note that many of the databases in Samba are transient and thus
+ don't need to be backed up, so you can optimise the above a little
+ by only running the backup on the critical databases.
+
+ */
+
#include <errno.h>
#include <stdlib.h>
#include <stdio.h>