2

I am trying to setup mysqlfailover utility on ec2 instance running Ubuntu 12.04. I performed the following steps:

Downloaded mysql-connector-python: wget http://cdn.mysql.com/Downloads/Connector-Python/mysql-connector-python_1.0.12-1debian6.0_all.deb -o mysql-connector-python_1.0.12-1debian6.0_all.deb

(Installed using dpkg -i command.)

Download mysql-utilities: wget http://cdn.mysql.com/Downloads/MySQLGUITools/mysql-utilities_1.3.5-1debian6.0_all.deb -o mysql-utilities_1.3.5-1debian6.0_all.deb

(Installed using dpkg -i command.)

There were some dependencies issues. I ran the following commands: sudo apt-get install python-pip easy_install -U distribute sudo apt-get install libmysqlclient-dev sudo apt-get install python-dev pip install mysql-python

Now, when I run the command mysqlfailover, it gives the following error:

Traceback (most recent call last):
  File "/usr/bin/mysqlfailover", line 24, in <module>
    from mysql.utilities.common.tools import check_python_version
ImportError: No module named mysql.utilities.common.tools

I have been banging my head around quite some time now, but no success. Any help in the matter is highly appreciated. Thanks.

KEINS
  • 71
  • 1
  • 6
  • Similar to but not related to http://stackoverflow.com/questions/31593772/cannot-run-anything-from-mysql-utilities-no-module-named-mysql-utilities-commo . In that question, the problems begin when I install 2.1 of the connector; while you have the problems in 1.0. – Otheus Jul 23 '15 at 17:10

2 Answers2

1

Try env PYTHONPATH=/usr/share/pyshared/ mysqlfailover

-1

Thers is no utilities in mysql modul, you can check this do:

ls /usr/lib/python2.7/dist-packages/mysql

So you should change mysql package:

cp -r /usr/share/pysharedmysql /usr/lib/python2.7/dist-packages/mysql
tobias_k
  • 81,265
  • 12
  • 120
  • 179
raolh
  • 1