44 lines
1.8 KiB
Plaintext
44 lines
1.8 KiB
Plaintext
puppet-mmm
|
|
|
|
This is the puppet-mmm module.
|
|
|
|
Usage:
|
|
|
|
recommend creating a services/manifests/s_mmmcommon.pp
|
|
|
|
define services::s_mmmcommon {
|
|
mmm::cluster::config { "mmm cluster config ${name}":
|
|
ensure => 'present',
|
|
cluster_interface => 'eth0:2',
|
|
replication_user => 'replication',
|
|
replication_password => 'xxxxxxxxx',
|
|
agent_user => 'mmm_agent',
|
|
agent_password => 'xxxxxxxxxxxxxxxxxx',
|
|
monitor_user =>' mmm_monitor',
|
|
monitor_password => 'xxxxxxxxxxxxxxxxxx',
|
|
monitor_ip => '192.168.159.58',
|
|
masters => [ [ 'tx-db01', '192.168.155.134', 'tx-db02' ], ['tx-db02', '192.168.129.88', 'tx-db01'] ],
|
|
slaves => [ [ 'tx-dbslave-01', '192.168.129.9'], [ 'tx-dbslave-02', '192.168.181.160' ] ],
|
|
readers => ['tx-db01', 'tx-db02', 'tx-dbslave-01', 'tx-dbslave-02' ],
|
|
writer_virtual_ip => '192.168.135.56',
|
|
reader_virtual_ips => ['192.168.135.151','192.168.169.32','192.168.182.102'],
|
|
localsubnet => '192.168.%',
|
|
reader_user => 'webapp',
|
|
reader_pass => 'xxxxxxxxxxxxxxxxxx',
|
|
writer_user => 'webapp_write',
|
|
writer_pass => 'xxxxxxxxxxxxxxxxxx',
|
|
mmm_type => $name
|
|
}
|
|
}
|
|
|
|
|
|
Ensure your replicaiton_password is less than 32 characters: http://bugs.mysql.com/bug.php?id=43439
|
|
|
|
Your dbserver node/class will contain:
|
|
|
|
services::s_mmmcommon{ 'agent': }
|
|
|
|
And the monitor node/class will contain:
|
|
|
|
services::s_mmmcommon { 'monitor': }
|