1mysql‐zrm‐scheduler(1)                                     mysql‐
2zrm‐scheduler(1)
3
4
5
6NNAAMMEE
7       mmyyssqqll‐‐zzrrmm‐‐sscchheedduulleerr ‐ backup scheduler utility for ZRM for
8MySQL
9
10SSYYNNOOPPSSIISS
11       mmyyssqqll‐‐zzrrmm‐‐sscchheedduulleerr ‐‐‐‐aadddd|‐‐‐‐qquueerryy|‐‐‐‐ddeelleettee|‐‐‐‐nnooww
12                       [‐‐‐‐ssttaarrtt‐‐ttiimmee _s_t_a_r_t _t_i_m_e]
13                       [‐‐‐‐ddaayy‐‐ooff‐‐wweeeekk _d_a_y _o_f _w_e_e_k]
14                       [‐‐‐‐ddaayy‐‐ooff‐‐mmoonntthh _d_a_y _o_f _m_o_n_t_h]
15                       [‐‐‐‐iinntteerrvvaall _i_n_t_e_r_v_a_l]
16                       [‐‐‐‐bbaacckkuupp‐‐lleevveell _l_e_v_e_l]
17                       [‐‐‐‐bbaacckkuupp‐‐sseett _b_a_c_k_u_p_s_e_t _n_a_m_e]
18                       [‐‐‐‐hheellpp]
19
20DDEESSCCRRIIPPTTIIOONN
21       mysql‐zrm‐scheduler   is   the  utility  for ZRM for MySQL
22used to schedule
23       MySQL backups using mmyyssqqll‐‐zzrrmm‐‐bbaacckkuupp(1).
24
25       At the scheduled time, this utility will   first   execute
26the  optional
27       pre‐scheduler   plugin  (see Pre‐Scheduler section) to de‐
28termine the sys‐
29       tem load before running the backup.  If  no  pre‐scheduler
30plugin  exists,
31       it will directly run the backup.
32
33       mmyyssqqll‐‐zzrrmm‐‐sscchheedduulleerr   also  implements  the  backup reten‐
34tion policy and
35       purges backup files. By default, the  backup  image  purge
36action will  be
37       performed    at   4:00am  daily.  See  mysql‐zrm‐backup(1)
38‐‐‐‐rreetteennttiioonn‐‐ppoolliiccyy
39       parameter for details.
40
41       When ‐‐‐‐nnooww option is specified,  the   mmyyssqqll‐‐zzrrmm‐‐sscchheedduulleerr
42utility  will
43       run mysql‐zrm immediately.
44
45
46OOPPTTIIOONNSS
47       ‐‐‐‐aadddd   Add   a   mmyyssqqll‐‐zzrrmm   backup   run to the schedule
48based on the time
49              specified by other options.
50
51       ‐‐‐‐ddeelleettee
52              Delete a scheduled backup run. Use the ‐‐‐‐ssttaarrtt  op‐
53tion to  delete
54              a scheduled run with specific time.
55
56       ‐‐‐‐qquueerryy
57              Display a list of backup runs scheduled.
58
59       ‐‐‐‐iinntteerrvvaall _i_n_t_e_r_v_a_l
60              Valid  options  are  daily,  weekly or monthly. De‐
61fault: weekly
62
63       ‐‐‐‐nnooww  Immediately do the backup of MySQL.
64
65       ‐‐‐‐bbaacckkuupp‐‐sseett _n_a_m_e
66              Specify the backup set name for the backup run. De‐
67fault is Back‐
68              upSet1.
69
70       ‐‐‐‐bbaacckkuupp‐‐lleevveell _L_e_v_e_l
71              Choose  0 for full backup. Choose 1 for  an  incre‐
72mental  backup.
73              Default is 0.
74
75       ‐‐‐‐ssttaarrtt‐‐ttiimmee _s_t_a_r_t _t_i_m_e
76              Start  time  for the backup run  in  HH:MM  format.
77Default values
78              are  00:00  for  monthly,  02:00  for   weekly  and
7903:00  for  daily
80              interval.
81
82       ‐‐‐‐ddaayy‐‐ooff‐‐wweeeekk _d_a_y _o_f _w_e_e_k
83              Value  used  with weekly interval  to  specify  the
84day(s) of week.
85              Use  a  single  number from 0‐6 (0=Sunday, 6=Satur‐
86day), or a  range
87              of two numbers separated with a hyphen.
88
89              Example: 1, to start on Monday
90                       0‐2, to start on Sunday, Monday and  Tues‐
91day.
92
93              Default value is 0 (Sunday).
94
95       ‐‐‐‐ddaayy‐‐ooff‐‐mmoonntthh _d_a_y _o_f _m_o_n_t_h
96              Value  used  with  monthly  interval to specify the
97day(s) of month.
98              Use a single number from 1‐31 or a  range  of   two
99numbers  sepa‐
100              rated   with   a   hyphen.  Interval must be set to
101"monthly" to use
102              this option.
103
104              Example: 2, to start on second day of the month
105                       10‐12, to start on the 10th, 11th and 12th
106day  of  the
107              month.   Default  value  is  1  (first  day  of the
108month).
109
110       ‐‐‐‐hheellpp Display help message and exits.
111
112
113PPrree‐‐SScchheedduulleerr
114       The pre‐scheduler plugin has to  be  specified  in  mysql‐
115zrm.conf(5).
116
117       mysql‐zrm‐scheduler   calls  the  specified  pre‐scheduler
118plugin before the
119       scheduled MySQL backup run.  The plugin should return  "0"
120to  continue
121       to   perform   MySQL backup run immediately. It should re‐
122turn "n" where n
123       is a positive integer smaller or equal to 11 to delay  the
124MySQL  backup
125       run by "n" hour(s) from the current time.
126
127       Returning   any   number  greater than "11" would skip the
128scheduled MySQL
129       backup run.
130
131       mysql‐zrm‐scheduler skips the daily backup  run   if   the
132pre‐scheduler
133       plugin   does   not  find  a  suitable time (return "0" or
134"n"") in 24 hours
135       (from the initial scheduled start time).
136
137       For weekly  or  monthly  backup  run,  mysql‐zrm‐scheduler
138will  perform  a
139       backup  run  at  the end of the 24 hours (from the initial
140scheduled start
141       time) even if pre‐scheduler plugin have not found a  suit‐
142able  time  in
143       the 24 hours cycle.
144
145       The   pre‐scheduler  plugin is used to tell mysql‐zrm if a
146backup should
147       happen at a particular time.
148
149       It is to be customized by the user to control  if  at  the
150scheduled  time
151       a   backup   should  run  or  not. For example: a user has
152scheduled backups
153       to happen every night at midnight. But he wants to do  de‐
154lay the  backup
155       if   the number of users in the system is more than 5. For
156this the user
157       needs to write a pre‐scheduler script that  can  determine
158how many users
159       are  there  in  the  system and inform the scheduler to go
160ahead and do
161       backup or delay the backup.
162
163
164EEXXAAMMPPLLEESS
165       To schedule a daily mysql‐zrm run that starts at 1:35pm:
166
167       ## mmyyssqqll‐‐zzrrmm‐‐sscchheedduulleerr ‐‐‐‐aadddd ‐‐iinntteerrvvaall ddaaiillyy ‐‐‐‐ssttaarrtt 1133::3355
168
169       To schedule a weekly mysql‐zrm run on Tuesday and  Wednes‐
170day:
171
172       ## mmyyssqqll‐‐zzrrmm‐‐sscchheedduulleerr ‐‐‐‐aadddd ‐‐iinntteerrvvaall wweeeekkllyy ‐‐‐‐ddaayy‐‐ooff‐‐wweeeekk
17322‐‐33
174
175       To schedule a monthly mysql‐zrm run on the  tenth  day  of
176each month:
177
178       ##    mmyyssqqll‐‐zzrrmm‐‐sscchheedduulleerr    ‐‐‐‐aadddd    ‐‐‐‐iinntteerrvvaall    mmoonntthhllyy
179‐‐‐‐ddaayy‐‐ooff‐‐mmoonntthh  1100  To
180       query scheduled runs:
181
182       ## mmyyssqqll‐‐zzrrmm‐‐sscchheedduulleerr ‐‐‐‐qquueerryy
183
184       35  13  *  *  * /usr/bin/zrm‐pre‐scheduler ‐‐action backup
185‐‐backup‐set
186       BackupSet1 ‐‐interval daily
187
188       0  2 * * 2‐3  /usr/bin/zrm‐pre‐scheduler  ‐‐action  backup
189‐‐backup‐set
190       BackupSet1  ‐‐interval weekly
191
192       0  0  10  *  *  /usr/bin/zrm‐pre‐scheduler ‐‐action backup
193‐‐backup‐set
194       BackupSet1 ‐‐interval monthly
195
196       To delete a daily mysql‐zrm run with specific start time:
197
198       ##  mmyyssqqll‐‐zzrrmm‐‐sscchheedduulleerr  ‐‐‐‐ddeelleettee  ‐‐‐‐iinntteerrvvaall ddaaiillyy ‐‐‐‐ssttaarrtt
1990088::2200
200
201FFIILLEESS
202       //vvaarr//lliibb//mmyyssqqll‐‐zzrrmm
203              Directory under which all backup data is stored.
204
205
206       //eettcc//mmyyssqqll‐‐zzrrmm//_b_a_c_k_u_p _s_e_t _n_a_m_e//mmyyssqqll‐‐zzrrmm..ccoonnff
207              Configuration file read by mysql‐zrm utility.
208
209
210RREETTUURRNN VVAALLUUEESS
211       On success, zero is returned. On error, non‐zero value  is
212returned.
213
214
215SSEEEE AALLSSOO
216       mysql‐zrm(1),     mysql‐zrm‐backup(1),      mysql‐zrm‐man‐
217age‐backup(1),
218       mysql‐zrm‐restore(1),                  mysql‐zrm‐check(1),
219mysql‐zrm‐list(1),
220       mysql‐zrm‐getconf(1),   mysql‐zrm‐setconf(1),   mysql‐zrm‐
221parse‐binlogs(1),
222       mysql‐zrm‐purge(1),           mysql‐zrm‐extract‐backup(1),
223mysql‐zrm‐ver‐
224       ify‐backup(1),                  mysql‐zrm‐abort‐backup(1),
225mysql‐zrm.conf(5),
226       mysql‐zrm‐reporter(1),   mysql(1),  Zmanda  Recovery  Man‐
227ager for MySQL
228       (http://mysqlbackup.zmanda.com/)
229
230
231AAUUTTHHOORR
232       Zmanda Inc. (http://www.zmanda.com)
233
234
235
236
237Zmanda,  Inc.                     ZRM  for MySQL           mysql‐
238zrm‐scheduler(1)
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
Impressum