From: Kern Sibbald Date: Wed, 1 Jun 2016 12:54:19 +0000 (+0200) Subject: In updatedb get recent update_xx_tables and remove old versions X-Git-Tag: Release-7.4.1~2 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=570fc0400e0b992f0d29ece416ab002f742a1399;p=bacula%2Fbacula In updatedb get recent update_xx_tables and remove old versions --- diff --git a/bacula/updatedb/update_mysql_tables.in b/bacula/updatedb/update_mysql_tables.in index 4ae0513679..08df0d88b3 100644 --- a/bacula/updatedb/update_mysql_tables.in +++ b/bacula/updatedb/update_mysql_tables.in @@ -143,7 +143,4 @@ END-OF-DATA fi fi - -END-OF-DATA - exit 0 diff --git a/bacula/updatedb/update_mysql_tables_12_to_13.in b/bacula/updatedb/update_mysql_tables_12_to_13.in deleted file mode 100644 index 2590e3d8b9..0000000000 --- a/bacula/updatedb/update_mysql_tables_12_to_13.in +++ /dev/null @@ -1,53 +0,0 @@ -#!/bin/sh -# -# Copyright (C) 2000-2015 Kern Sibbald -# License: BSD 2-Clause; see file LICENSE-FOSS -# -# Shell script to update MySQL -# -echo " " -echo "This script will update a Bacula MySQL database from version 12 to 13" -echo " which is needed to convert from Bacula" -echo " " -bindir=@MYSQL_BINDIR@ -PATH="$bindir:$PATH" -db_name=${db_name:-@db_name@} - -mysql $* -D ${db_name} -e "select VersionId from Version\G" >/tmp/$$ -DBVERSION=`sed -n -e 's/^VersionId: \(.*\)$/\1/p' /tmp/$$` -if [ $DBVERSION != 12 ] ; then - echo " " - echo "The existing database is version $DBVERSION !!" - echo "This script can only update an existing version 12 database to version 13." - echo "Error. Cannot upgrade this database." - echo " " - exit 1 -fi - -if mysql $* -f </tmp/$$ -DBVERSION=`sed -n -e 's/^VersionId: \(.*\)$/\1/p' /tmp/$$` -if [ $DBVERSION != 13 ] ; then - echo " " - echo "The existing database is version $DBVERSION !!" - echo "This script can only update an existing version 13 database to version 14." - echo "Error. Cannot upgrade this database." - echo " " - exit 1 -fi - -if mysql $* -f <