From cacb0d8f2b5e2720365963a7ee32355003ff04c3 Mon Sep 17 00:00:00 2001 From: Eric Bollengier Date: Sat, 13 Feb 2010 17:05:01 +0100 Subject: [PATCH] Tweak multi2-storage-test --- regress/scripts/bacula-dir-tape.conf.in | 26 +++++++++++-------------- regress/tests/multi2-storage-test | 17 +++++++++------- 2 files changed, 21 insertions(+), 22 deletions(-) diff --git a/regress/scripts/bacula-dir-tape.conf.in b/regress/scripts/bacula-dir-tape.conf.in index 0a71657ba4..48a1c8acf9 100644 --- a/regress/scripts/bacula-dir-tape.conf.in +++ b/regress/scripts/bacula-dir-tape.conf.in @@ -166,19 +166,6 @@ Client { Maximum Concurrent Jobs = 100 } -# Definition of DDS tape storage device -Storage { - Name = tape - Address = @hostname@ # N.B. Use a fully qualified name here - SDPort = @sdport@ - Password = "ccV3lVTsQRsdIUGyab0N4sMDavui2hOBkmpBU0aQKOr9" # password for Storage daemon - Device = tape # must be same as Device in Storage daemon - Media Type = tape # must be same as MediaType in Storage daemon - Maximum Concurrent Jobs = 100 -# Autochanger = yes -} - - # Definition of File storage device Storage { Name = File @@ -201,7 +188,6 @@ Storage { Maximum Concurrent Jobs = 100 } - # Definition of File3 storage device Storage { Name = File3 @@ -224,7 +210,17 @@ Storage { Maximum Concurrent Jobs = 100 } - +# Definition of DDS tape storage device +Storage { + Name = tape + Address = @hostname@ # N.B. Use a fully qualified name here + SDPort = @sdport@ + Password = "ccV3lVTsQRsdIUGyab0N4sMDavui2hOBkmpBU0aQKOr9" # password for Storage daemon + Device = tape # must be same as Device in Storage daemon + Media Type = tape # must be same as MediaType in Storage daemon + Maximum Concurrent Jobs = 100 +# Autochanger = yes +} # Definition of Virtual storage device Storage { diff --git a/regress/tests/multi2-storage-test b/regress/tests/multi2-storage-test index c33daed797..22b1aeb219 100755 --- a/regress/tests/multi2-storage-test +++ b/regress/tests/multi2-storage-test @@ -12,17 +12,19 @@ scripts/prepare-disk-changer # create a new bacula-sd.confs for sd in 2 3 4; do - perl -ne ' - if (/SDPort = /) { $_ =~ s/(\d+)/1810$sd/;} - if (/Name = .+?-sd/) { $_ =~ s/-sd/-sd$sd/;} - if (/WorkingDirectory/) { $_ =~ s/"$/$sd"/; } - if (/Pid Directory/) { $_ =~ s/"$/$sd"/; } + perl -ne "\$sd=$sd;\$tmp='$tmp';"' + if (/SDPort = /) { $_ =~ s/(\d+)/1810$sd/} + if (/Name = .+?-sd/) { $_ =~ s/-sd/-sd$sd/} + if (/WorkingDirectory/) { $_ = "$tmp/$sd"} + if (/Pid Directory/) { $_ = "$tmp/$sd"} + if (/(Archive|Changer) Device/) { $_ =~ s:$tmp:$tmp/$sd:} print; ' $conf/bacula-sd.conf > $conf/bacula-sd$sd.conf mkdir -p ${working}$sd sed 's/bacula-sd.conf/bacula-sd$sd.conf/' $scripts/bacula-ctl-sd \ > $tmp/bacula-ctl-sd$sd chmod +x $tmp/bacula-ctl-sd$sd + mkdir -p $tmp/$sd done # Patch up bacula-dir.conf @@ -84,9 +86,10 @@ setdebug trace=1 level=110 director restore where=${cwd}/tmp/bacula-restores select all done yes wait messages +show storage sql -select * in Storage; - +select * FROM Storage; +select VolumeName, Name, StorageId, MediaType FROM Media JOIN Storage USING (StorageId); quit END_OF_DATA -- 2.39.5