From: Marco van Wieringen Date: Wed, 4 May 2011 19:13:40 +0000 (+0200) Subject: Don't force job duplicate checking on copy and migration jobs. X-Git-Tag: Release-7.0.0~932 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=4ef5c93bf8dc429d479e23c7ddcee8b5e1ddf1ae;p=bacula%2Fbacula Don't force job duplicate checking on copy and migration jobs. --- diff --git a/bacula/src/dird/job.c b/bacula/src/dird/job.c index d428bd064b..b3bee866cc 100644 --- a/bacula/src/dird/job.c +++ b/bacula/src/dird/job.c @@ -697,7 +697,7 @@ bool allow_duplicate_job(JCR *jcr) JOB *job = jcr->job; JCR *djcr; /* possible duplicate job */ - if (job->AllowDuplicateJobs) { + if (jcr->no_check_duplicates || job->AllowDuplicateJobs) { return true; } Dmsg0(800, "Enter allow_duplicate_job\n"); diff --git a/bacula/src/dird/migrate.c b/bacula/src/dird/migrate.c index 2ee0e0d15b..f39fd1b15a 100644 --- a/bacula/src/dird/migrate.c +++ b/bacula/src/dird/migrate.c @@ -213,6 +213,9 @@ bool do_migration_init(JCR *jcr) /* Don't let WatchDog checks Max*Time value on this Job */ mig_jcr->no_maxtime = true; + /* Don't check for duplicates on migration and copy jobs */ + mig_jcr->no_check_duplicates = true; + Dmsg4(dbglevel, "mig_jcr: Name=%s JobId=%d Type=%c Level=%c\n", mig_jcr->jr.Name, (int)mig_jcr->jr.JobId, mig_jcr->jr.JobType, mig_jcr->jr.JobLevel); diff --git a/bacula/src/jcr.h b/bacula/src/jcr.h index 0bdf0a389b..f29d6fd172 100644 --- a/bacula/src/jcr.h +++ b/bacula/src/jcr.h @@ -355,6 +355,7 @@ public: bool Encrypt; /* Encryption used by FD */ bool stats_enabled; /* Keep all job records in a table for long term statistics */ bool no_maxtime; /* Don't check Max*Time for this JCR */ + bool no_check_duplicates; /* Don't check duplicates for this JCR */ bool keep_sd_auth_key; /* Clear or not the SD auth key after connection*/ bool use_accurate_chksum; /* Use or not checksum option in accurate code */ bool run_pool_override;