]> git.sur5r.net Git - bacula/bacula/commitdiff
kes Apply Richard Mortimer's patches for printing an error
authorKern Sibbald <kern@sibbald.com>
Wed, 13 Sep 2006 19:15:15 +0000 (19:15 +0000)
committerKern Sibbald <kern@sibbald.com>
Wed, 13 Sep 2006 19:15:15 +0000 (19:15 +0000)
     message in btape when a DVD is used, and to initialize traceback.

git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@3465 91ce42f0-d328-0410-95d8-f526ca767f89

bacula/src/dird/protos.h
bacula/src/dird/ua_update.c
bacula/src/stored/bcopy.c
bacula/src/stored/bextract.c
bacula/src/stored/bls.c
bacula/src/stored/bscan.c
bacula/src/stored/btape.c
bacula/src/stored/reserve.c
bacula/src/version.h
bacula/technotes-1.39

index f25fac5c789032c3c3b37fd98e9a265ac9b48b96..9645cb99d31a57826d0be68ae53f514bd19e4704 100644 (file)
@@ -176,6 +176,7 @@ void parse_ua_args(UAContext *ua);
 /* ua_label.c */
 bool is_volume_name_legal(UAContext *ua, const char *name);
 int get_num_drives_from_SD(UAContext *ua);
+void update_slots(UAContext *ua);
 
 /* ua_output.c */
 void prtit(void *ctx, const char *msg);
index 2eaf0617e7747a8972e477433b7816c4602b8da3..29487ca3942ea008d9c007d6cd9cc5f9f8536918 100644 (file)
 #include "bacula.h"
 #include "dird.h"
 
-/* Imported functions */
-void update_slots(UAContext *ua);
-
-
-
 /* Forward referenced functions */
 static int update_volume(UAContext *ua);
 static bool update_pool(UAContext *ua);
index 930003ebd77a8287bfedaf5fbb5fd604b4b4f8c4..a086360c88d2014f28a0056a60467003a75d3463 100644 (file)
@@ -80,6 +80,7 @@ int main (int argc, char *argv[])
    setlocale(LC_ALL, "");
    bindtextdomain("bacula", LOCALEDIR);
    textdomain("bacula");
+   init_stack_dump();
 
    my_name_is(argc, argv, "bcopy");
    init_msg(NULL, NULL);
index 9c7c0de1b7cd2b3a043e30eca5a879881c38f034..9b6c1213b21be3c466951c0a5dc40f7a6c5a5a2f 100644 (file)
@@ -87,6 +87,7 @@ int main (int argc, char *argv[])
    setlocale(LC_ALL, "");
    bindtextdomain("bacula", LOCALEDIR);
    textdomain("bacula");
+   init_stack_dump();
 
    working_directory = "/tmp";
    my_name_is(argc, argv, "bextract");
index bdc20604dc7fd9d125f7500a173f86eb8f6e9e72..3a75cae22b1205dae59aaff9ed988df2dded020d 100644 (file)
@@ -91,6 +91,7 @@ int main (int argc, char *argv[])
    setlocale(LC_ALL, "");
    bindtextdomain("bacula", LOCALEDIR);
    textdomain("bacula");
+   init_stack_dump();
 
    working_directory = "/tmp";
    my_name_is(argc, argv, "bls");
index 85e6c1589999237efd678bbab5034835730c3256..1a71b1825e8d84651f6368baa33a5e222817a732 100644 (file)
@@ -129,6 +129,7 @@ int main (int argc, char *argv[])
    setlocale(LC_ALL, "");
    bindtextdomain("bacula", LOCALEDIR);
    textdomain("bacula");
+   init_stack_dump();
 
    my_name_is(argc, argv, "bscan");
    init_msg(NULL, NULL);
index 10b64c4377af7c6523fee5d45ce4bcc21902923d..43c00d64d9f991734b9379bfa392b5b73c6cb026 100644 (file)
@@ -152,6 +152,7 @@ int main(int margc, char *margv[])
    setlocale(LC_ALL, "");
    bindtextdomain("bacula", LOCALEDIR);
    textdomain("bacula");
+   init_stack_dump();
 
    /* Sanity checks */
    if (TAPE_BSIZE % B_DEV_BSIZE != 0 || TAPE_BSIZE / B_DEV_BSIZE == 0) {
@@ -269,6 +270,16 @@ int main(int margc, char *margv[])
    if (!dev) {
       exit(1);
    }
+   if (dev->is_dvd()) {
+      Pmsg0(000, _("btape does not work with DVD storage.\n"));
+      usage();
+      exit(1);
+   }
+   if (!dev->is_tape()) {
+      Pmsg0(000, _("btape only works with tape storage.\n"));
+      usage();
+      exit(1);
+   }
    dcr = jcr->dcr;
    if (!open_the_device()) {
       goto terminate;
index 250bd4f7c9e68d401d970ed906bb7671dfe5a51e..a7763839bf1a6bf084c6218d80821635e9b15a35 100644 (file)
@@ -911,7 +911,7 @@ static int can_reserve_drive(DCR *dcr, RCTX &rctx)
 
       /* Check for prefer mounted volumes */
       if (rctx.PreferMountedVols && !dev->VolHdr.VolumeName[0] && dev->is_tape()) {
-         Mmsg(jcr->errmsg, _("3606 JobId=%u wants mounted, but drive %s has no Volume.\n"), 
+         Mmsg(jcr->errmsg, _("3606 JobId=%u prefers mounted drives, but drive %s has no Volume.\n"), 
             jcr->JobId, dev->print_name());
          queue_reserve_message(jcr);
          Dmsg1(110, "failed: want mounted -- no vol JobId=%u\n", jcr->JobId);
@@ -1000,7 +1000,7 @@ static int can_reserve_drive(DCR *dcr, RCTX &rctx)
          return 1;
       } else {
          /* Drive Pool not suitable for us */
-         Mmsg(jcr->errmsg, _("3609 JobId=%u wants Pool=\"%s\" but have Pool=\"%s\" on drive %s.\n"), 
+         Mmsg(jcr->errmsg, _("3609 JobId=%u wants Pool=\"%s\" but has Pool=\"%s\" on drive %s.\n"), 
                jcr->JobId, dcr->pool_name, dev->pool_name, dev->print_name());
          queue_reserve_message(jcr);
          Dmsg2(110, "failed: busy num_writers>0, can_append, pool=%s wanted=%s\n",
index b2b8a8ebc873ec82f128f249671b8ef1a407a911..fadd83a787980eb971c10d950534fba7dea7adcc 100644 (file)
@@ -4,8 +4,8 @@
 
 #undef  VERSION
 #define VERSION "1.39.23"
-#define BDATE   "12 September 2006"
-#define LSMDATE "12Sep06"
+#define BDATE   "13 September 2006"
+#define LSMDATE "13Sep06"
 #define BYEAR "2006"       /* year for copyright messages in progs */
 
 /* Debug flags */
index 95499379b424bc3212532d7eaa6afbfbe2139a1b..28ed9852447f888e976bdc18f8ad67277fe86bb3 100644 (file)
@@ -1,6 +1,11 @@
               Technical notes on version 1.39  
 
 General:
+13Sep06
+kes  Apply Richard Mortimer's patches for printing an error 
+     message in btape when a DVD is used, and to initialize traceback.
+kes  Added error message to btape when trying to access a file.
+kes  Move prototype of update_slots() to protos.h.
 12Sep06
 kes  Add JobErrors, JobFiles, SDJobFiles, SDJobErrors, SDJobStatus,
      and FDJobStatus to the Director Python variables.