]> git.sur5r.net Git - bacula/bacula/commitdiff
Add message to migration job when the target job is already migrated.
authorKern Sibbald <kern@sibbald.com>
Mon, 4 Aug 2008 08:49:59 +0000 (08:49 +0000)
committerKern Sibbald <kern@sibbald.com>
Mon, 4 Aug 2008 08:49:59 +0000 (08:49 +0000)
     This closes bug #1129.

git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/branches/Branch-2.4@7462 91ce42f0-d328-0410-95d8-f526ca767f89

bacula/patches/2.4.2-mig-message.patch [new file with mode: 0644]
bacula/src/dird/migrate.c
bacula/src/version.h
bacula/technotes-2.4

diff --git a/bacula/patches/2.4.2-mig-message.patch b/bacula/patches/2.4.2-mig-message.patch
new file mode 100644 (file)
index 0000000..a9d2f67
--- /dev/null
@@ -0,0 +1,29 @@
+
+ This patch causes a message to be printed if the migration job finds that
+ the target job has already been migrated:
+
+    JobId %s already migrated probably by another Job. Migration stopped.
+
+  It can be applied to 2.4.2 (not to previous versions) with:
+
+  cd <bacula-source>
+  patch -p0 <2.4.2-mig-message.patch
+  ./configure <your-options>
+  make
+  ...
+  make install
+
+
+Index: src/dird/migrate.c
+===================================================================
+--- src/dird/migrate.c (revision 7444)
++++ src/dird/migrate.c (working copy)
+@@ -284,6 +284,8 @@
+    }
+    /* Make sure this job was not already migrated */
+    if (jcr->previous_jr.JobType != JT_BACKUP) {
++      Jmsg(jcr, M_INFO, 0, _("JobId %s already migrated probably by another Job. Migration stopped.\n"),
++         edit_int64(jcr->previous_jr.JobId, ed1));
+       set_jcr_job_status(jcr, JS_Terminated);
+       migration_cleanup(jcr, jcr->JobStatus);
+       return true;
index 11efb7d532ea25a42c218003ae4662398e7c2ee7..d36d63b7a69c3178ecffff89798ccd88ccd62815 100644 (file)
@@ -284,6 +284,8 @@ bool do_migration(JCR *jcr)
    }
    /* Make sure this job was not already migrated */
    if (jcr->previous_jr.JobType != JT_BACKUP) {
+      Jmsg(jcr, M_INFO, 0, _("JobId %s already migrated probably by another Job. Migration stopped.\n"),
+         edit_int64(jcr->previous_jr.JobId, ed1));
       set_jcr_job_status(jcr, JS_Terminated);
       migration_cleanup(jcr, jcr->JobStatus);
       return true;
index 3596458a01c7463cbd86b5eca8eac65c64bf7811..e90bb59fbef939bf639101064c8f04f0490f5acb 100644 (file)
@@ -3,9 +3,9 @@
  */
 
 #undef  VERSION
-#define VERSION "2.4.2"
-#define BDATE   "26 July 2008"
-#define LSMDATE "26Jul08"
+#define VERSION "2.4.3"
+#define BDATE   "08 August 2008"
+#define LSMDATE "08Aug08"
 
 #define PROG_COPYRIGHT "Copyright (C) %d-2008 Free Software Foundation Europe e.V.\n"
 #define BYEAR "2008"       /* year for copyright messages in progs */
index 6947c764333dd810b4c2d47f0ea26a474a7a0f8b..e37cd4f5bbb61a6fcbbdb3a11ca266291ce158b7 100644 (file)
@@ -1,6 +1,10 @@
               Technical notes on version 2.4
 
 General:
+08Aug08
+kes  Add message to migration job when the target job is already migrated.
+     This closes bug #1129.
+
 Release Version 2.4.2
 26Jul08
 kes  When a migration job actually runs, re-check the Job record