5090051e34afb4b632e5805ccdfab6ad7c9318ba
[matthijs/upstream/backupninja.git] / man / backup.d.5
1 .\"                                      Hey, EMACS: -*- nroff -*-
2 .\" First parameter, NAME, should be all caps
3 .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
4 .\" other parameters are allowed: see man(7), man(1)
5 .TH BACKUP.D 5 "October 10, 2005" "riseup" "backupninja package"
6 .SH NAME 
7 BACKUP.D \- Action configuration files for \fBbackupninja(1)\fP.
8
9 .\" Please adjust this date whenever revising the manpage.
10 .\"
11 .\" Some roff macros, for reference:
12 .\" .nh        disable hyphenation
13 .\" .hy        enable hyphenation
14 .\" .ad l      left justify
15 .\" .ad b      justify to both left and right margins
16 .\" .nf        disable filling
17 .\" .fi        enable filling
18 .\" .br        insert line break
19 .\" .sp <n>    insert n+1 empty lines
20 .\" for manpage-specific macros, see man(7)
21 .br
22 .SH SYNOPSIS
23 .B "/etc/backup.d/* "
24 .br
25 .SH DESCRIPTION
26
27 To preform the actual backup actions, backupninja processes each action configuration file in
28 /etc/backup.d according to the file's suffix.
29
30 .IP .sh 10
31 run this file as a shell script.
32 .IP .rdiff
33 backup action for rdiff-backup.
34 .IP .dup
35 backup action for duplicity.
36 .IP .maildir
37 backup action for slow, incremental rsyncs of tens of thousands of maildirs.
38 .IP .mysql
39 backup action for safe MySQL dumps.
40 .IP .pgsql
41 backup action for safe PostgreSQL dumps.
42 .IP .ldap
43 backup action for safe OpenLdap dumps.
44 .IP .sys
45 backup action for general system reports and hardware information.
46 .IP .svn
47 backup action for safe backups of subversion repositories.
48 .IP .trac
49 backup action for safe backups of trac repositories.
50 .IP .makecd
51 backup action for burning backups to CD/DVD or creating ISOs.
52
53 .TP
54 These files must be owned by root and must not be world or group readable/writable. Support for additional configuration types can be added by dropping bash scripts with the name of the suffix into /usr/share/backupninja. 
55 .TP
56 The configuration files are processed in alphabetical order. However, it is suggested that you name the config files in "sysvinit style." 
57 .TP
58 For example:
59  10-local.ldap.disabled
60  15-runthisfirst.sh
61  20-runthisnext.mysql
62  90-runthislast.rdiff
63 .TP
64 Typically, you will put a '.rdiff' config file last, so that any database dumps you make are included in the filesystem backup. Action configurations which end with .disabled are skipped.
65 .TP
66 Example templates for the action configuration files can be found in /usr/share/doc/backupninja/examples. You can also use \fBninjahelper(1)\fP, a console based "wizard" for creating backup actions.
67
68 .SH SCHEDULING
69
70 By default, each configuration file is processed everyday at 01:00 (1 AM). This can be changed by specifying the 'when' option in a backup action's config file or in the global configuration file. 
71
72 For example:
73   when = sundays at 02:00
74   when = 30th at 22
75   when = 30 at 22:00
76   when = everyday at 01
77   when = Tuesday at 05:00
78   when = hourly
79
80 These values for "when" are invalid:
81   when = tuesday at 2am
82   when = tuesday at 2
83   when = tues at 02
84
85 A configuration file will be processed at the time(s) specified by the "when" option. If multiple "when" options are present, then they all apply. If two configurations files are scheduled to run in the same hour, then we fall back on the alphabetical ordering specified above. The "when" must occur before any sections in the action configuration file. 
86
87 .SH FILE FORMAT
88
89 The file format of the action configuration files is "ini style." Sections are created by using square bracket. Long lines are connected with a backslash. For example:
90
91    # this is a comment
92    [fishes]
93    fish = red
94    fish = blue
95    [fruit]
96    apple = yes
97    pear = no thanks \\
98    i will not have a pear.
99
100 .SH SEE ALSO
101 .BR backupninja (1), 
102 .BR ninjahelper (1), 
103 .BR backupninja.conf (5), 
104 .br
105 .SH AUTHOR
106 BACKUPNINJA was written by the riseup.net collective.