This helps get out of blocked conditions.
kes Experimental implementation of switch_device in reservations.
git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@6578
91ce42f0-d328-0410-95d8-
f526ca767f89
return false;
}
Dmsg1(100, "Someone woke me for device %s\n", dev->print_name());
+ break;
}
set_jcr_job_status(jcr, JS_Running);
dir_send_job_status(jcr);
}
Dmsg1(150, "Label type=%d\n", dev->label_type);
if (!dev->rewind(dcr)) {
- dev->clear_volhdr();
Dmsg2(130, "Bad status on %s from rewind: ERR=%s\n", dev->print_name(), dev->print_errmsg());
if (!forge_on) {
goto bail_out;
ASSERT(dev != NULL);
- dev->clear_volhdr(); /* release any old volume */
+ dev->clear_volhdr(); /* clear any old volume info */
bstrncpy(dev->VolHdr.Id, BaculaId, sizeof(dev->VolHdr.Id));
dev->VolHdr.VerNum = BaculaTapeVersion;
static bool use_storage_cmd(JCR *jcr);
static void queue_reserve_message(JCR *jcr);
static void pop_reserve_messages(JCR *jcr);
+void switch_device(DCR *dcr, DEVICE *dev);
/* Requests from the Director daemon */
static char use_storage[] = "use storage=%127s media_type=%127s "
/* Check if we are trying to use the Volume on a different drive */
if (dev != vol->dev) {
/* Caller wants to switch Volume to another device */
+ switch_device(dcr, vol->dev);
+ dev = vol->dev;
+#ifdef xxx
if (!vol->dev->is_busy()) {
/* OK to move it -- I'm not sure this will work */
Dmsg3(dbglvl, "==== Swap vol=%s from dev=%s to %s\n", VolumeName,
vol = NULL; /* device busy */
goto get_out;
}
+#endif
}
}
dev->vol = vol;
General:
10Mar08
+kes Make ask_sysop_to_create... to return if waken from wait.
+ This helps get out of blocked conditions.
+kes Experimental implementation of switch_device in reservations.
kes Implement FD version to allow easier protocol changes.
kes Add Plugin Options string -- not yet passed to FD.
kes Implement PluginOptions ACL.