diff options
author | Don Brewer <dbrewer@dbrewer-host.usersys.redhat.com> | 2008-04-09 09:22:48 -0400 |
---|---|---|
committer | Brenton Leanhardt <bleanhar@redhat.com> | 2008-04-15 10:37:38 -0400 |
commit | 1bdc1f426185f05beb573eb7ca63d404d849d753 (patch) | |
tree | 175ae51b1d692b74b4d34a16a9545aa03be0e5e9 /templates/gather_master_data.bash.erb | |
parent | 28544868b29c412418436e9924f301ac210c6236 (diff) | |
download | puppet-mysql-1bdc1f426185f05beb573eb7ca63d404d849d753.tar.gz puppet-mysql-1bdc1f426185f05beb573eb7ca63d404d849d753.tar.xz puppet-mysql-1bdc1f426185f05beb573eb7ca63d404d849d753.zip |
added server_id and master_ip factors
Diffstat (limited to 'templates/gather_master_data.bash.erb')
-rw-r--r-- | templates/gather_master_data.bash.erb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/templates/gather_master_data.bash.erb b/templates/gather_master_data.bash.erb index c9d3804..53cf2cf 100644 --- a/templates/gather_master_data.bash.erb +++ b/templates/gather_master_data.bash.erb @@ -2,20 +2,20 @@ PATH=$PATH -logname=$(mysql -u replication --host=<%= master_host_ip %> --password=password --execute="show master status" | grep mysqllog | awk '{ print $1 }') +logname=$(mysql -u replication --host=<%= mysql_master_ip_address %> --password=password --execute="show master status" | grep mysqllog | awk '{ print $1 }') export logname -position=$(mysql -u replication --host=<%= master_host_ip %> --password=password --execute="show master status" | grep mysqllog | awk '{ print $2 }') +position=$(mysql -u replication --host=<%= mysql_master_ip_address %> --password=password --execute="show master status" | grep mysqllog | awk '{ print $2 }') export position rm /var/lib/mysql/set_master_repl_data.sql -export master_host_ip=<%= master_host_ip %> +export mysql_master_ip_address=<%= mysql_master_ip_address %> #Build MySQL Master Data Script # echo CHANGE MASTER TO >> /var/lib/mysql/set_master_repl_data.sql -echo MASTER_HOST=\'$master_host_ip\', >> /var/lib/mysql/set_master_repl_data.sql +echo MASTER_HOST=\'$mysql_master_ip_address\', >> /var/lib/mysql/set_master_repl_data.sql echo MASTER_USER=\'replication\', >> /var/lib/mysql/set_master_repl_data.sql echo MASTER_PASSWORD=\'password\', >> /var/lib/mysql/set_master_repl_data.sql echo MASTER_LOG_FILE=\'$logname\', >> /var/lib/mysql/set_master_repl_data.sql |