From: Kern Sibbald Date: Sat, 24 Jan 2004 16:19:05 +0000 (+0000) Subject: various see kes-1.33 X-Git-Tag: Release-7.0.0~9729 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=7b096a4643aa8f4e088ff698168f3a309d33123d;p=bacula%2Fbacula various see kes-1.33 git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@1018 91ce42f0-d328-0410-95d8-f526ca767f89 --- diff --git a/bacula/platforms/redhat/bacula.spec.in b/bacula/platforms/redhat/bacula.spec.in index 75c47ba49b..8160b3f5be 100644 --- a/bacula/platforms/redhat/bacula.spec.in +++ b/bacula/platforms/redhat/bacula.spec.in @@ -56,7 +56,7 @@ BuildRequires: ORBit2-devel BuildRequires: libart_lgpl-devel >= 2.0 BuildRequires: libbonobo-devel >= 2.0 BuildRequires: libbonoboui-devel >= 2.0 -BuildRequires: bonobo-activation-devel >= 2.0 +BuildRequires: bonobo-activation-devel BuildRequires: GConf2-devel BuildRequires: linc-devel %endif @@ -102,7 +102,7 @@ Requires: ORBit2 Requires: libart_lgpl >= 2.0 Requires: libbonobo >= 2.0 Requires: libbonoboui >= 2.0 -Requires: bonobo-activation >= 2.0 +Requires: bonobo-activation Requires: GConf2 Requires: linc %endif @@ -204,6 +204,9 @@ cd ${cwd} # patch the make_sqlite_tables script for installation bindir patch src/cats/make_sqlite_tables.in src/cats/make_sqlite_tables.in.patch +# patch the create_sqlite_database script for installation bindir +patch src/cats/create_sqlite_database.in src/cats/create_sqlite_database.in.patch + # patch the make_catalog_backup script for installation bindir patch src/cats/make_catalog_backup.in src/cats/make_catalog_backup.in.patch @@ -214,7 +217,7 @@ patch src/cats/make_catalog_backup.in src/cats/make_catalog_backup.in.patch --with-scriptdir=/etc/bacula \ --enable-smartalloc \ --enable-gnome \ - --enable-static-fd \ + --enable-static-fd \ %if %{mysql} --with-mysql \ %else @@ -431,7 +434,10 @@ echo "Creating bacula tables..." # add execute permission for console chmod 0755 /usr/sbin/gnome-console -# create the tables +# create the database and tables +echo "Creating SQLite database..." +/etc/bacula/create_sqlite_database +echo "Creating the SQLite tables..." /etc/bacula/make_sqlite_tables %preun sqlite @@ -518,6 +524,9 @@ rm -f /etc/bacula/rescue/sfdisk rm -rf /etc/bacula/rescue/diskinfo/* %changelog +* Sat Jan 24 2004 D. Scott Barninger +- added patch for create_sqlite_database to fix the installed bindir +- added execute of create_sqlite_database to post of sqlite package * Sat Jan 10 2004 D. Scott Barninger - added virtual package Provides bacula-dir, bacula-sd, bacula-fd - added bacula-fd as Requires for rescue package diff --git a/bacula/src/cats/create_sqlite_database.in.patch b/bacula/src/cats/create_sqlite_database.in.patch new file mode 100644 index 0000000000..85d2dcbe8c --- /dev/null +++ b/bacula/src/cats/create_sqlite_database.in.patch @@ -0,0 +1,4 @@ +5c5 +< bindir=@SQL_BINDIR@ +--- +> bindir=/usr/lib/sqlite diff --git a/bacula/src/console/console.c b/bacula/src/console/console.c index 6436ab9a35..3e3dc3cf7b 100644 --- a/bacula/src/console/console.c +++ b/bacula/src/console/console.c @@ -404,6 +404,7 @@ try_again: LockRes(); CONRES *cons = (CONRES *)GetNextRes(R_CONSOLE, (RES *)NULL); UnlockRes(); + /* If cons==NULL, default console will be used */ if (!authenticate_director(&jcr, dir, cons)) { fprintf(stderr, "ERR=%s", UA_sock->msg); terminate_console(0); diff --git a/bacula/src/console2.glade b/bacula/src/console2.glade index 2c2619445c..c62ae83ae8 100644 --- a/bacula/src/console2.glade +++ b/bacula/src/console2.glade @@ -2,6 +2,7 @@ + True @@ -998,204 +999,218 @@ - + True - False - 0 + 0.5 + 0.5 + 1 + 1 - + True False 0 - + True - Job: - False - False - GTK_JUSTIFY_RIGHT - False - False - 0.5 - 0.5 - 0 - 0 - - - 0 - False - False - - + False + 0 - - - True - True - False - False - True - False - - - + + + 66 + 16 True - True - False - True - 0 - - True - * - False - + Job: + False + False + GTK_JUSTIFY_RIGHT + False + False + 0.5 + 0.5 + 0 + 0 + + 0 + False + False + - - + + True - GTK_SELECTION_BROWSE + True + False + False + True + False + + + + True + True + False + True + 0 + + True + * + False + + + - - + + True + GTK_SELECTION_BROWSE - + True - - False - False - GTK_JUSTIFY_LEFT - False - False - 0 - 0.5 - 0 - 0 + + + + True + + False + False + GTK_JUSTIFY_LEFT + False + False + 0 + 0.5 + 0 + 0 + + + + 1 + True + True + - - - 1 - True - True - - - - - - True - Type: - False - False - GTK_JUSTIFY_CENTER - False - False - 0.5 - 0.5 - 0 - 0 - - - 0 - False - False - - - - - True - True - False - False - True - False - - - + + True - True - False - True - 0 - - True - * - False + Type: + False + False + GTK_JUSTIFY_CENTER + False + False + 0.5 + 0.5 + 0 + 0 + + 0 + False + False + - - + + + 141 + 24 True - GTK_SELECTION_BROWSE + True + False + False + True + False + + + + True + True + False + True + 0 + + True + * + False + + - - + + True + GTK_SELECTION_BROWSE - + True - - False - False - GTK_JUSTIFY_LEFT - False - False - 0 - 0.5 - 0 - 0 + + + + True + + False + False + GTK_JUSTIFY_LEFT + False + False + 0 + 0.5 + 0 + 0 + + + + 0 + False + False + - 6 + 0 + True + True + + + + + + True + + False + False + GTK_JUSTIFY_LEFT + False + False + 0.5 + 0.5 + 0 + 0 + + + 30 False False - - 0 - True - True - - - - - - True - - False - False - GTK_JUSTIFY_CENTER - False - False - 0.5 - 0.5 - 0 - 0 - - - 30 - False - False - @@ -1213,6 +1228,8 @@ + 65 + 16 True Client: False @@ -1327,6 +1344,8 @@ + 66 + 16 True FileSet: False @@ -1407,6 +1426,8 @@ + 93 + 26 True True View FileSet @@ -1457,6 +1478,8 @@ + 66 + 16 True Level: False @@ -1593,6 +1616,8 @@ + 66 + 16 True Pool: False @@ -1729,6 +1754,8 @@ + 66 + 16 True Storage: False @@ -1865,6 +1892,8 @@ + 66 + 16 True Messages: False @@ -1979,6 +2008,8 @@ + 66 + 16 True Where: False @@ -2060,6 +2091,8 @@ + 66 + 16 True When: False diff --git a/bacula/src/dird/ua_run.c b/bacula/src/dird/ua_run.c index e95e050b06..2753409556 100644 --- a/bacula/src/dird/ua_run.c +++ b/bacula/src/dird/ua_run.c @@ -289,11 +289,14 @@ int run_cmd(UAContext *ua, char *cmd) pool = (POOL *)GetResWithName(R_POOL, pool_name); if (!pool) { bsendmsg(ua, _("Pool \"%s\" not found.\n"), pool_name); - pool = get_pool_resource(ua); + pool = select_pool_resource(ua); } } else { pool = job->pool; /* use default */ } + if (!pool) { + return 1; + } if (client_name) { client = (CLIENT *)GetResWithName(R_CLIENT, client_name); diff --git a/bacula/src/lib/bnet.c b/bacula/src/lib/bnet.c index 76350d7d30..c55d953c5d 100644 --- a/bacula/src/lib/bnet.c +++ b/bacula/src/lib/bnet.c @@ -318,11 +318,10 @@ bnet_send(BSOCK *bsock) int32_t pktsiz; int32_t msglen; - if (bsock->errors || bsock->terminated) { + if (bsock->errors || bsock->terminated || bsock->msglen > 1000000) { return 0; } msglen = bsock->msglen; - ASSERT(bsock->msglen < 1000000); pktsiz = htonl((int32_t)bsock->msglen); /* send int32_t containing size of data packet */ bsock->timer_start = watchdog_time; /* start timer */ @@ -354,7 +353,6 @@ bnet_send(BSOCK *bsock) bsock->out_msg_no++; /* increment message number */ if (bsock->msglen <= 0) { /* length only? */ - ASSERT(msglen == bsock->msglen); return 1; /* yes, no data */ } @@ -381,7 +379,6 @@ bnet_send(BSOCK *bsock) } return 0; } - ASSERT(msglen == bsock->msglen); return 1; } diff --git a/bacula/src/stored/dircmd.c b/bacula/src/stored/dircmd.c index b3ddd63418..89748b4c0d 100644 --- a/bacula/src/stored/dircmd.c +++ b/bacula/src/stored/dircmd.c @@ -300,12 +300,8 @@ static int do_label(JCR *jcr, int relabel) P(dev->mutex); /* Use P to avoid indefinite block */ if (!(dev->state & ST_OPENED)) { - if (open_dev(dev, newname, READ_WRITE) < 0) { - bnet_fsend(dir, _("3994 Connot open device: %s\n"), strerror_dev(dev)); - } else { - label_volume_if_ok(jcr, dev, oldname, newname, poolname, slot, relabel); - force_close_dev(dev); - } + label_volume_if_ok(jcr, dev, oldname, newname, poolname, slot, relabel); + force_close_dev(dev); /* Under certain "safe" conditions, we can steal the lock */ } else if (dev->dev_blocked && (dev->dev_blocked == BST_UNMOUNTED ||