1mysql‐zrm‐backup(1) mysql‐
2zrm‐backup(1)
3
4
5
6NNAAMMEE
7 mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp ‐ Backup utility for ZRM for MySQL.
8
9SSYYNNOOPPSSIISS
10 mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp
11 [‐‐‐‐bbaacckkuupp‐‐sseett _n_a_m_e]
12 [_B_a_c_k_u_p _S_o_u_r_c_e _O_p_t_i_o_n_s]
13 [_M_y_S_Q_L _A_c_c_e_s_s _O_p_t_i_o_n_s]
14 [_B_a_c_k_u_p _M_e_t_h_o_d _O_p_t_i_o_n_s]
15 [_B_a_c_k_u_p _D_e_s_t_i_n_a_t_i_o_n _O_p_t_i_o_n_s]
16 [_L_o_g_g_i_n_g _a_n_d _N_o_t_i_f_i_c_a_t_i_o_n _O_p_t_i_o_n_s]
17 [‐‐‐‐ooppttiioonnss‐‐ffiillee _c_o_n_f___f_i_l_e]
18 [‐‐‐‐hheellpp]]
19
20BBaacckkuupp SSoouurrccee SSyynnooppssiiss
21 mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp
22 [‐‐‐‐aallll‐‐ddaattaabbaasseess] | [‐‐‐‐ddaattaabbaasseess "_d_b_n_a_m_e_1
23_d_b_n_a_m_e_2"...] |
24 [‐‐‐‐ddaattaabbaassee "_n_a_m_e" [‐‐‐‐ttaabblleess _t_n_a_m_e_1 _t_n_a_m_e_2
25...]]
26 [‐‐‐‐eexxcclluuddee‐‐ppaatttteerrnn _p_a_t_t_e_r_n]
27 [‐‐‐‐rroouuttiinneess | ‐‐‐‐nnoo‐‐rroouuttiinneess]
28 [‐‐‐‐mmyyssqqll‐‐bbiinnppaatthh _M_y_S_Q_L___c_o_m_m_a_n_d___d_i_r]
29 [‐‐‐‐mmyyssqqll‐‐bbiinnlloogg‐‐ppaatthh _M_y_S_Q_L___b_i_n_a_r_y___l_o_g___d_i_r]
30 [‐‐‐‐ccoonnffiigg‐‐ffiillee‐‐lliisstt==""_c_o_n_f_i_g___f_i_l_e___p_a_t_h_n_a_m_e""]
31
32MMyySSQQLL AAcccceessss SSyynnooppssiiss
33 mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp
34 [‐‐‐‐uusseerr _u_s_e_r]
35 [‐‐‐‐ppaasssswwoorrdd _p_a_s_s_w_o_r_d]
36 [‐‐‐‐hhoosstt _h_o_s_t_n_a_m_e]
37 [‐‐‐‐ppoorrtt _p_o_r_t_n_u_m_b_e_r]
38 [‐‐‐‐ssoocckkeett _n_a_m_e]
39 [‐‐‐‐ssssll‐‐ooppttiioonnss _"_M_y_S_Q_L _s_s_l _o_p_t_i_o_n_s_"]
40 [‐‐‐‐ssiinnggllee‐‐ttrraannssaaccttiioonn
41[aallwwaayyss|nneevveerr|oonnllyy‐‐iinnnnooddbb]]
42 [‐‐‐‐eexxttrraa‐‐mmyyssqqlldduummpp‐‐ooppttiioonnss
43_m_y_s_q_l_d_u_m_p___o_p_t_i_o_n_s]
44 [‐‐‐‐eexxttrraa‐‐mmyydduummppeerr‐‐ooppttiioonnss
45_m_y_d_u_m_p_e_r___o_p_t_i_o_n_s]
46
47CCoommpprreessssiioonn aanndd EEnnccrryyppttiioonn SSyynnooppssiiss
48 mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp
49 [‐‐‐‐ccoommpprreessss | ‐‐‐‐nnoo‐‐ccoommpprreessss ]
50 [‐‐‐‐ccoommpprreessss‐‐mmyyssqqlldduummpp‐‐oonntthheeffllyy |
51‐‐‐‐nnoo‐‐ccoommpprreessss‐‐mmyyssqqll‐‐
52 dduummpp‐‐oonntthheeffllyy]
53 [‐‐‐‐ccoommpprreessss‐‐pplluuggiinn _p_l_u_g_i_n___n_a_m_e]
54 [‐‐‐‐nnoo‐‐eennccrryypptt | ‐‐‐‐eennccrryypptt]
55 [‐‐‐‐eennccrryypptt‐‐pplluuggiinn pplluuggiinn__nnaammee
56[‐‐‐‐ddeeccrryypptt‐‐ooppttiioonn
57 _o_p_t_i_o_n]]
58 [‐‐‐‐ppaassssffiillee _f_i_l_e_n_a_m_e]
59
60PPlluuggiinn SSyynnooppssiiss
61 mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp
62 [‐‐‐‐pprree‐‐bbaacckkuupp‐‐pplluuggiinn _p_l_u_g_i_n]
63 [‐‐‐‐pprree‐‐bbaacckkuupp‐‐pplluuggiinn‐‐ooppttiioonnss _"_o_p_t_i_o_n_1
64_o_p_t_i_o_n_2 _._._._"]
65 [‐‐‐‐ccooppyy‐‐pplluuggiinn _p_l_u_g_i_n]
66 [‐‐‐‐sssshh‐‐uusseerr _u_s_e_r]
67 [‐‐‐‐sssshh‐‐iiddeennttiittyy‐‐ffiillee _f_i_l_e_n_a_m_e]
68 [‐‐‐‐rreemmoottee‐‐mmyyssqqll‐‐bbiinnppaatthh _p_a_t_h]
69 [‐‐‐‐ssoocckkeett‐‐rreemmoottee‐‐ppoorrtt _p_o_r_t]
70 [‐‐‐‐ppoosstt‐‐bbaacckkuupp‐‐pplluuggiinn _p_l_u_g_i_n]
71 [‐‐‐‐ppoosstt‐‐bbaacckkuupp‐‐pplluuggiinn‐‐ooppttiioonnss _"_o_p_t_i_o_n_1
72_o_p_t_i_o_n_2 _._._._"]
73
74BBaacckkuupp MMeetthhoodd SSyynnooppssiiss
75 mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp
76 [‐‐‐‐bbaacckkuupp‐‐lleevveell _l_e_v_e_l]
77 [‐‐‐‐bbaacckkuupp‐‐mmooddee rraaww | llooggiiccaall]
78 [‐‐‐‐llooggiiccaall‐‐ppaarraalllleell 00 | 11]
79 [‐‐‐‐ssyynncchhrroonnoouuss‐‐cchheecckkssuumm | ‐‐‐‐nnoo‐‐ssyynncchhrroonnoouuss‐‐cchheecckkssuumm]
80 [‐‐‐‐rreepplliiccaattiioonn | ‐‐‐‐nnoorreepplliiccaattiioonn]
81 [‐‐‐‐rreetteennttiioonn‐‐ppoolliiccyy _b_a_c_k_u_p___r_e_t_e_n_t_i_o_n___t_i_m_e]
82 [‐‐‐‐ddeeffaauulltt‐‐cchhaarraacctteerr‐‐sseett _c_h_a_r___s_e_t___n_a_m_e]
83 [‐‐‐‐ccoommpprreessss‐‐ddaattaa‐‐dduurriinngg‐‐ttrraannssppoorrtt]
84
85SSnnaappsshhoott PPlluuggiinn SSyynnooppssiiss
86 mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp
87 [‐‐‐‐ssnnaappsshhoott‐‐pplluuggiinn==""_s_n_a_p_s_h_o_t___p_l_u_g_i_n___p_a_t_h_n_a_m_e""]
88 [‐‐‐‐cchheecckk‐‐iinnnnooddbb | ‐‐‐‐nnoo‐‐cchheecckk‐‐iinnnnooddbb]
89 [‐‐‐‐bbaacckkuupp‐‐ttyyppee rreegguullaarr|‐‐‐‐bbaacckkuupp‐‐ttyyppee qquuiicckk]]
90
91 ‐‐‐‐ssnnaappsshhoott‐‐pplluuggiinn==""""//uussrr//sshhaarree//mmyyssqqll‐‐zzrrmm//pplluuggiinnss//llvvmm‐‐ssnnaappsshhoott..ppll""
92 [‐‐‐‐ssnnaappsshhoott‐‐ssiizzee _s_i_z_e]
93
94 ‐‐‐‐ssnnaappsshhoott‐‐pplluuggiinn==""//uussrr//sshhaarree//mmyyssqqll‐‐zzrrmm//pplluuggiinnss//zzffss‐‐ssnnaappsshhoott..ppll""
95 (no options necessary)
96
97BBaacckkuupp DDeessttiinnaattiioonn SSyynnooppssiiss
98 mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp
99 [‐‐‐‐bbaacckkuupp‐‐nnaammee _i_m_a_g_e___n_a_m_e]
100 [‐‐‐‐ddeessttiinnaattiioonn _d_i_r___p_a_t_h]
101 [‐‐‐‐ttmmppddiirr _t_e_m_p___d_i_r
102
103LLooggggiinngg aanndd NNoottiiffiiccaattiioonn SSyynnooppssiiss
104 mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp
105 [‐‐‐‐mmaaiillttoo _a_d_d_r_e_s_s]
106 [‐‐‐‐mmaaiill‐‐ppoolliiccyy
107_a_l_w_a_y_s_|_n_e_v_e_r_|_o_n_l_y_‐_o_n_‐_e_r_r_o_r]
108 [‐‐‐‐ccoommmmeenntt "_c_o_m_m_e_n_t _s_t_r_i_n_g"]
109 [‐‐‐‐qquuiieett|‐‐‐‐nnoo‐‐qquuiieett]
110 [‐‐‐‐vveerrbboossee]
111
112DDEESSCCRRIIPPTTIIOONN
113 ZRM for MySQL provides automated scheduling of live
114MySQL database
115 backup. You only need to configure it once to reflect the
116MySQL deploy‐
117 ment, then schedule it to run unattended backups. Vari‐
118ous options can
119 help an administrator:
120
121 * Verify the backups created.
122
123 * Generate various types of reports about the backups cre‐
124ated.
125
126 * Specify compression and encryption as desired.
127
128 * Report information about the backups via an email or RSS
129feed.
130
131 * Access pre‐ and post‐ backup plugins to extend the suite
132further.
133
134 * Control full and selective restore operations on the
135database, both
136 locally and remotely.
137
138 mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp provides the core backup functions of
139ZRM for MySQL
140 databases.
141
142 Use the mmyyssqqll‐‐zzrrmm..ccoonnff(5) configuration file to set
143mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp
144 options described on this page. Use the ‐‐‐‐aaccttiioonn cchheecckk
145option to ver‐
146 ify the configuration of mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp.
147
148 Use mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp to create full or incremental back‐
149ups of MySQL
150 databases.
151
152 To display help on individual action options, append the
153‐‐help option
154 to the command line. For example: ’mysql‐zrm‐backup
155‐‐options‐file
156 ‐‐help’
157
158BBAACCKKUUPP SSEETTSS
159 ZRM for MySQL organizes backups into Backup Sets.
160Each backup set
161 defines the list of databases or tables within a data‐
162base, how it
163 should be backed up and the backup schedule for the da‐
164ta. Backup sets
165 are identified by a unique name.
166
167 Every backup run (each time mmyyssqqll‐‐zzrrmm is executed) is as‐
168sociated with
169 one backup set. Various parameters can be associated
170with each backup
171 run.
172
173 mmyyssqqll‐‐zzrrmm first reads the global configu‐
174ration file
175 (//eettcc//mmyyssqqll‐‐zzrrmm//mmyyssqqll‐‐zzrrmm..ccoonnff). The global configura‐
176tion file can be
177 overridden by backup set specific configuration file
178stored in
179 //eettcc//mmyyssqqll‐‐zzrrmm//_b_a_c_k_u_p _s_e_t _n_a_m_e directory. The mmyyssqqll‐‐zzrrmm
180command line
181 options will override the parameters specified in the
182configuration
183 files.
184
185
186
187
188
189
190BBAACCKKUUPP MMEETTHHOODDSS
191 mmyyssqqll‐‐zzrrmm backups can be either full or incremental.
192Full backups can
193 be logical backups or raw backups. Logical backups con‐
194tain SQL state‐
195 ments to recreate the database. Raw backups are actual
196copies of the
197 database files.
198
199 When logical backup is specified, the utility uses only
200mmyyssqqlldduummpp for
201 backing up specified databases and tables.
202
203 When raw backup is specified, the utility has the
204ability to decide
205 which backup mechanism to use for a particular database.
206If there are
207 no transactional storage engine based tables in the speci‐
208fied database,
209 then it uses mmyyssqqllhhoottccooppyy for backing up that database.
210Otherwise, it
211 uses mmyyssqqlldduummpp for backing up the specified database.
212
213 Snapshot backups are discussed in the Snapshot Options
214section of this
215 man page.
216
217 When rreepplliiccaattiioonn is specified and if the MySQL server is a
218replication
219 slave, then it will also backup all replication related
220files.
221
222 When ddeessttiinnaattiioonn specified then the backups are stored in
223a sub‐direc‐
224 tory under the specified directory. Default path is
225//vvaarr//lliibb//mmyyssqqll‐‐zzrrmm.
226 If the destination specified does not exist, it will
227return an error
228 and exit; the utility does not create the directory.
229
230 An index file is also created in the backup directory. The
231index is a
232 file that contains the details of what was backed up, how
233much data was
234 backed up, what parameters were used to backup the data,
235how much time
236 it took to backup etc.
237
238 When an incremental backup is specified, the follow‐
239ing options are
240 ignored:
241
242 bbaacckkuupp‐‐mmooddee,
243
244 ssnnaappsshhoott‐‐pplluuggiinn,
245
246 aallll‐‐ddaattaabbaasseess,
247
248 ddaattaabbaasseess,
249
250 ddaattaabbaassee
251
252 ttaabblleess
253
254
255OOPPTTIIOONNSS
256 You can select a backup set by name on the command
257line, or select
258 source database(s), backup methods, plugins, etc. by us‐
259ing the options
260 described in the Options subsections that follow. You can
261also specify
262 mysql‐zrm‐backup options in a configuration file speci‐
263fied using the
264 ‐‐‐‐ooppttiioonnss switch.
265
266
267 ‐‐‐‐bbaacckkuupp‐‐sseett _n_a_m_e
268 Specify backup‐set for the backup run. This is a
269Command line
270 option only and cannot be specified in the con‐
271figuration file.
272 The default value is _B_a_c_k_u_p_S_e_t_1. If such a value
273is already
274 present, it will be used.
275
276 ‐‐‐‐ooppttiioonnss‐‐ffiillee _c_o_n_f___f_i_l_e
277 Set the file along with full pathname
278that contains
279 mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp configuration options; this file
280has the same
281 format as mmyyssqqll‐‐zzrrmm..ccoonnff(5).
282
283 ‐‐‐‐hheellpp Displays the help message and exits. This com‐
284mand‐line‐only
285 parameter cannot be specified in the configuration
286file.
287
288
289BBaacckkuupp SSoouurrccee OOppttiioonnss
290 ‐‐‐‐aallll‐‐ddaattaabbaasseess
291 Opt for all databases to be backed up or restored.
292This is the
293 default if _d_a_t_a_b_a_s_e or _d_a_t_a_b_a_s_e_s are not specified.
294
295 ‐‐‐‐ddaattaabbaasseess _"_n_a_m_e_1 _n_a_m_e_2 _._._._"
296 List the databases to backup or restore.
297
298 ‐‐‐‐ddaattaabbaassee _n_a_m_e [‐‐‐‐ttaabblleess "_n_a_m_e_1 _n_a_m_e_2 _._._."]
299 List the tables that should be backed up. This
300option is valid
301 during the backup operation only.
302
303 ‐‐‐‐eexxcclluuddee‐‐ppaatttteerrnn _"_p_a_t_t_e_r_n_"
304 All databases or tables that match the _p_a_t_t_e_r_n are
305not backed
306 up. If ‐‐‐‐aallll‐‐ddaattaabbaasseess or ‐‐‐‐ddaattaabbaasseess are speci‐
307fied, the exclude
308 pattern applies to database names. If ‐‐‐‐ddaattaabbaassee
309is specified,
310 the exclude pattern applies to table names. Wild‐
311card characters
312 _* (match one or more characters), _? (match one
313character), _[_]
314 (match one of the characters specified within
315parenthesis) and _|
316 (match one of the patterns) are supported. For ex‐
317ample: Exclude
318 pattern "*_db|dbase[123]|abcd" will match names
319tom_db, dbase1,
320 dbase2, abcd. All tables or databases that match
321this pattern
322 will be excluded. Character _# is not permitted
323in the exclude
324 pattern.
325
326 ‐‐‐‐rroouuttiinneess|‐‐‐‐nnoo‐‐rroouuttiinneess
327 If ‐‐‐‐rroouuttiinneess is specified then mysqldump will dump
328stored rou‐
329 tines. The default is ‐‐‐‐nnoo‐‐rroouuttiinneess. This parameter
330is optional.
331
332 ‐‐‐‐mmyyssqqll‐‐bbiinnppaatthh _m_y_s_q_l___c_o_m_m_a_n_d___d_i_r
333 Set the full path where mysql binary commands
334are installed.
335 For example: //oopptt//llaammpppp//bbiinn.
336
337 ‐‐‐‐mmyyssqqll‐‐bbiinnlloogg‐‐ppaatthh _m_y_s_q_l___b_i_n_a_r_y___l_o_g___l_o_c_a_t_i_o_n
338 Set the full path of the location of mysql bi‐
339nary logs. For
340 example: //vvaarr//lloogg//mmyyssqqll
341
342 ‐‐‐‐ccoonnffiigg‐‐ffiillee‐‐lliisstt==""_l_i_s_t___f_i_l_e___p_a_t_h""
343 Intended for configuration file backup, this op‐
344tional parameter
345 lets you specify a list of files to backup during
346a full backup
347 of any type (snapshot, logical, or raw). The
348_l_i_s_t___f_i_l_e___p_a_t_h is
349 the path to the file that contains the list of
350configuration
351 files to back up. The list itself should specify
352full pathnames,
353 separated by newlines.
354
355 The config‐file‐list is processed after the main
356data has been
357 backed up, and the list file itself is copied to
358the destination
359 directory along with the configuration files. The
360backup index
361 will record the config‐file‐list parameter.
362
363 Files specified by config‐file‐list will be re‐
364stored during a
365 full restore to their original locations, preserv‐
366ing permissions
367 and ownership.
368
369
370
371MMyySSQQLL AAcccceessss OOppttiioonnss
372 ‐‐‐‐uusseerr _u_s_e_r
373 Specify MySQL backup/restore user on the MySQL
374server. If no
375 user is specified here, ensure that you have
376the MySQL user
377 specified in the mmyy..ccnnff or ‐‐‐‐ooppttiioonnss file has
378the necessary
379 privileges.
380
381 ‐‐‐‐ppaasssswwoorrdd _p_a_s_s_w_o_r_d
382 Specify password for the MySQL user. If you wish
383to prevent the
384 password from being sent in plaintext over the net‐
385work, you may
386 wish to configure the MySQL username and pass‐
387word using the
388 MySQL mmyy..ccnnff or ‐‐‐‐ooppttiioonnss file.
389
390 ‐‐‐‐hhoosstt _h_o_s_t_n_a_m_e
391 Specify MySQL server host name or IP name.
392
393 ‐‐‐‐ppoorrtt _p_o_r_t_n_u_m_b_e_r
394 Specify MySQL server port.
395
396 ‐‐‐‐ssoocckkeett _n_a_m_e
397 Specify socket file to use for communication with
398MySQL server.
399
400 ‐‐‐‐ssssll‐‐ooppttiioonnss "_M_y_S_Q_L _s_s_l _o_p_t_i_o_n_s"
401 Set any ‐‐‐‐ssssll** options that MySQL supports. Refer
402to MySQL Docu‐
403 mentation for SSL options details.
404
405 ‐‐‐‐ssiinnggllee‐‐ttrraannssaaccttiioonn [aallwwaayyss|nneevveerr|oonnllyy‐‐iinnnnooddbb]
406 The ssiinnggllee‐‐ttrraannssaaccttiioonn option controls under what
407circumstances
408 MySQL for ZRM will pass the ‐‐‐‐ssiinnggllee‐‐ttrraannssaaccttiioonn
409ooppttiioonn sseettttiinngg
410 ttoo mmyyssqqlldduummpp when executing a database dump. Spec‐
411ifying aallwwaayyss
412 causes ‐‐‐‐ssiinnggllee‐‐ttrraannssaaccttiioonn to always be passed,
413nneevveerr causes
414 the ‐‐‐‐ssiinnggllee‐‐ttrraannssaaccttiioonn to never be passed, and
415oonnllyy‐‐iinnnnooddbb
416 specifies that ‐‐‐‐ssiinnggllee‐‐ttrraannssaaccttiioonn will only be
417passed during
418 innodb‐only backups. For example, if oonnllyy‐‐iinnnnooddbb
419is specified,
420 the ‐‐‐‐ssiinnggllee‐‐ttrraannssaaccttiioonn wwiillll nnoott bbee ppaasssseedd ffoorr
421bbaacckkuuppss tthhaatt
422 iinncclluuddee mmyyiissaamm oorr ootthheerr nnoonn‐‐ttrraannssaaccttiioonnaall ttaabblleess..
423
424 ‐‐‐‐eexxttrraa‐‐mmyyssqqlldduummpp‐‐ooppttiioonnss=="" _m_y_s_q_l_d_u_m_p___o_p_t_i_o_n_s""
425 Use this to pass any extra mmyyssqqlldduummpp options when
426ZRM for MySQL
427 executes a mmyyssqqlldduummpp_. _F_o_r _e_x_a_m_p_l_e_, _i_f _y_o_u _r_e_q_u_i_r_e
428mmyyssqqlldduummpp to
429 be run with the ‐‐‐‐fflluusshh‐‐llooggss and ‐‐‐‐nnoo‐‐ccrreeaattee‐‐iinnffoo
430options, spec‐
431 ify ‐‐‐‐eexxttrraa‐‐mmyyssqqlldduummpp‐‐ooppttiioonnss==""‐‐‐‐fflluusshh‐‐llooggss
432‐‐‐‐nnoo‐‐ccrreeaattee‐‐iinnffoo"" in
433 the mysql‐zrm.conf file.
434
435 ‐‐‐‐eexxttrraa‐‐mmyydduummppeerr‐‐ooppttiioonnss=="" _m_y_d_u_m_p_e_r___o_p_t_i_o_n_s""
436 Use this to pass any extra mmyydduummppeerr options when
437ZRM for MySQL
438 executes a mmyydduummppeerr_. _F_o_r _e_x_a_m_p_l_e_, _i_f _y_o_u _r_e_q_u_i_r_e
439mmyydduummppeerr to be
440 run with the ‐‐‐‐tthhrreeaaddss and ‐‐‐‐rreeggeexx op‐
441tions, specify
442 ‐‐‐‐eexxttrraa‐‐mmyydduummppeerr‐‐ooppttiioonnss==""‐‐‐‐tthhrreeaaddss==44
443‐‐‐‐rreeggeexx==’’RReegguullaarr eexxpprreess‐‐
444 ssiioonn ffoorr ’’ddbb..ttaabbllee’’ mmaattcchhiinngg’’"" in the mysql‐
445zrm.conf file.
446
447BBaacckkuupp MMeetthhoodd OOppttiioonnss
448 ‐‐‐‐bbaacckkuupp‐‐lleevveell _l_e_v_e_l
449 Choose 0 for full backup. Choose 1 for incremen‐
450tal back up.
451 Default is full backup.
452
453 ‐‐‐‐bbaacckkuupp‐‐mmooddee rraaww|llooggiiccaall
454 Database/tables that use a transactional engine
455cannot be backed
456 up by mmyyssqqlldduummpp. They should be backed up by
457mmyyssqqllhhoottccooppyy.
458 Choose rraaww to use mmyyssqqllhhoottccooppyy to back up the
459database/tables
460 that use a transactional engine. Choose llooggiiccaall to
461use mmyyssqqll‐‐
462 dduummpp to back up the database/tables that don’t
463use a transac‐
464 tional engine. Default value is rraaww.
465
466 ‐‐‐‐llooggiiccaall‐‐ppaarraalllleell |11
467 Choose 0 for mysqldump backup. Choose 1 for my‐
468dumper muti‐thread
469 logical back up. Default is mydsqldump backup.
470
471 ‐‐‐‐ssyynncchhrroonnoouuss‐‐cchheecckkssuumm | ‐‐‐‐nnoo‐‐ssyynncchhrroonnoouuss‐‐cchheecckkssuumm
472 Specifies whether a checksum should be pro‐
473duced during the
474 backup process. Default is
475nnoo‐‐ssyynncchhrroonnoouuss‐‐cchheecckkssuumm, in which
476 case the checksum is produced only after the
477backup process is
478 complete. Specifying ‐‐‐‐ssyynncchhrroonnoouuss‐‐cchheecckkssuumm
479significantly
480 increases overall backup times.
481
482 ‐‐‐‐rreepplliiccaattiioonn | ‐‐‐‐nnoorreepplliiccaattiioonn
483 Choose replication to backup replication files.
484They will be
485 backed up only if the host is a replication
486slave. Default
487 option is ‐‐‐‐nnoorreepplliiccaattiioonn.
488
489 ‐‐‐‐ddeeffaauulltt‐‐cchhaarraacctteerr‐‐sseett _c_h_a_r___s_e_t___n_a_m_e
490 The default character set that mysqldump
491should use. If not
492 specified utf8 is used. This parameter is optional.
493
494 ‐‐‐‐ccoommpprreessss‐‐ddaattaa‐‐dduurriinngg‐‐ttrraannssppoorrtt
495 If the value is set to 1, the backup is com‐
496pressed when it
497 transferred from MySQL server to ZRM server. Set‐
498ting the value
499 to zero, no compression is performed. No compres‐
500sion is per‐
501 formed by default. Data compression during trans‐
502fer is indepen‐
503 dent of the Backup compression parameter.
504
505
506PPlluuggiinn OOppttiioonnss
507 ‐‐‐‐pprree‐‐bbaacckkuupp‐‐pplluuggiinn _p_l_u_g_i_n
508 (Optional) Specify the plugin along with full
509pathname to be
510 called before a backup run. All pre‐backup plugin
511scripts must
512 accept the following command‐line parameters (which
513are passed
514 to the plugin using ‐‐‐‐pprree‐‐bbaacckkuupp‐‐pplluuggiinn‐‐ooppttiioonnss:
515
516 ‐‐‐‐aallll‐‐ddaattaabbaasseess
517 Use when all databases on the server are being
518backed up.
519
520 ‐‐‐‐ddaattaabbaassee _d_a_t_a_b_a_s_e_1 _d_a_t_a_b_a_s_e_2......
521 Use when selected databases are being backed
522up.
523
524 ‐‐‐‐ddaattaabbaassee ddaattaabbaassee ‐‐‐‐ttaabblleess ttaabbllee11 ttaabbllee22......
525 Use if selected tables are being backed up.
526
527 The script should be written to return a non‐
528zero value on
529 error; pre‐backup plugin failures should cancel the
530backup and
531 generate a failure message for reports and logs.
532
533 ‐‐‐‐pprree‐‐bbaacckkuupp‐‐pplluuggiinn‐‐ooppttiioonnss ""_o_p_t_i_o_n_1 _o_p_t_i_o_n_2...""
534 Pass options to the pprree‐‐bbaacckkuupp‐‐pplluuggiinn as one of the
535command line
536 arguments.
537
538 ‐‐‐‐ccooppyy‐‐pplluuggiinn _p_l_u_g_i_n
539 Specify plugin along with full pathname to be used
540for transfer‐
541 ring backup files to and from a remote MySQL
542server to the
543 machine running ZRM for MySQL. Use this option
544when
545 1. remote incremental backup is required
546 2. copying replication related files from a re‐
547mote machine
548 3. execute mmyyssqqllhhoottccooppyy (MySQL command) and
549copy the data
550 from the remote machine
551 4. restore data to a remote machine using
552mmyyssqqllhhoottccooppyy(MySQL
553 command). This parameter is optional.
554
555 ‐‐‐‐sssshh‐‐uusseerr _u_s_e_r
556 Specifies the user to be used for SSH. This param‐
557eter is only
558 used by the ssh‐copy.pl plugin. The user specified
559should either
560 be the user mmyyssqqlldd runs as or root. If not speci‐
561fied the default
562 value used is mmyyssqqll. This parameter is optional.
563
564 ‐‐‐‐sssshh‐‐iiddeennttiiffyy‐‐ffiillee _f_i_l_e_n_a_m_e
565 Selects a file from which the identity (private
566key) for RSA or
567 DSA authentication is read. This identity file is
568used by the
569 ssh‐copy.pl plugin for authentication.
570
571 ‐‐‐‐rreemmoottee‐‐mmyyssqqll‐‐bbiinnppaatthh _p_a_t_h
572 Full path where mysql binaries are installed
573on the remote
574 machine. For example: //oopptt//llaammpppp//bbiinn. This param‐
575eter is only
576 used by the socket‐copy.pl and ssh‐copy.pl plugins.
577If not spec‐
578 ified, the default value used is //uussrr//bbiinn.
579
580 ‐‐‐‐ssoocckkeett‐‐rreemmoottee‐‐ppoorrtt _p_o_r_t
581 Port that the socket‐plugin.pl should use to
582connect. This
583 parameter is only used by the socket‐copy.pl
584plugin. If not
585 specified the default value used is 25300. This
586parameter is
587 optional
588
589 ‐‐‐‐ppoosstt‐‐bbaacckkuupp‐‐pplluuggiinn _p_l_u_g_i_n
590 Set the plugin along with full pathname to be
591called after a
592 backup run. If synchronous‐checksum is not set or
593its value is
594 set to zero, the post backup plugin is called
595twice, once at the
596 end of backup and once when the checksum is fin‐
597ished.
598
599
600 ‐‐‐‐ppoosstt‐‐bbaacckkuupp‐‐pplluuggiinn‐‐ooppttiioonnss ""_O_p_t_i_o_n_1 _O_p_t_i_o_n_2 _O_p_t_i_o_n_3
601_O_p_t_i_o_n_4...""
602 _o_p_t_i_o_n_1 is the value of
603ppoosstt‐‐bbaacckkuupp‐‐pplluuggiinn‐‐ooppttiioonnss from the
604 mmyyssqqll‐‐zzrrmm..ccoonnff(5) file. _o_p_t_i_o_n_2 is the data being
605backed up. It
606 will be either
607
608 ‐‐‐‐aallll‐‐ddaattaabbaasseess
609 Use when all databases on the server are being
610backed up.
611
612 ‐‐‐‐ddaattaabbaassee _d_a_t_a_b_a_s_e_1 _d_a_t_a_b_a_s_e_2......
613 Use when selected databases are being backed
614up.
615
616 ‐‐‐‐ddaattaabbaassee ddaattaabbaassee ‐‐‐‐ttaabblleess ttaabbllee11 ttaabbllee22......
617 Use if selected tables are being backed up.
618
619 _O_p_t_i_o_n_3 will be ‐‐‐‐bbaacckkuupp‐‐ddiirreeccttoorryy _p_a_t_h
620
621 _O_p_t_i_o_n_4 will be ‐‐‐‐cchheecckkssuumm‐‐ppeennddiinngg or it will be
622‐‐‐‐cchheecckkssuumm‐‐ffiinn‐‐
623 iisshheedd if synchronous‐checksum is set to 1.
624
625 If synchronous‐checksum is not set or its value is
626set to zero,
627 the post‐backup‐plugin is called again and it will
628have 3 param‐
629 eters First parameter is the value of
630ppoosstt‐‐bbaacckkuupp‐‐pplluuggiinn‐‐ooppttiioonnss
631 from the mmyyssqqll‐‐zzrrmm..ccoonnff(5) configuration file.
632Second parameter
633 will be ‐‐‐‐bbaacckkuupp‐‐ddiirreeccttoorryy _p_a_t_h. Third param‐
634eter will be
635 ‐‐‐‐cchheecckkssuumm‐‐ffiinniisshheedd.
636
637CCoommpprreessssiioonn aanndd EEnnccrryyppttiioonn OOppttiioonnss
638 ‐‐‐‐ccoommpprreessss | ‐‐‐‐nnoo‐‐ccoommpprreessss
639 Choose whether the files should be compressed using
640the utility
641 specified by the ‐‐‐‐ccoommpprreessss‐‐pplluuggiinn. The
642default is
643 ‐‐‐‐nnoo‐‐ccoommpprreessss.
644
645 ‐‐‐‐ccoommpprreessss‐‐mmyyssqqlldduummpp‐‐oonntthheeffllyy |
646‐‐‐‐nnoo‐‐ccoommpprreessss‐‐mmyyssqqlldduummpp‐‐oonntthheeffllyy
647 Choose whether to compress the data dumped by
648mmyyssqqlldduummpp on the
649 fly. Default compression command used is ggzziipp.
650Default is no
651 compression on the fly.
652
653 ‐‐‐‐ccoommpprreessss‐‐pplluuggiinn _p_l_u_g_i_n___n_a_m_e
654 Use _p_l_u_g_i_n___n_a_m_e to specify a path to the utility to
655use for com‐
656 pression. The default is ggzziipp.
657
658 ‐‐‐‐nnoo‐‐eennccrryypptt | ‐‐‐‐eennccrryypptt
659 Choose whether the files should be encrypted us‐
660ing the utility
661 specified by the ‐‐‐‐eennccrryypptt‐‐pplluuggiinn. The default is
662‐‐‐‐nnoo‐‐eennccrryypptt.
663
664 ‐‐‐‐eennccrryypptt‐‐pplluuggiinn pplluuggiinn__nnaammee [‐‐‐‐ddeeccrryypptt‐‐ooppttiioonn [_o_p_t_i_o_n]
665 Use pplluuggiinn__nnaammee to specify a utility to use
666for compression
667 along with its full path. If ddeeccrryypptt‐‐ooppttiioonn is
668not specified
669 then the ‐‐dd option of encrypt‐plugin is used for
670decrypting.
671
672 ‐‐‐‐ppaassssffiillee _f_i_l_e_n_a_m_e
673
674SSnnaappsshhoott PPlluuggiinn OOppttiioonnss
675 ‐‐‐‐ssnnaappsshhoott‐‐pplluuggiinn==""_p_l_u_g_i_n___p_a_t_h_n_a_m_e""
676 Specifies the plugin to be used for snapshot
677operations. The
678 default is the lvm‐snapshot plugin.
679
680 [‐‐‐‐cchheecckk‐‐iinnnnooddbb | ‐‐‐‐nnoo‐‐cchheecckk‐‐iinnnnooddbb]
681 Specifies whether to check for iinnnnooddbb shared data
682and log files
683 to back up during every snapshot‐based based
684backup. If
685 ‐‐‐‐cchheecckk‐‐iinnnnooddbb is specified, iinnnnooddbb shared data
686and logs are
687 only backed up if the databases being backed up
688use iinnnnooddbb. If
689 ‐‐‐‐nnoo‐‐cchheecckk‐‐iinnnnooddbb is specified (the default),
690the iinnnnooddbb
691 databases and logs are backed up regardless of
692whether they are
693 relevant. The default value is ‐‐‐‐nnoo‐‐cchheecckk‐‐iinnnnooddbb,
694which means
695 iinnnnooddbb shared data and logs are always copied
696if the iinnnnooddbb
697 engine is enabled in MySQL. In most cases,
698‐‐‐‐nnoo‐‐cchheecckk‐‐iinnnnooddbb
699 provides the best performance.
700
701 ‐‐‐‐ssnnaappsshhoott‐‐ssiizzee _s_i_z_e
702 Set the size of the llvvmm‐‐ssnnaappsshhoott to be generated.
703For rraaww back‐
704 ups, each specified database is first checked en‐
705sure that it is
706 on a LVM volume, and then a snapshot of the
707specified size is
708 created and used to backup the database. If
709the specified
710 database is not on a LVM volume, either
711mmyyssqqllhhoottccooppyy or mmyyssqqll‐‐
712 dduummpp will be used to create the backup based on the
713logic speci‐
714 fied by the ‐‐‐‐bbaacckkuupp‐‐mmooddee option. This option is
715ignored if the
716 ‐‐‐‐bbaacckkuupp‐‐mmooddee is llooggiiccaall.
717
718 ‐‐‐‐bbaacckkuupp‐‐ttyyppee rreegguullaarr|‐‐‐‐bbaacckkuupp‐‐ttyyppee qquuiicckk
719 Choose the method of snapshot backup. The rreegguullaarr
720option speci‐
721 fies that the snapshot should be copied into a
722standard ZRM for
723 MySQL backup archive. The qquuiicckk option specifies
724that the snap‐
725 shot itself should be used as a near‐line backup.
726Quick backups
727 are convenient as they provide near‐instantaneous
728restores, but
729 because they remain on the MySQL server they
730do not protect
731 against media or server failure. Note that if the
732’’’quick’’’
733 option is specified, the ’’’compress’’’ and
734’’’encrypt’’’
735 options are ignored, and the backup size will al‐
736ways be zero. In
737 addition, no checksums are performed, which
738means that quick
739 snapshot backups cannot be verified.
740
741BBaacckkuupp DDeessttiinnaattiioonn OOppttiioonnss
742 ‐‐‐‐bbaacckkuupp‐‐nnaammee _i_m_a_g_e___n_a_m_e
743 Specify a unique name to store the backup. If a
744name is not
745 specified or it already exists in the ‐‐‐‐ddeessttiinnaattiioonn
746_d_i_r_p_a_t_h (see
747 the next option), the backup image will be named
748with the cur‐
749 rent date and time.
750
751 ‐‐‐‐ddeessttiinnaattiioonn _d_i_r___p_a_t_h
752 Specify the directory to store the backup. The de‐
753fault location
754 is //vvaarr//lliibb//mmyyssqqll‐‐zzrrmm//. If a directory other than
755the default is
756 specified, you must create it manually on both the
757MySQL server
758 and the ZRM server, and it must have permissions
759set to allow
760 read/write access to the mysql backup user.
761
762LLooggggiinngg aanndd NNoottiiffiiccaattiioonn OOppttiioonnss
763 ‐‐‐‐mmaaiillttoo _a_d_d_r_e_s_s
764 Set the address to which a backup report will be
765sent.
766
767 ‐‐‐‐mmaaiill‐‐ppoolliiccyy _a_l_w_a_y_s_|_n_e_v_e_r_|_o_n_l_y_‐_o_n_‐_e_r_r_o_r
768 Mail policy determines when email notification
769should be sent.
770 The value _a_l_w_a_y_s is the default value and email no‐
771tification is
772 sent for all events. If the mail policy is set to
773_n_e_v_e_r, email
774 notification is not sent for all events. If the
775mail policy is
776 set to _o_n_l_y_‐_o_n_‐_e_r_r_o_r, notification is sent
777when there is a
778 backup failure if mmaaiillttoo is specified.
779
780 ‐‐‐‐ccoommmmeenntt "_C_o_m_m_e_n_t _s_t_r_i_n_g"
781 Insert a comment or a note about the backup run.
782This can be
783 used to tag backup runs and the note can re‐
784trieved using the
785 mmyyssqqll‐‐zzrrmm‐‐rreeppoorrtteerr(1) utility.
786
787 ‐‐‐‐qquuiieett | ‐‐‐‐nnoo‐‐qquuiieett
788 Choose quiet to suppress display of log messages
789on stdout.
790 Choose _n_o_‐_q_u_i_e_t to display the log messages std‐
791out. Default is
792 ‐‐‐‐nnoo‐‐qquuiieett.
793
794 ‐‐‐‐vveerrbboossee
795 Provide verbose output in the log. Default is that
796verbose is
797 turned off and a terse output is generated.
798
799
800 FFIILLEESS
801
802 //vvaarr//lliibb//mmyyssqqll‐‐zzrrmm
803 Default directory for storing all backup data.
804
805
806 //eettcc//mmyyssqqll‐‐zzrrmm//_b_a_c_k_u_p _s_e_t _n_a_m_e//mmyyssqqll‐‐zzrrmm..ccoonnff
807 Default location for the backup‐set configuration
808file used by
809 the mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp utility.
810
811
812RREETTUURRNN VVAALLUUEESS
813 On success, zero is returned. On error, non‐zero value is
814returned.
815
816
817SSEEEE AALLSSOO
818 mysql‐zrm(1), mysql‐zrm‐manage‐backup(1), mysql‐
819zrm‐restore(1),
820 mysql‐zrm‐check(1), mysql‐zrm‐list(1), mysql‐
821zrm‐getconf(1),
822 mysql‐zrm‐setconf(1), mysql‐zrm‐parse‐binlogs(1), mysql‐
823zrm‐purge(1),
824 mysql‐zrm‐extract‐backup(1), mysql‐zrm‐ver‐
825ify‐backup(1),
826 mysql‐zrm‐abort‐backup(1), mysql‐zrm‐
827scheduler(1),
828 mysql‐zrm‐reporter(1), mysql‐zrm.conf(5), mysqldump(1),
829mysqlbinlog(1),
830 mysql(1), lvm(8), Zmanda Recovery Manager for MySQL
831(http://mysql‐
832 backup.zmanda.com/)
833
834
835AAUUTTHHOORR
836 Zmanda Inc. (http://www.zmanda.com)
837
838
839
840Zmanda, Inc. ZRM for MySQL mysql‐
841zrm‐backup(1)
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858