Bacula-users

Re: [Bacula-users] drop_mysql_tables

2009-04-15 04:37:03
Subject: Re: [Bacula-users] drop_mysql_tables
From: Arno Lehmann <al AT its-lehmann DOT de>
To: Bacula Users <bacula-users AT lists.sourceforge DOT net>
Date: Wed, 15 Apr 2009 10:30:54 +0200
Hi,

15.04.2009 09:52, Maria McKinley wrote:
> Out of curiosity, can anyone tell me why this script got rid of all of 
> the volumes, but not the old jobs?

That's probably because you refer to the list of jobs shown at the end 
of the 'status' output - that's not taken from the catalog, but from 
the .state files which each daemon manages independently.

If you want to get rid of them, shut down the daemon and delete the 
corresponding .state file in the working directory.

Arno

> (When I ran it I got the succeeded 
> comment.) I also tried just deleting the jobs from bconsole, but they 
> didn't seem to go away then either.
> 
> thanks,
> maria
> 
> #!/bin/sh
> #
> # shell script to delete Bacula tables for MySQL
> 
> bindir=@SQL_BINDIR@
> 
> if $bindir/mysql $* <<END-OF-DATA
> USE bacula;
> DROP TABLE IF EXISTS Filename;
> DROP TABLE IF EXISTS Path;
> DROP TABLE IF EXISTS LongName;
> DROP TABLE IF EXISTS Device;
> DROP TABLE IF EXISTS Storage;
> DROP TABLE IF EXISTS MediaType;
> DROP TABLE IF EXISTS File;
> DROP TABLE IF EXISTS Client;
> DROP TABLE IF EXISTS Job;
> DROP TABLE IF EXISTS Media;
> DROP TABLE IF EXISTS JobMedia;
> DROP TABLE IF EXISTS Pool;
> DROP TABLE IF EXISTS MultiVolume;
> DROP TABLE IF EXISTS FileSave;        
> DROP TABLE IF EXISTS FileSet; 
> DROP TABLE IF EXISTS Version;
> DROP TABLE IF EXISTS Counters;
> DROP TABLE IF EXISTS BaseFiles;
> DROP TABLE IF EXISTS UnsavedFiles;
> DROP TABLE IF EXISTS CDImages;
> DROP TABLE IF EXISTS Status;
> DROP TABLE IF EXISTS MAC;
> DROP TABLE IF EXISTS Log;
> DROP TABLE IF EXISTS Location;
> DROP TABLE IF EXISTS LocationLog;
> END-OF-DATA
> then
>     echo "Deletion of Bacula MySQL tables succeeded."
> else
>     echo "Deletion of Bacula MySQL tables failed."
> fi
> exit 0
> 
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by:
> High Quality Requirements in a Collaborative Environment.
> Download a free trial of Rational Requirements Composer Now!
> http://p.sf.net/sfu/www-ibm-com
> _______________________________________________
> Bacula-users mailing list
> Bacula-users AT lists.sourceforge DOT net
> https://lists.sourceforge.net/lists/listinfo/bacula-users
> 

-- 
Arno Lehmann
IT-Service Lehmann
Sandstr. 6, 49080 Osnabrück
www.its-lehmann.de

------------------------------------------------------------------------------
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users

<Prev in Thread] Current Thread [Next in Thread>