*/
Dmsg0(200, "Connect to write (wjcr) storage daemon.\n");
if (!connect_to_storage_daemon(wjcr, 10, SDConnectTimeout, 1)) {
+ Jmsg(jcr, M_FATAL, 0, _("Could not connect to write Storage Daemon: %s\n"), wjcr->store_mngr->get_wstore()->name());
goto bail_out;
}
wsd = wjcr->store_bsock;
*/
Dmsg1(200, "Connect to read (jcr) storage daemon. Jid=%d\n", jcr->JobId);
if (!connect_to_storage_daemon(jcr, 10, SDConnectTimeout, 1)) {
+ Jmsg(jcr, M_FATAL, 0, _("Could not connect to read Storage Daemon: %s\n"), jcr->store_mngr->get_rstore()->name());
goto bail_out;
}
sd = jcr->store_bsock;
*/
Dmsg1(200, "Start job with read (jcr) storage daemon. Jid=%d\n", jcr->JobId);
if (!start_storage_daemon_job(jcr, jcr->store_mngr->get_rstore_list(), NULL, true /* wait */, /*send_bsr*/true)) {
+ Jmsg(jcr, M_FATAL, 0, _("Could not start job on read Storage Daemon: %s\n"), jcr->store_mngr->get_rstore()->name());
goto bail_out;
}
Dmsg0(150, "Read storage daemon connection OK\n");
*/
Dmsg1(200, "Start Job with write (wjcr) storage daemon. Jid=%d\n", jcr->JobId);
if (!start_storage_daemon_job(wjcr, NULL, wjcr->store_mngr->get_wstore_list(), true /* wait */, /*no_send_bsr*/false)) {
+ Jmsg(jcr, M_FATAL, 0, _("Could not start job on write Storage Daemon: %s\n"), wjcr->store_mngr->get_wstore()->name());
goto bail_out;
}
Dmsg0(150, "Write storage daemon connection OK\n");
wjcr->store_mngr->reset_wstorage();
wjcr->file_bsock = NULL;
- if (ok) {
- mac_cleanup(jcr, jcr->JobStatus, wjcr->JobStatus);
- }
+ mac_cleanup(jcr, jcr->JobStatus, wjcr->JobStatus);
return ok;
}
STORE *store;
utime_t heart_beat;
STORE *wstore = jcr->store_mngr->get_wstore();
+ POOL_MEM buf;
if (is_bsock_open(sd)) {
return true; /* already connected */
}
if (!store) {
- Dmsg0(100, "No storage resource found in jcr!\n");
+ Dmsg1(100, "No storage resource found in jcr for JobId: %d!\n", jcr->JobId);
return false;
}
Dmsg2(100, "Connect to Storage daemon %s:%d\n", store->address,
store->SDport);
sd->set_source_address(director->DIRsrc_addr);
- if (!sd->connect(jcr, retry_interval, max_retry_time, heart_beat, _("Storage daemon"),
+ //TODO is translating needed/useful here?
+ Mmsg(buf, _("Storage Daemon: %s"), store->name());
+ if (!sd->connect(jcr, retry_interval, max_retry_time, heart_beat, buf.c_str(),
store->address, NULL, store->SDport, verbose)) {
if (!jcr->store_bsock) { /* The bsock was locally created, so we free it here */