blob: 6c47157fa4dcfc1e83701634a3aabdac007bb0e1 [file] [log] [blame]
marcod468a042016-06-14 22:13:03 +02001
2==================================
3cassandra
4==================================
5
6Service cassandra description
7
8Sample pillars
9==============
10
11Single cassandra service
12
13.. code-block:: yaml
14
15 cassandra:
16 server:
17 enabled: true
18 version: icehouse
19
Jiri Broulikf46f2222017-07-06 13:52:32 +020020Backup client with ssh/rsync remote host
21
22.. code-block:: yaml
23
24 cassandra:
25 backup:
26 client:
27 enabled: true
28 full_backups_to_keep: 3
29 hours_before_full: 24
30 target:
31 host: cfg01
Jiri Broulikf3ec8b42018-03-05 12:11:08 +010032 home_dir: server-home-dir
Jiri Broulikf46f2222017-07-06 13:52:32 +020033
34 .. note:: full_backups_to_keep param states how many backup will be stored locally on cassandra client.
35 More options to relocate local backups can be done using salt-formula-backupninja.
36
37
38Backup client with local backup only
39
40.. code-block:: yaml
41
42 cassandra:
43 backup:
44 client:
45 enabled: true
46 full_backups_to_keep: 3
47 hours_before_full: 24
48
49 .. note:: full_backups_to_keep param states how many backup will be stored locally on cassandra client
50
51
Martin Polreich0a165102018-03-04 17:29:53 +010052Backup client at exact times:
53
54..code-block:: yaml
55
56 cassandra:
57 backup:
58 client:
59 enabled: true
60 full_backups_to_keep: 3
61 incr_before_full: 3
62 backup_times:
Martin Polreichb81606a2018-04-25 15:30:47 +020063 day_of_week: 0
Martin Polreich0a165102018-03-04 17:29:53 +010064 hour: 4
65 minute: 52
66 compression: true
67 compression_threads: 2
68 database:
69 user: user
70 password: password
71 target:
72 host: host01
73
74 .. note:: Parameters in ``backup_times`` section can be used to set up exact
75 time the cron job should be executed. In this example, the backup job
76 would be executed every Sunday at 4:52 AM. If any of the individual
77 ``backup_times`` parameters is not defined, the defalut ``*`` value will be
78 used. For example, if minute parameter is ``*``, it will run the backup every minute,
79 which is ususally not desired.
Martin Polreichb81606a2018-04-25 15:30:47 +020080 Available parameters are ``day_of_week``, ``day_of_month``, ``month``, ``hour`` and ``minute``.
Martin Polreich0a165102018-03-04 17:29:53 +010081 Please see the crontab reference for further info on how to set these parameters.
82
83 .. note:: Please be aware that only ``backup_times`` section OR
84 ``hours_before_full(incr)`` can be defined. If both are defined,
85 the ``backup_times`` section will be peferred.
86
87 .. note:: New parameter ``incr_before_full`` needs to be defined. This
88 number sets number of incremental backups to be run, before a full backup
89 is performed.
90
91
Jiri Broulikf46f2222017-07-06 13:52:32 +020092Backup server rsync
93
94.. code-block:: yaml
95
96 cassandra:
97 backup:
98 server:
99 enabled: true
100 hours_before_full: 24
101 full_backups_to_keep: 5
102 key:
103 cassandra_pub_key:
104 enabled: true
105 key: ssh_rsa
106
Jiri Broulika6496d72018-02-28 16:21:28 +0100107Backup server without strict client restriction
108
109.. code-block:: yaml
110
111 cassandra:
112 backup:
113 restrict_clients: false
114
Martin Polreich0a165102018-03-04 17:29:53 +0100115Backup server at exact times:
116
117..code-block:: yaml
118
119 cassandra:
120 backup:
121 server:
122 enabled: true
123 full_backups_to_keep: 3
124 incr_before_full: 3
125 backup_dir: /srv/backup
126 backup_times:
Martin Polreichb81606a2018-04-25 15:30:47 +0200127 day_of_week: 0
Martin Polreich0a165102018-03-04 17:29:53 +0100128 hour: 4
129 minute: 52
130 key:
131 cassandra_pub_key:
132 enabled: true
133 key: key
134
135 .. note:: Parameters in ``backup_times`` section can be used to set up exact
136 time the cron job should be executed. In this example, the backup job
137 would be executed every Sunday at 4:52 AM. If any of the individual
138 ``backup_times`` parameters is not defined, the defalut ``*`` value will be
139 used. For example, if minute parameter is ``*``, it will run the backup every minute,
140 which is ususally not desired.
Martin Polreichb81606a2018-04-25 15:30:47 +0200141 Available parameters are ``day_of_week``, ``day_of_month``, ``month``, ``hour`` and ``minute``.
Martin Polreich0a165102018-03-04 17:29:53 +0100142 Please see the crontab reference for further info on how to set these parameters.
143
144 .. note:: Please be aware that only ``backup_times`` section OR
145 ``hours_before_full(incr)`` can be defined. If both are defined, The
146 ``backup_times`` section will be peferred.
147
148 .. note:: New parameter ``incr_before_full`` needs to be defined. This
149 number sets number of incremental backups to be run, before a full backup
150 is performed.
151
Jiri Broulikf46f2222017-07-06 13:52:32 +0200152Client restore from local backup:
153
154.. code-block:: yaml
155
156 cassandra:
157 backup:
158 client:
159 enabled: true
160 full_backups_to_keep: 3
161 hours_before_full: 24
162 target:
163 host: cfg01
164 restore_latest: 1
165 restore_from: local
166
167 .. note:: restore_latest param with a value of 1 means to restore db from the last full backup. 2 would mean to restore second latest full backup.
168
169Client restore from remote backup:
170
171.. code-block:: yaml
172
173 cassandra:
174 backup:
175 client:
176 enabled: true
177 full_backups_to_keep: 3
178 hours_before_full: 24
179 target:
180 host: cfg01
181 restore_latest: 1
182 restore_from: remote
183
184 .. note:: restore_latest param with a value of 1 means to restore db from the last full backup. 2 would mean to restore second latest full backup.
185
186
187
marcod468a042016-06-14 22:13:03 +0200188Read more
189=========
190
191* links
Filip Pytloun74cd9c62017-02-02 13:02:03 +0100192
193Documentation and Bugs
194======================
195
196To learn how to install and update salt-formulas, consult the documentation
197available online at:
198
199 http://salt-formulas.readthedocs.io/
200
201In the unfortunate event that bugs are discovered, they should be reported to
202the appropriate issue tracker. Use Github issue tracker for specific salt
203formula:
204
205 https://github.com/salt-formulas/salt-formula-cassandra/issues
206
207For feature requests, bug reports or blueprints affecting entire ecosystem,
208use Launchpad salt-formulas project:
209
210 https://launchpad.net/salt-formulas
211
212You can also join salt-formulas-users team and subscribe to mailing list:
213
214 https://launchpad.net/~salt-formulas-users
215
216Developers wishing to work on the salt-formulas projects should always base
217their work on master branch and submit pull request against specific formula.
218
219 https://github.com/salt-formulas/salt-formula-cassandra
220
221Any questions or feedback is always welcome so feel free to join our IRC
222channel:
223
224 #salt-formulas @ irc.freenode.net