From: Kern Sibbald Date: Mon, 18 Jun 2007 14:29:50 +0000 (+0000) Subject: Update X-Git-Tag: Release-7.0.0~6121 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=9d251a44f4daa0edb1b28091379e29526d0f9270;p=bacula%2Fbacula Update git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@5036 91ce42f0-d328-0410-95d8-f526ca767f89 --- diff --git a/regress/README b/regress/README index efd85e9e8e..5f5aad70aa 100644 --- a/regress/README +++ b/regress/README @@ -143,3 +143,31 @@ Also, if you run from time to time on a computer that is not connected to the network, please be sure that "hostname" is set to "localhost", otherwise, your tests may fail because the hostname used by Bacula's ./configure cannot be properly resolved. + +Anyway, you can debug where it is happening in the source code using the +following example. For example, here I get the following backtrace: + +======= Backtrace: ========= +/lib/libc.so.6[0xb7b9d6e1] +/lib/libc.so.6(cfree+0x89)[0xb7b9ed79] +/home/kern/bacula/regress/bin/bacula-fd[0x8082ae5] +/home/kern/bacula/regress/bin/bacula-fd[0x8082d58] +/home/kern/bacula/regress/bin/bacula-fd[0x80838ac] +/home/kern/bacula/regress/bin/bacula-fd[0x807aa3f] +/home/kern/bacula/regress/bin/bacula-fd[0x807ac29] +/home/kern/bacula/regress/bin/bacula-fd[0x804d188] +/lib/libc.so.6(__libc_start_main+0xdc)[0xb7b4ef9c] +/home/kern/bacula/regress/bin/bacula-fd[0x804cd21] + +Now to convert this into something more meaningful, kill off any hung Bacula +processes. Note the one that was running -- above you see that it was +bacula-fd, then bring the same binary up in the debugger. Then start at the +first bacula-fd line, and feed the hex number to gdb as follows: + +info symbol 0x8082ae5 +free_addresses(dlist*) + 53 in section .text + +info symbol 0x8082d58 +add_address(dlist**, IPADDR::i_type, unsigned short, int, char const*, char +const*, char**) + 568 in section .text + diff --git a/regress/tests/bscan-test b/regress/tests/bscan-test index 59c4905400..a009c932d7 100755 --- a/regress/tests/bscan-test +++ b/regress/tests/bscan-test @@ -29,6 +29,12 @@ update Volume=TestVolume001 MaxVolBytes=3000000 run job=$JobName storage=File1 yes wait +list volumes +list files jobid=1 +sql +select * from JobMedia; + + messages @$out /dev/null @# @@ -48,13 +54,10 @@ run_bacula check_for_zombie_jobs storage=File1 stop_bacula -echo "volume=TestVolume001|TestVolume002" >tmp/bscan.bsr +echo "volume=TestVolume001" >tmp/bscan.bsr +echo "volume=TestVolume002" >>tmp/bscan.bsr -if test "$debug" -eq 1 ; then - bin/bscan -w working -u regress -n regress -m -s -v -b tmp/bscan.bsr -c bin/bacula-sd.conf ${cwd}/tmp -else - bin/bscan -w working -u regress -n regress -m -s -v -b tmp/bscan.bsr -c bin/bacula-sd.conf ${cwd}/tmp 2>&1 >/dev/null -fi +bin/bscan -w working -u regress -n regress -m -s -v -b tmp/bscan.bsr -c bin/bacula-sd.conf ${cwd}/tmp 2>&1 >tmp/log3.out cat <tmp/bconcmds @$out /dev/null diff --git a/regress/tests/regexwhere-test b/regress/tests/regexwhere-test index cecbc5f95f..d38537c128 100755 --- a/regress/tests/regexwhere-test +++ b/regress/tests/regexwhere-test @@ -8,12 +8,9 @@ JobName=backup . scripts/functions -copy_test_confs +scripts/cleanup +scripts/copy_test_confs -rm -f bin/bacula-dir.conf -rm -f tmp/RUN* -rm -f ${cwd}/build/po/*old* -rm -rf tmp/po /bin/cp -f scripts/bacula-dir.conf.regexwhere bin/bacula-dir.conf echo "${cwd}/build/po" >/tmp/file-list @@ -160,9 +157,8 @@ messages quit END_OF_DATA +run_bacula -bin/bacula start -cat tmp/bconcmds | bin/bconsole -c bin/bconsole.conf > /dev/null stop_bacula