Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/bareos/bareos.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Rogge <andreas.rogge@bareos.com>2022-09-30 13:56:00 +0300
committerAndreas Rogge <andreas.rogge@bareos.com>2022-11-07 19:37:28 +0300
commitcacce9929486ac8757d0504ab3e3dde3db25902e (patch)
treed2a59b5f4106692edf053b4022c3a2b679fe7fe6
parent9bb0154c87326b3b5e740d50106a840074bf76f5 (diff)
systemtests: fail early if daemon is misconfigured
-rw-r--r--systemtests/scripts/functions3
-rwxr-xr-xsystemtests/scripts/start_bareos.sh3
-rwxr-xr-xsystemtests/tests/autochanger/test-setup1
-rwxr-xr-xsystemtests/tests/bareos/test-setup3
-rwxr-xr-xsystemtests/tests/checkpoints/test-setup1
-rwxr-xr-xsystemtests/tests/checkpoints/testrunner-checkpoints-on-stop1
-rwxr-xr-xsystemtests/tests/parallel-jobs/test-setup1
-rwxr-xr-xsystemtests/tests/python-bareos/test-setup1
-rwxr-xr-xsystemtests/tests/scheduler-backup/test-setup1
-rwxr-xr-xsystemtests/tests/stresstest/test-setup1
10 files changed, 14 insertions, 2 deletions
diff --git a/systemtests/scripts/functions b/systemtests/scripts/functions
index 413684176..051035f2b 100644
--- a/systemtests/scripts/functions
+++ b/systemtests/scripts/functions
@@ -411,16 +411,19 @@ check_duration_lt()
}
start_dir() {
+ "${BAREOS_DIRECTOR_BINARY}" -c "${BAREOS_CONFIG_DIR}" -t </dev/null
"${BAREOS_DIRECTOR_BINARY}" -c "${BAREOS_CONFIG_DIR}" -f </dev/null &
dir_pid=$!
}
start_fd() {
+ "${BAREOS_FILEDAEMON_BINARY}" -c "${BAREOS_CONFIG_DIR}" -t </dev/null
"${BAREOS_FILEDAEMON_BINARY}" -c "${BAREOS_CONFIG_DIR}" -f </dev/null &
fd_pid=$!
}
start_sd() {
+ "${BAREOS_STORAGEDAEMON_BINARY}" -c "${BAREOS_CONFIG_DIR}" -t </dev/null
"${BAREOS_STORAGEDAEMON_BINARY}" -c "${BAREOS_CONFIG_DIR}" -f </dev/null &
sd_pid=$!
}
diff --git a/systemtests/scripts/start_bareos.sh b/systemtests/scripts/start_bareos.sh
index d04454a04..73b70c7ef 100755
--- a/systemtests/scripts/start_bareos.sh
+++ b/systemtests/scripts/start_bareos.sh
@@ -2,7 +2,7 @@
# BAREOSĀ® - Backup Archiving REcovery Open Sourced
#
-# Copyright (C) 2021-2021 Bareos GmbH & Co. KG
+# Copyright (C) 2021-2022 Bareos GmbH & Co. KG
#
# This program is Free Software; you can redistribute it and/or
# modify it under the terms of version three of the GNU Affero General Public
@@ -32,6 +32,7 @@ set -u
"${rscripts}"/setup
bin/bareos start
+bin/bareos status
# make sure, director is up and running.
print_debug "$(bin/bconsole <<< "status dir")"
diff --git a/systemtests/tests/autochanger/test-setup b/systemtests/tests/autochanger/test-setup
index bc74d296a..5d4579396 100755
--- a/systemtests/tests/autochanger/test-setup
+++ b/systemtests/tests/autochanger/test-setup
@@ -48,6 +48,7 @@ fi
setup_data
bin/bareos start
+bin/bareos status
# make sure, director is up and running.
print_debug "$(bin/bconsole <<< "status dir")"
diff --git a/systemtests/tests/bareos/test-setup b/systemtests/tests/bareos/test-setup
index 3b467ba11..824c7a1cc 100755
--- a/systemtests/tests/bareos/test-setup
+++ b/systemtests/tests/bareos/test-setup
@@ -2,7 +2,7 @@
# BAREOSĀ® - Backup Archiving REcovery Open Sourced
#
-# Copyright (C) 2021-2021 Bareos GmbH & Co. KG
+# Copyright (C) 2021-2022 Bareos GmbH & Co. KG
#
# This program is Free Software; you can redistribute it and/or
# modify it under the terms of version three of the GNU Affero General Public
@@ -35,6 +35,7 @@ set -u
setup_data
bin/bareos start
+bin/bareos status
# make sure, director is up and running.
print_debug "$(bin/bconsole <<< "status dir")"
diff --git a/systemtests/tests/checkpoints/test-setup b/systemtests/tests/checkpoints/test-setup
index 9f7be3d9b..c48c83ec8 100755
--- a/systemtests/tests/checkpoints/test-setup
+++ b/systemtests/tests/checkpoints/test-setup
@@ -35,6 +35,7 @@ set -u
setup_data
bin/bareos start
+bin/bareos status
# make sure, director is up and running.
print_debug "$(bin/bconsole <<< "status dir")"
diff --git a/systemtests/tests/checkpoints/testrunner-checkpoints-on-stop b/systemtests/tests/checkpoints/testrunner-checkpoints-on-stop
index 96177339d..55c6fbe8f 100755
--- a/systemtests/tests/checkpoints/testrunner-checkpoints-on-stop
+++ b/systemtests/tests/checkpoints/testrunner-checkpoints-on-stop
@@ -63,6 +63,7 @@ fi
bin/bareos stop
bin/bareos start
+bin/bareos status
slowjobid=$(grep 'Job queued. JobId=' "$backup_log" | sed -n -e 's/^.*JobId=//p')
diff --git a/systemtests/tests/parallel-jobs/test-setup b/systemtests/tests/parallel-jobs/test-setup
index 9f7be3d9b..c48c83ec8 100755
--- a/systemtests/tests/parallel-jobs/test-setup
+++ b/systemtests/tests/parallel-jobs/test-setup
@@ -35,6 +35,7 @@ set -u
setup_data
bin/bareos start
+bin/bareos status
# make sure, director is up and running.
print_debug "$(bin/bconsole <<< "status dir")"
diff --git a/systemtests/tests/python-bareos/test-setup b/systemtests/tests/python-bareos/test-setup
index 5fa79d635..1c138dbbe 100755
--- a/systemtests/tests/python-bareos/test-setup
+++ b/systemtests/tests/python-bareos/test-setup
@@ -21,5 +21,6 @@ setup_data
echo "${BackupDirectory}/build" >"$tmp/file-list-simple"
bin/bareos start
+bin/bareos status
print_debug "$(bin/bconsole <<< "status dir")"
diff --git a/systemtests/tests/scheduler-backup/test-setup b/systemtests/tests/scheduler-backup/test-setup
index 30231d4c2..85695c25e 100755
--- a/systemtests/tests/scheduler-backup/test-setup
+++ b/systemtests/tests/scheduler-backup/test-setup
@@ -53,6 +53,7 @@ echo "Schedule {
}" > "$conf"/bareos-dir.d/schedule/schedule.conf
bin/bareos start
+bin/bareos status
# make sure, director is up and running.
print_debug "$(bin/bconsole <<< "status dir")"
diff --git a/systemtests/tests/stresstest/test-setup b/systemtests/tests/stresstest/test-setup
index 1207a7dce..31c0e2b6f 100755
--- a/systemtests/tests/stresstest/test-setup
+++ b/systemtests/tests/stresstest/test-setup
@@ -38,6 +38,7 @@ fi
echo "$1" >$tmp/file-list
bin/bareos start
+bin/bareos status
# make sure, director is up and running.
print_debug "$(bin/bconsole <<< "status dir")"