Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MHA now installs - need to configure
- Loading branch information
1 parent
afe32de
commit dcff719
Showing
5 changed files
with
75 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
--- | ||
# install MHA manager software - it would appear MHA manager depends on | ||
# MHA node from a dpkg point of view, so I install everything everywhere | ||
- hosts: mhamanager:mhanodes | ||
user: ubuntu | ||
sudo: True | ||
vars_files: | ||
- ../PalominoClusterToolConfig.yml | ||
tasks: | ||
- name: install MHA dependencies on MHA manager | ||
action: apt name=$item state=installed | ||
with_items: | ||
- libdbd-mysql-perl | ||
- libconfig-tiny-perl | ||
- liblog-dispatch-perl | ||
- libparallel-forkmanager-perl | ||
|
||
- name: download MHA software | ||
action: command creates=/tmp/$item /usr/bin/curl http://mysql-master-ha.googlecode.com/files/$item -o /tmp/$item | ||
with_items: | ||
- mha4mysql-node_0.53_all.deb | ||
- mha4mysql-manager_0.53_all.deb | ||
|
||
- name: install MHA software | ||
action: command /usr/bin/dpkg -i /tmp/$item | ||
with_items: | ||
- mha4mysql-node_0.53_all.deb | ||
- mha4mysql-manager_0.53_all.deb | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
--- | ||
|
18 changes: 18 additions & 0 deletions
18
AnsiblePlaybooks/Ubuntu-12.04/MHA/templates/etc:mha:palominoMHAapp.cnf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
[server default] | ||
manager_workdir=/var/log/masterha/app | ||
manager_log=/var/log/masterha/app.log | ||
|
||
[server1] | ||
hostname=host1 | ||
candidate_master=1 | ||
|
||
[server2] | ||
hostname=host2 | ||
candidate_master=1 | ||
|
||
[server3] | ||
hostname=host3 | ||
|
||
[server4] | ||
hostname=host4 | ||
|
12 changes: 12 additions & 0 deletions
12
AnsiblePlaybooks/Ubuntu-12.04/MHA/templates/etc:mha:palominoMHAglobal.cnf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
[server default] | ||
user=root | ||
password=rootpass | ||
ssh_user=ubuntu | ||
master_binlog_dir=/var/log/mysql | ||
remote_workdir=/data/log/masterha | ||
secondary_check_script=masterha_secondary_check -s remote_host1 -s remote_host2 | ||
ping_interval=3 | ||
master_ip_failover_script=/script/masterha/master_ip_failover | ||
shutdown_script=/script/masterha/power_manager | ||
report_script=/script/masterha/send_master_failover_mail | ||
|