2011-02-09 02:07 PM - edited 2015-12-18 12:47 AM
I'm trying to use snapcreator 3.3 with mysql. But this doesn't work.
I can confirm that this works:
mysql -h 127.0.0.1 -P 3306 -u root -p demo
I've attached the config file. Any ideas?
2011-02-11 12:30 AM
the snapcreator mysql plugin seems to use Net::MySQL, which is quite old (latest version 0.09 = March 2006)
I did some googling and I found this:
List of Net::MySQL Bugs: https://rt.cpan.org/Public/Dist/Display.html?Name=Net-MySQL
A bug description and a possible fix (not included in the latest version) for my problem:
2011-02-11 02:11 AM
What version of MySQL server and Client are you running? Also did you try installing the MySQL-devel package? Your SC config file looks good.
SC 3.3 supports following MySQL versions according to IMT http://now.netapp.com/matrix :
MySQL Enterprise Server 5.1.30
MySQL Enterprise Server 5.1.31
MySQL Enterprise Server 5.1.32
MySQL Enterprise Server 5.1.33
MySQL Enterprise Server 5.1.34
MySQL Enterprise Server 5.1.35
MySQL Enterprise Server 5.1.36
MySQL Enterprise Server 5.1.37
MySQL Enterprise Server 5.1.38
MySQL Enterprise Server 5.1.39
MySQL Enterprise Server 5.1.40
MySQL Enterprise Server 5.1.41
MySQL Enterprise Server 5.1.42
MySQL Enterprise Server 5.1.43
MySQL Enterprise Server 5.1.44
MySQL Enterprise Server 5.1.45
MySQL Enterprise Server 5.1.46
MySQL Enterprise Server 5.1.47
MySQL Enterprise Server 5.1.48
MySQL Enterprise Server 5.1.49
MySQL Enterprise Server 5.1.50
MySQL Enterprise Server 5.1.51
MySQL Enterprise Server 5.1.52
I think probably this is a compadibility issue between Net::MySQL and MySQL client libs. We will try and reproduce this issue and find a solution. The best thing you can do is if your config is supported open an NGS support case. This will force a BURT to be opened and the problem will be addressed much quicker.
2011-02-11 02:27 AM
A workaround solution to this problem is simply not use MYSQL plugin.
You can try using mysql command to send sql needed to quiesce/unquiesce MySQL
APP_QUIESCE_CMD01=mysql <arguments> <sql query=flush tables with read lock>
APP_QUIESCE_CMD02=mysql <arguments> <sql query=flush logs>
APP_UNQUIESCE_CMD01=mysql <arguments> <sql query=unlock tables>
PRE_EXIT_CMD01=mysql <arguments> <sql query=unlock tables>
flush tables with read lock
Let us know if this helps?
2011-02-11 08:15 AM
My bad. i didn't chek the compatibility matrix. I was testing with centos 5.5, which has only MySQL 5.0.77
I wanted to test with RHEL6 x86_64 but it's no listed in the compatibility list either.
2011-02-11 08:20 AM
SC will run on centOS and redhat6. There isn't NGS support for that but that doesnt prevent you from providing a solution. You can still use SC as basis to quickly get a scripting solution going. This saves time and provides the customer I think with a great solution.
If the MySQL plugin doesn't work (has issues with certain versions) the try using mysql cli in combo with APP_QUIESCE_CMDS and APP_UNQUIESCE_CMDS. If you want any further help getting that going then let us know. We are happy to help!
2011-02-11 08:21 AM
The workaround is working. In the config file, you have to modify the following line too:
APP_NAME=mysql => APP_NAME=
Actually one could write a small perl script wraper to quiesce/unquiesce the db. The needed infos are available as environment variables. I'll have a look at tthis
and try to make this work on rhel6 too.
2011-02-11 08:26 AM
Yep I forgot about APP_NAME. You have to turn that off, that basically turns off plugin and allows you to work with quiesce|unquiesce|pre_exit cmds.
If you figure this out please share your scripts and config file, this type of knowledge really helps everyone in the SC community.
2011-02-11 08:29 AM
Actually I tried on RHE6 x86_64 too. It is a minimal install, so some libraries are possibly missing.
I'll take a look after my holidays
I get this
2011-02-11 08:32 AM
One more thing. You mention perl, if you are interested you can create your own plugin (plugin framework is perl). There is a TR (below) which explains how to program a community plugin. This would take more time to create than wrapper scripts but if you plan on re-using your plugin and providing a unique solution (your own SnapManager using Snap Creator) you are welcome to do so.
In future releases we are looking at adding support so folks can write plugins in other languages (powershell, etc) and not just perl.