From: Kern Sibbald Date: Fri, 7 Sep 2007 14:54:07 +0000 (+0000) Subject: First cut multi-client test X-Git-Tag: Release-7.0.0~5719 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=1164fc23f1699b1635a89c94713586d68e947b95;p=bacula%2Fbacula First cut multi-client test git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@5494 91ce42f0-d328-0410-95d8-f526ca767f89 --- diff --git a/regress/scripts/do_sed b/regress/scripts/do_sed index 17f39a448a..2f46089e98 100755 --- a/regress/scripts/do_sed +++ b/regress/scripts/do_sed @@ -32,7 +32,7 @@ echo "s%@hostname3_password@%${hostname3_password}%g" >>${out} # process .in files with sed script sed -f ${out} ${cwd}/scripts/bacula-dir.conf.errors.in >${cwd}/scripts/bacula-dir.conf.errors sed -f ${out} ${cwd}/scripts/test-bacula-dir.conf.in >${cwd}/scripts/test-bacula-dir.conf -sed -f ${out} ${cwd}/scripts/multihost-bacula-dir.conf.in >${cwd}/scripts/multihost-bacula-dir.conf +sed -f ${out} ${cwd}/scripts/multi-client-bacula-dir.conf.in >${cwd}/scripts/multi-client-bacula-dir.conf sed -f ${out} ${cwd}/scripts/bacula-dir.conf.regexwhere.in >${cwd}/scripts/bacula-dir.conf.regexwhere sed -f ${out} ${cwd}/scripts/bacula-dir.conf.maxtime.in >${cwd}/scripts/bacula-dir.conf.maxtime sed -f ${out} ${cwd}/scripts/new-test-bacula-dir.conf.in >${cwd}/scripts/new-test-bacula-dir.conf diff --git a/regress/scripts/multi-client-bacula-dir.conf.in b/regress/scripts/multi-client-bacula-dir.conf.in new file mode 100644 index 0000000000..3ee7eba306 --- /dev/null +++ b/regress/scripts/multi-client-bacula-dir.conf.in @@ -0,0 +1,391 @@ +# +# Default Bacula Director Configuration file +# +# The only thing that MUST be changed is to add one or more +# file or directory names in the Include directive of the +# FileSet resource. +# +# For Bacula release 2.2.2 +# +# You might also want to change the default email address +# from root to your address. See the "mail" and "operator" +# directives in the Messages resource. +# + +Director { # define myself + Name = @hostname@-dir + DIRport = 8101 # where we listen for UA connections + QueryFile = "@scriptdir@/query.sql" + WorkingDirectory = "@working_dir@" + PidDirectory = "@piddir@" + SubSysDirectory = "@subsysdir@" + Maximum Concurrent Jobs = 4 + Password = "pNvX1WiXnwv2C/F7E52LGvw6rKjbbPvu2kyuPa9pVaL3" # Console password + Messages = Daemon +} + +# +# Define the main nightly save backup job +# By default, this job will back up to disk in /tmp +Job { + Name = "NightlySave" + Type = Backup + Client=@hostname@-fd + FileSet="Full Set" + Storage = File + Messages = Standard + Pool = Default + Write Bootstrap = "@working_dir@/NightlySave.bsr" + Maximum Concurrent Jobs = 4 +} + +Job { + Name = @hostname1@ + Type = Backup + Client = @hostname1@-fd + FileSet = "@hostname1@-FileSet" + Storage = File + Messages = Standard + Pool = Default + Write Bootstrap = "@working_dir@/NightlySave.bsr" + Maximum Concurrent Jobs = 4 +} + +Job { + Name = @hostname2@ + Type = Backup + Client = @hostname2@-fd + FileSet = "@hostname2@-FileSet" + Storage = File + Messages = Standard + Pool = Default + Write Bootstrap = "@working_dir@/NightlySave.bsr" + Maximum Concurrent Jobs = 4 +} + +Job { + Name = @hostname3@ + Type = Backup + Client = @hostname3@-fd + FileSet = "@hostname3@-FileSet" + Storage = File + Messages = Standard + Pool = Default + Write Bootstrap = "@working_dir@/NightlySave.bsr" + Maximum Concurrent Jobs = 4 + SpoolData=yes +} + + +Job { + Name = "NightlySave" + Type = Backup + Client=@hostname@-fd + FileSet="Full Set" + Storage = File + Messages = Standard + Pool = Default + Write Bootstrap = "@working_dir@/NightlySave.bsr" + Maximum Concurrent Jobs = 4 + SpoolData=yes +} + + +Job { + Name = "MonsterSave" + Type = Backup + Client=@hostname@-fd + FileSet="Full Set" + Storage = File1 + Messages = Standard + Pool = Default + Write Bootstrap = "@working_dir@/NightlySave.bsr" +} + + +Job { + Name = "VerifyVolume" + Type = Verify + Level = VolumeToCatalog + Client=@hostname@-fd + FileSet="Full Set" + Storage = File + Messages = Standard + Pool = Default + Write Bootstrap = "@working_dir@/NightlySave.bsr" +} + + +Job { + Name = "SparseTest" + Type = Backup + Client=@hostname@-fd + FileSet="SparseSet" + Storage = File + Messages = Standard + Pool = Default + Write Bootstrap = "@working_dir@/NightlySave.bsr" +} + +Job { + Name = "CompressedTest" + Type = Backup + Client=@hostname@-fd + FileSet="CompressedSet" + Storage = File + Messages = Standard + Pool = Default + Maximum Concurrent Jobs = 4 + Write Bootstrap = "@working_dir@/NightlySave.bsr" +# Max Run Time = 15 seconds +} + +Job { + Name = "SparseCompressedTest" + Type = Backup + Client=@hostname@-fd + FileSet="SparseCompressedSet" + Storage = File + Messages = Standard + Pool = Default + Write Bootstrap = "@working_dir@/NightlySave.bsr" +} + + +# Backup the catalog database (after the nightly save) +Job { + Name = "BackupCatalog" + Type = Backup + Client=@hostname@-fd + FileSet="Catalog" +# Schedule = "WeeklyCycleAfterBackup" + Storage = File + Messages = Standard + Pool = Default + # This creates an ASCII copy of the catalog + RunBeforeJob = "@sbindir@/make_catalog_backup -u regress" + # This deletes the copy of the catalog + RunAfterJob = "@sbindir@/delete_catalog_backup" + Write Bootstrap = "@working_dir@/BackupCatalog.bsr" +} + +# Standard Restore template, to be changed by Console program +Job { + Name = "RestoreFiles" + Type = Restore + Client=@hostname@-fd + FileSet="Full Set" + Storage = File + Messages = Standard + Pool = Default + Where = /tmp/bacula-restores +} + + +# List of files to be backed up +FileSet { + Name = "Full Set" + Include { Options { signature=MD5 } + File = tmp/bconcmds +@output /dev/null +messages +@$out tmp/log1.out +label storage=File1 +TestVolume001 +label storage=File1 +TestVolume002 +update Volume=TestVolume001 MaxVolBytes=200000000 +@#50000000 +@#12 +@#setdebug level=51 Storage=File1 +status storage=File1 +llist volume=TestVolume001 +llist volume=TestVolume002 +run job=${hostname1} level=Full Storage=File1 +yes +llist volume=TestVolume001 +llist volume=TestVolume002 +run job=${hostname2} level=Full Storage=File1 +yes +reload +llist volume=TestVolume001 +llist volume=TestVolume002 +run job=${hostname3} level=Full Storage=File1 +yes +llist volume=TestVolume001 +llist volume=TestVolume002 +status storage=File1 +run job=$JobName level=Full Storage=File1 +yes +status storage=File1 +@sleep 2 +status dir +status storage=File1 +llist volume=TestVolume001 +llist volume=TestVolume002 +@sleep 5 +messages +wait +status storage=File1 +messages +@# +@# now do a restore +@# +@$out tmp/log2.out +restore where=${cwd}/tmp/bacula-restores client=${hostname} select storage=File1 +unmark * +mark * +done +yes +wait +reload +reload +messages +@output +quit +END_OF_DATA + +run_bacula +check_for_zombie_jobs storage=File1 +stop_bacula + +check_two_logs +check_restore_diff +end_test