michealzh / mysql-master-ha

Automatically exported from code.google.com/p/mysql-master-ha
0 stars 0 forks source link

upgrade to 0.54 problem #45

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Hi,
MHA worked fine on my two servers (debian) in 0.53. After upgrade the package 
in 0.54, i have a problem when i start the manager

masterha_manager --conf=/etc/masterha/app1.cnf

-------
Wed Dec 12 14:56:57 2012 - [warning] Global configuration file 
/etc/masterha_default.cnf not found. Skipping.
Wed Dec 12 14:56:57 2012 - [info] Reading application default configurations 
from /etc/masterha/app1.cnf..
Wed Dec 12 14:56:57 2012 - [error][/usr/share/perl5/MHA/MasterMonitor.pm, 
ln386] Error happend on checking configurations. Undefined subroutine 
&MHA::NodeUtil::escape_for_shell called at /usr/share/perl5/MHA/Config.pm line 
285.
Wed Dec 12 14:56:57 2012 - [error][/usr/share/perl5/MHA/MasterMonitor.pm, 
ln482] Error happened on monitoring servers.
Wed Dec 12 14:56:57 2012 - [info] Got exit code 1 (Not master dead).
----------

this is my app1.cnf

----------
 [server default]
  # mysql user and password
  user=root
  password=rootpass
  ssh_user=mysql
  # working directory on the manager
  manager_workdir=/var/log/masterha/app1
  manager_log=/var/log/masterha/app1/app1.log
  # working directory on MySQL servers
  remote_workdir=/var/log/masterha/app1
  master_binlog_dir=/data/mysql/log_binaire
  ping_interval=5

  master_ip_failover_script=/home/mysql/master_ip_failover

  [server1]
  hostname=10.0.0.1

  [server2]
  hostname=10.0.0.2

----------

if i test the ssh with: masterha_check_ssh --conf=/etc/masterha/app1.cnf

i have this issue Wed Dec 12 14:59:42 2012 - [warning] Global configuration 
file /etc/masterha_default.cnf not found. Skipping.
Wed Dec 12 14:59:42 2012 - [info] Reading application default configurations 
from /etc/masterha/app1.cnf..
Undefined subroutine &MHA::NodeUtil::escape_for_shell called at 
/usr/share/perl5/MHA/Config.pm line 285.

thanks for your help

Sebastien

Original issue reported on code.google.com by slefevr...@gmail.com on 12 Dec 2012 at 2:01

GoogleCodeExporter commented 8 years ago
Did you upgrade mha4mysql-node deb package to 0.54 as well as mha4mysql-manager?

Original comment by Yoshinor...@gmail.com on 12 Dec 2012 at 3:12

GoogleCodeExporter commented 8 years ago
yes

dpkg -l | grep mha

ii  mha4mysql-manager                   0.54-0                       Master 
High Availability Manager and Tools for MySQL, Manager Package
ii  mha4mysql-node                      0.54-0                       Master 
High Availability Manager and Tools for MySQL, Node Package

Original comment by slefevr...@gmail.com on 12 Dec 2012 at 3:39

GoogleCodeExporter commented 8 years ago
This is strange. Your error message happens if MHA Node package or NodeUtil.pm 
is not updated to 0.54 so I think MHA Manager refers older NodeUtil.pm. Would 
you please do below and let me know?

- Check all NodeUtil.pm file on your server (i.e. updatedb; locate NodeUtil.pm)
- Get md5sum. In 0.54 NodeUtil.pm md5 checksum should be as below.
$ md5sum /usr/share/perl5/MHA/NodeUtil.pm
65a0094af5176d9dcd8a44028ec14bb1
- Open NodeUtil.pm and check there is a "escape_for_shell" function

Original comment by Yoshinor...@gmail.com on 12 Dec 2012 at 4:04

GoogleCodeExporter commented 8 years ago
Yeah!! you fixed my problem 

i have another install  in /usr/local/share/perl/5.10.1/MHA. 
after remove it, it's ok with 0.54 version.

thanks a lot

Original comment by slefevr...@gmail.com on 12 Dec 2012 at 4:37

GoogleCodeExporter commented 8 years ago

Original comment by Yoshinor...@gmail.com on 12 Dec 2012 at 8:39