[pkg-bacula-commits] [SCM] Bacula, a network backup, recovery and verification program branch, master, updated. debian/5.0.3-1-171-gad1ad44

Alexander Golovko alexandro at ankalagon.ru
Wed Jun 6 16:42:57 UTC 2012


The following commit has been merged in the master branch:
commit ad1ad44637bd53cd56bd3a79521db07ece18ac78
Author: Alexander Golovko <alexandro at ankalagon.ru>
Date:   Wed Jun 6 20:25:01 2012 +0400

    stop old bacula-director before db upgrade, not after

diff --git a/debian/bacula-director-mysql.postinst b/debian/bacula-director-mysql.postinst
index 00e680c..b7ea9be 100644
--- a/debian/bacula-director-mysql.postinst
+++ b/debian/bacula-director-mysql.postinst
@@ -29,6 +29,10 @@ dbc_first_version=1.38.9-3
 # set in config, must not be set here: dbc_dbuser=bacula
 # set in config, must not be set here: dbc_dbname=bacula
 
+if test "$1" = "configure" -a -n "$2" && dpkg --compare-versions "$2" lt "5.2.6+dfsg-1"; then
+  invoke-rc.d bacula-director stop || true
+fi
+
 # source dbconfig-common shell library, and call the hook function
 if [ -f /usr/share/dbconfig-common/dpkg/config.mysql ]; then
   . /usr/share/dbconfig-common/dpkg/postinst.mysql
@@ -47,11 +51,6 @@ setup_etc_default bacula-director-mysql $@
 
 case "$1" in
 configure)
-
-  if test -n "$2" && dpkg --compare-versions "$2" lt "5.2.6+dfsg-1"; then
-    invoke-rc.d bacula-director stop || true
-  fi
-
 	echo -n "Processing configuration..."
         . /etc/dbconfig-common/bacula-director-mysql.conf
 	TARGET=$CFGFILE.dpkg-tmp
diff --git a/debian/bacula-director-pgsql.postinst b/debian/bacula-director-pgsql.postinst
index a328850..2357063 100644
--- a/debian/bacula-director-pgsql.postinst
+++ b/debian/bacula-director-pgsql.postinst
@@ -29,6 +29,10 @@ dbc_first_version=1.38.9-2
 # set in config, must not be set here: dbc_dbuser=bacula
 # set in config, must not be set here: dbc_dbname=bacula
 
+if test "$1" = "configure" -a -n "$2" && dpkg --compare-versions "$2" lt "5.2.6+dfsg-1"; then
+  invoke-rc.d bacula-director stop || true
+fi
+
 # source dbconfig-common shell library, and call the hook function
 if [ -f /usr/share/dbconfig-common/dpkg/postinst.pgsql ]; then
   . /usr/share/dbconfig-common/dpkg/postinst.pgsql
@@ -53,11 +57,6 @@ setup_etc_default bacula-director-pgsql $@
 
 case "$1" in
 configure)
-
-  if test -n "$2" && dpkg --compare-versions "$2" lt "5.2.6+dfsg-1"; then
-    invoke-rc.d bacula-director stop || true
-  fi
-	
 	echo -n "Processing configuration..."
         . /etc/dbconfig-common/bacula-director-pgsql.conf
 	TARGET=$CFGFILE.dpkg-tmp
diff --git a/debian/bacula-director-sqlite3.postinst b/debian/bacula-director-sqlite3.postinst
index b7b6063..5b482fd 100644
--- a/debian/bacula-director-sqlite3.postinst
+++ b/debian/bacula-director-sqlite3.postinst
@@ -31,6 +31,9 @@ dbc_dbfile_owner=bacula:bacula
 # set in config, must not be set here: dbc_dbname=bacula.db
 # set in config, must not be set here: dbc_basepath=/var/lib/bacula
 
+if test "$1" = "configure" -a -n "$2" && dpkg --compare-versions "$2" lt "5.2.6+dfsg-1"; then
+  invoke-rc.d bacula-director stop || true
+fi
 
 # source dbconfig-common shell library, and call the hook function
 if [ -f /usr/share/dbconfig-common/dpkg/config.sqlite3 ]; then
@@ -49,11 +52,6 @@ setup_etc_default bacula-director-sqlite3 $@
 
 case "$1" in
 configure)
-
-  if test -n "$2" && dpkg --compare-versions "$2" lt "5.2.6+dfsg-1"; then
-    invoke-rc.d bacula-director stop || true
-  fi
-
 	echo -n "Processing configuration..."
         . /etc/dbconfig-common/bacula-director-sqlite3.conf
 	TARGET=$CFGFILE.dpkg-tmp

-- 
Bacula, a network backup, recovery and verification program



More information about the pkg-bacula-commits mailing list