Skip to content

Commit

Permalink
HDDS-4137. Turn on the verbose mode of safe mode check on testlib (ap…
Browse files Browse the repository at this point in the history
  • Loading branch information
maobaolong authored and rakeshadr committed Sep 3, 2020
1 parent d9d56f9 commit fe00ba9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions hadoop-ozone/dist/src/main/compose/testlib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ find_tests(){
## @description wait until safemode exit (or 180 seconds)
wait_for_safemode_exit(){
# version-dependent
: ${OZONE_ADMIN_COMMAND:=admin}
: ${OZONE_SAFEMODE_STATUS_COMMAND:=ozone admin safemode status --verbose}

#Reset the timer
SECONDS=0
Expand All @@ -72,7 +72,7 @@ wait_for_safemode_exit(){
while [[ $SECONDS -lt 180 ]]; do

#This line checks the safemode status in scm
local command="ozone ${OZONE_ADMIN_COMMAND} safemode status"
local command="${OZONE_SAFEMODE_STATUS_COMMAND}"
if [[ "${SECURITY_ENABLED}" == 'true' ]]; then
status=$(docker-compose exec -T scm bash -c "kinit -k HTTP/scm@EXAMPLE.COM -t /etc/security/keytabs/HTTP.keytab && $command" || true)
else
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@
# limitations under the License.

export OZONE_ADMIN_COMMAND=scmcli
export OZONE_SAFEMODE_STATUS_COMMAND='ozone scmcli safemode status'
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@
# limitations under the License.

export OZONE_ADMIN_COMMAND=admin
export OZONE_SAFEMODE_STATUS_COMMAND='ozone admin safemode status --verbose'

0 comments on commit fe00ba9

Please sign in to comment.