PDA

View Full Version : abort-backup problem



cpeintre
March 31st, 2011, 07:43 AM
Hello,

I would like to use this command to abort a backup :

mysql-zrm --action abort-backup --backup-set alldatabases

But I have always the same error :

abort:INFO: ZRM for MySQL Community Edition - version 2.2.0
abort:INFO: Reading options from file /etc/mysql-zrm/mysql-zrm.conf
alldatabases:abort:INFO: Reading options from file /etc/mysql-zrm/alldatabases/mysql-zrm.conf
alldatabases:abort:ERROR: Unable to abort backup run for backup-set alldatabases

Does this abort option works ?
If yes, how does it works ?

Need help.
Thx
CÚdric

paddy
April 1st, 2011, 11:33 AM
Abort command uses the pid information from the file /etc/mysql-zrm/<backup set name/.mysql-zrm.pid

It appears that pid found in the file was not valid. Remove the pid before next backup run and try again.

Paddy

cpeintre
April 4th, 2011, 02:51 AM
Hello Paddy, thanks for your reply.
The pid file seems correct during the backup :

cat .mysql-zrm.pid
22927

ps -ef| grep 22927
root 22927 22916 0 11:49 pts/1 00:00:00 /usr/bin/perl /usr/bin/mysql-zrm --action backup --backup-set alldatabases
root 22928 22927 0 11:49 pts/1 00:00:00 /usr/bin/perl /usr/bin/mysql-zrm-backup --backup-set alldatabases
root 22964 22851 0 11:49 pts/0 00:00:00 grep 22927

But, I had the same error :

mysql-zrm --action abort-backup --backup-set alldatabases
abort:INFO: ZRM for MySQL Community Edition - version 2.2.0
alldatabases:abort:ERROR: Unable to abort backup run for backup-set alldatabases

Need help !
Thx
CÚdric

paddy
April 4th, 2011, 02:05 PM
The backups are running as root. Are you running abort backup as root user?

cpeintre
April 5th, 2011, 02:01 AM
Yes, I'm running the abort as root user

paddy
April 5th, 2011, 04:51 PM
abort backup command does kill -15 <pid>. The kill command did not succeed. Do you see any reason why this may not work. You can try the kill command during your backup run.

cpeintre
April 6th, 2011, 05:47 AM
Hello Paddy,

Thx for your help.
Yes the "kill -15" command runs without error.

So, after several tests, I found that the command "my $r = kill( -15, $x );" didn't work correctly.

I have just changed "-15" by "ABRT" and aborting backup runs now :
my $r = kill( "ABRT", $x );

In the file /usr/bin/mysql-zrm-abort-backup

Thx again, my issue is ok.
CÚdric

cpeintre
April 7th, 2011, 02:10 AM
But, in fact, aborting ZRM backup don't stop the mysqldump process !
So, with a mysqldump backup, this fonctionnality is useless :-(