PDA

View Full Version : SUSE manager DB backup failing



julianrogan
14-Nov-2019, 16:41
I have a prod and dev susemager. On the dev backup is working. On the prod when I run the command:

mdba backup-hot --enable=on --backup-dir=/var/spacewalk/db-backup
Backend error:
You've specified "/var/spacewalk/db-backup" as a destination,
but your backup is already in "/var/spacewalk/db_backup" directory.
In order to specify a new target directory,
you must purge (or disable) current backup.

smdba backup-status
Backup status: ON
Destination: /var/spacewalk/db_backup
Last transaction: Wed Oct 30 03:04:40 2019
Space available: 95%


ls -l /var/spacewalk/db_backup
total 2153168
-rw-r--r-- 1 postgres postgres 2204841389 Oct 30 03:04 base.tar.gz
drwx------ 2 postgres postgres 6 Oct 30 03:04 tmp

On the dev SUSE Manager I have run several backups with the same command.

The man page say run smdba backup-purge but that option is not valid in the current version

smdba
SUSE Manager Database Control. Version 1.6.4
Copyright (c) 2012-2019 by SUSE Linux LLC

Available commands:
backup-hot Enable continuous archiving backup
backup-restore Restore the SUSE Manager Database from backup.
backup-status Show backup status.
db-start Start the SUSE Manager Database.
db-status Show database status.
db-stop Stop the SUSE Manager Database.
space-overview Show database space report.
space-reclaim Free disk space from unused object in tables and indexes.
space-tables Show space report for each table.
system-check Common backend healthcheck.

To know a complete description of each command, use parameter 'help'.
Usage:
smdba <command> help <ENTER>

Andy advice?

julianrogan
16-Nov-2019, 12:27
after all that it was a simple typo. /var/spacewalk/db_backup --- the underscore should have been a dash in the directory name