PDA

View Full Version : ZRM Failed-Cant use locks with log files?



BigBirdy
June 4th, 2009, 08:58 AM
Trying to get zrm running on a RHEL 5.x x64 machine. First attempts run a local backup of all db's gives me an error that "You can't use locks with log tables. at /usr/bin/mysqlhotcopy line 452."

Is there any way around this?

Full Output:

[root@akitas Downloads]# mysql-zrm-scheduler --now --backup-set akitas-daily
schedule:INFO: ZRM for MySQL Community Edition - version 2.1
Logging to /var/log/mysql-zrm/mysql-zrm-scheduler.log
backup:INFO: ZRM for MySQL Community Edition - version 2.1
akitas-daily:backup:INFO: START OF BACKUP
akitas-daily:backup:INFO: PHASE START: Initialization
akitas-daily:backup:INFO: backup-set=akitas-daily
akitas-daily:backup:INFO: backup-date=20090604095125
akitas-daily:backup:INFO: mysql-server-os=Linux/Unix
akitas-daily:backup:INFO: backup-type=regular
akitas-daily:backup:INFO: host=localhost
akitas-daily:backup:INFO: backup-date-epoch=1244134285
akitas-daily:backup:INFO: retention-policy=30D
akitas-daily:backup:INFO: mysql-zrm-version=ZRM for MySQL Community Edition - version 2.1
akitas-daily:backup:INFO: mysql-version=5.1.34-log
akitas-daily:backup:INFO: backup-directory=/mnt/Backups/akitas-daily/20090604095125
akitas-daily:backup:INFO: backup-level=0
akitas-daily:backup:INFO: backup-mode=raw
akitas-daily:backup:INFO: PHASE END: Initialization
akitas-daily:backup:INFO: PHASE START: Running pre backup plugin
akitas-daily:backup:INFO: PHASE END: Running pre backup plugin
akitas-daily:backup:INFO: PHASE START: Flushing logs
akitas-daily:backup:INFO: PHASE END: Flushing logs
akitas-daily:backup:INFO: PHASE START: Find table type
akitas-daily:backup:INFO: PHASE END: Find table type
akitas-daily:backup:INFO: PHASE START: Creating raw backup
akitas-daily:backup:ERROR: Output of command: 'mysqlhotcopy' is {
DBD::mysql::db do failed: You can't use locks with log tables. at /usr/bin/mysqlhotcopy line 452.
}
akitas-daily:backup:ERROR: mysqlhotcopy did not succeed. Command used is mysqlhotcopy --user="****" --password="*****" --quiet mysql phpchain "/mnt/Backups/akitas-daily/20090604095125" > /tmp/f8o0fIDgJR 2>&1 Return value is 65280
akitas-daily:backup:INFO: PHASE START: Cleanup
akitas-daily:backup:INFO: backup-status=Backup failed
akitas-daily:backup:INFO: Backup failed
akitas-daily:backup:INFO: PHASE END: Cleanup
akitas-daily:backup:INFO: END OF BACKUP
ERROR: /usr/bin/mysql-zrm did not finish successfully

paddy
June 4th, 2009, 09:11 AM
I guess you are using MySQL 5.1.

This is a known problem and a workaround is documented here
http://planet.mysql.com/entry/?id=17913

thanks,
Paddy

BigBirdy
June 8th, 2009, 08:53 AM
Excellent and thanks But where would I make the changes to address this issue? I changed the line in socket-server.pl and socket-copy.pl from

# my $MYSQLHOTCOPY="mysqlhotcopy";
my $MYSQLHOTCOPY="mysqlhotcopy mysql./~.+_log$/";

Bit this did not address the issue and I noticed mysqlhotcopy called elsewhere but without the variable above.

Any suggestions on where I can make the changes in the ZRM scripts to address this?

Thanks again :)

paddy
June 8th, 2009, 12:51 PM
Use the fixed version of mysqlhotcopy from http://bugs.mysql.com/bug.php?id=43594
instead of working around the issue in ZRM.

Paddy

BigBirdy
June 9th, 2009, 08:46 AM
Just to confirm, I am unable to locate a copy of "mysqlhotcopy" at that link, but there is a link to "mysqlhostcopy.bug43594". Is this what you mean?

paddy
June 9th, 2009, 08:55 AM
yes. apply the patch.

Paddy

BigBirdy
June 9th, 2009, 08:57 AM
Ok I will byte. Exactly how do I do that? A bit more detail would certainly lessen both of our back-forth-email on this. I have NOT installed from source, but from rpm's

paddy
June 9th, 2009, 09:21 AM
mysqlhotcopy is a script and patch to the script is attached. You can use "patch" command to apply the patch.

Paddy

BigBirdy
June 9th, 2009, 09:26 AM
I know you are trying to help. But your suggestions assume I am a developer and know how to patch a program. Simply stating, "run the patch program" obviously does not provide me with with any helpful information. It also continues to waste both of our time. I hope you can appreciate this and possibly send a suggestion, and steps, to actually accomplish this and we can both return to our other tasks.

Thanks again :)

paddy
June 9th, 2009, 11:56 AM
patch -p 1 < mysqlhostcopy.bug43594

should work. Please execute this command in /usr/bin directory (as root user) if mysqlhotcopy is installed in /usr/bin directory.

Paddy