forked from logicalclocks/ndb-chef
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmetadata.rb
executable file
·334 lines (251 loc) · 11.2 KB
/
metadata.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
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
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
name "ndb"
maintainer "Jim Dowling"
maintainer_email "jdowling@kth.se"
license "GPL 2.0"
description "Installs/Configures NDB (MySQL Cluster)"
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
version "0.3.0"
source_url "https://github.com/hopshadoop/ndb-chef"
depends "kagent"
depends "ulimit"
recipe "ndb::install", "Installs MySQL Cluster binaries"
recipe "ndb::mgmd", "Installs a MySQL Cluster management server (ndb_mgmd)"
recipe "ndb::ndbd", "Installs a MySQL Cluster data node (ndbd)"
recipe "ndb::mysqld", "Installs a MySQL Server connected to the MySQL Cluster (mysqld)"
recipe "ndb::memcached", "Installs a memcached Server connected to the MySQL Cluster (memcached)"
recipe "ndb::mgmd-purge", "Removes a MySQL Cluster management server (ndb_mgmd)"
recipe "ndb::ndbd-purge", "Removes a MySQL Cluster data node (ndbd)"
recipe "ndb::mysqld-purge", "Removes a MySQL Server connected to the MySQL Cluster (mysqld)"
recipe "ndb::memcached-purge", "Removes a memcached Server connected to the MySQL Cluster (memcached)"
recipe "ndb::purge", "Removes all data and all binaries related to a MySQL Cluster installation"
recipe "ndb::_test", "A unit-test used for testing this cookbook"
supports 'ubuntu', ">= 14.04"
supports 'rhel', ">= 7.0"
supports 'centos', ">= 7.0"
#
# Required Attributes
#
attribute "ndb/url",
:description => "Download URL for MySQL Cluster binaries",
:type => 'string'
attribute "ndb/MaxNoOfExecutionThreads",
:description => "Number of execution threads for MySQL Cluster",
:type => 'string'
attribute "ndb/DataMemory",
:description => "Data memory for each MySQL Cluster Data Node",
:type => 'string',
:required => "required"
attribute "ndb/IndexMemory",
:description => "Index memory for each MySQL Cluster Data Node",
:type => 'string'
attribute "memcached/mem_size",
:description => "Memcached data memory size",
:type => 'string'
attribute "ndb/version",
:description => "MySQL Cluster Version",
:type => 'string'
attribute "ndb/user",
:description => "User that runs ndb database",
:type => 'string'
attribute "ndb/group",
:description => "Group that runs ndb database",
:type => 'string'
attribute "ndb/BackupDataDir",
:description => "Directory to store mysql cluster backups in",
:type => 'string'
attribute "mysql/user",
:description => "User that runs mysql server",
:required => "required",
:type => 'string'
attribute "mysql/password",
:description => "Password for hop mysql user",
:required => "required",
:type => 'string'
attribute "mysql/dir",
:description => "Directory in which to install MySQL Binaries",
:type => 'string'
attribute "mysql/localhost",
:description => "MySQL server binds to localhost (not a public/private network interface)",
:type => 'string'
attribute "mysql/replication_enabled",
:description => "Enable replication for the mysql server",
:type => 'string'
attribute "ndb/wait_startup",
:description => "Max amount of time a MySQL server should wait for the ndb nodes to be up",
:type => 'string'
attribute "ndb/mgm_server/port",
:description => "Port used by Mgm servers in MySQL Cluster",
:type => 'string'
attribute "ndb/NoOfReplicas",
:description => "Num of replicas of the MySQL Cluster Data Nodes",
:type => 'string'
attribute "ndb/FragmentLogFileSize",
:description => "FragmentLogFileSize",
:type => 'string'
attribute "ndb/MaxNoOfAttributes",
:description => "MaxNoOfAttributes",
:type => 'string'
attribute "ndb/MaxNoOfConcurrentIndexOperations",
:description => "Increase for higher throughput at the cost of more memory",
:type => 'string'
attribute "ndb/MaxNoOfConcurrentScans",
:description => "Increase for higher throughput at the cost of more memory",
:type => 'string'
attribute "ndb/MaxNoOfConcurrentOperations",
:description => "Increase for higher throughput at the cost of more memory",
:type => 'string'
attribute "ndb/MaxNoOfTables",
:description => "MaxNoOfTables",
:type => 'string'
attribute "ndb/MaxNoOfOrderedIndexes",
:description => "MaxNoOfOrderedIndexes",
:type => 'string'
attribute "ndb/MaxNoOfUniqueHashIndexes",
:description => "MaxNoOfUniqueHashIndexes",
:type => 'string'
attribute "ndb/MaxDMLOperationsPerTransaction",
:description => "MaxDMLOperationsPerTransaction",
:type => 'string'
attribute "ndb/TransactionBufferMemory",
:description => "TransactionBufferMemory",
:type => 'string'
attribute "ndb/MaxParallelScansPerFragment",
:description => "MaxParallelScansPerFragment",
:type => 'string'
attribute "ndb/MaxDiskWriteSpeed",
:description => "MaxDiskWriteSpeed",
:type => 'string'
attribute "ndb/MaxDiskWriteSpeedOtherNodeRestart",
:description => "MaxDiskWriteSpeedOtherNodeRestart",
:type => 'string'
attribute "ndb/MaxDiskWriteSpeedOwnRestart",
:description => "MaxDiskWriteSpeedOwnRestart",
:type => 'string'
attribute "ndb/MinDiskWriteSpeed",
:description => "MinDiskWriteSpeed",
:type => 'string'
attribute "ndb/DiskSyncSize",
:description => "DiskSyncSize",
:type => 'string'
attribute "ndb/RedoBuffer",
:description => "RedoBuffer",
:type => 'string'
attribute "ndb/LongMessageBuffer",
:description => "LongMessageBuffer",
:type => 'string'
attribute "ndb/TransactionInactiveTimeout",
:description => "TransactionInactiveTimeout",
:type => 'string'
attribute "ndb/TransactionDeadlockDetectionTimeout",
:description => "TransactionDeadlockDetectionTimeout",
:type => 'string'
attribute "ndb/LockPagesInMainMemory",
:description => "LockPagesInMainMemory",
:type => 'string'
attribute "ndb/RealTimeScheduler",
:description => "RealTimeScheduler",
:type => 'string'
attribute "ndb/SchedulerSpinTimer",
:description => "SchedulerSpinTimer",
:type => 'string'
attribute "ndb/BuildIndexThreads",
:description => "BuildIndexThreads",
:type => 'string'
attribute "ndb/CompressedLCP",
:description => "CompressedLCP",
:type => 'string'
attribute "ndb/CompressedBackup",
:description => "CompressedBackup",
:type => 'string'
attribute "ndb/BackupMaxWriteSize",
:description => "BackupMaxWriteSize",
:type => 'string'
attribute "ndb/BackupLogBufferSize",
:description => "BackupLogBufferSize",
:type => 'string'
attribute "ndb/BackupDataBufferSize",
:description => "BackupDataBufferSize",
:type => 'string'
attribute "ndb/MaxAllocate",
:description => "MaxAllocate",
:type => 'string'
attribute "ndb/DefaultHashMapSize",
:description => "DefaultHashMapSize",
:type => 'string'
attribute "ndb/ODirect",
:description => "ODirect",
:type => 'string'
attribute "ndb/TotalSendBufferMemory",
:description => "TotalSendBufferMemory in MBs",
:type => 'string'
attribute "ndb/OverloadLimit",
:description => "Overload for Send/Recv TCP Buffers in MBs",
:type => 'string'
attribute "kagent/enabled",
:description => "Install kagent",
:type => 'string',
:required => "optional"
attribute "ndb/NoOfFragmentLogParts",
:description => "One per ldm thread. Valid values: 4, 8, 16. Should match the number of CPUs in ThreadConfig's ldm threads.",
:type => 'string'
attribute "ndb/bind_cpus",
:description => "Isolate interrupts from cpus, turn off balance_irqs",
:type => 'string'
attribute "ndb/TcpBind_INADDR_ANY",
:description => "Set to TRUE so that any IP addr can be used on any node. Default is FALSE.",
:type => 'string'
attribute "ndb/aws_enhanced_networking",
:description => "Set to true if you want the ixgbevf module to be installed that is needed for AWS enhanced networking.",
:type => 'string'
attribute "ndb/interrupts_isolated_to_single_cpu",
:description => "Set to true if you want to setup your linux kernal to handle interrupts on a single CPU.",
:type => 'string'
attribute "ndb/ThreadConfig",
:description => "Decide which threads bind to which cores: Threadconfig=main={cpubind=0},ldm={count=8,cpubind=1,2,3,4,13,14,15,16},io={count=4,cpubind=5,6,17,18},rep={cpubind=7},recv={count=2,cpubind=8,19}k",
:type => 'string'
attribute "ndb/dir",
:description => "Directory in which to install mysql-cluster",
:type => 'string'
attribute "ndb/cron_backup",
:description => "Default is 'false'. To turn on, set to 'true'",
:type => 'string'
attribute "ndb/backup_frequency",
:description => "Options are 'daily', 'weekly'. Default is 'daily'",
:type => 'string'
attribute "ndb/backup_time",
:description => "Time in 24-hour clock of when to make the regular backup. Default: 03:00 (in the morning)",
:type => 'string'
attribute "ndb/systemd",
:description => "Use systemd scripts (instead of system-v). Default is 'true'.",
:type => 'string'
attribute "ndb/MaxNoOfConcurrentTransactions",
:description => "Maximum number of concurrent transactions (higher consumes more memory)",
:type => 'string'
attribute "ndb/mgmd/private_ips",
:description => "Ips for ndb_mgmds",
:type => 'array'
attribute "ndb/mysqld/private_ips",
:description => "Ips for mysql servers",
:type => 'array'
attribute "ndb/ndbd/private_ips",
:description => "Ips for ndb data nodes",
:type => 'array'
attribute "install/dir",
:description => "Set to a base directory under which we will install.",
:type => "string"
attribute "install/user",
:description => "User to install the services as",
:type => "string"
attribute "services/enabled",
:description => "Default 'false'. Set to 'true' to enable daemon services, so that they are started on a host restart.",
:type => "string"
# attribute "btsync/ndb/seeder_secret",
# :display_name => "Ndb seeder's random secret key.",
# :description => "20 chars or more (normally 32 chars)",
# :type => 'string',
# :default => "AY27AAZKTKO3GONE6PBCZZRA6MKGRKBX2"
# attribute "btsync/ndb/leecher_secret",
# :display_name => "Ndb leecher's secret key.",
# :description => "Ndb's random secret (key) generated using the seeder's secret key. 20 chars or more (normally 32 chars)",
# :type => 'string',
# :default => "BTHKJKK4PIPIOJZ7GITF2SJ2IYDLSSJVY"