Skip to content

Commit

Permalink
percona-xtrabackup test: fix shutdown procedure
Browse files Browse the repository at this point in the history
If the "mysql_install_db" binary is not found by cmake, the value of
$MYSQL_INSTALL_DB  is not the empty string as expected by the former code,
but "MYSQL_INSTALL_DB-NOTFOUND".

This commit removes checks for this variable completely and only checks that the
possible pidfiles exist.
  • Loading branch information
pstorz committed Jun 28, 2021
1 parent 8458ba3 commit f0c52d1
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions systemtests/tests/py2plug-fd-percona-xtrabackup/testrunner
Expand Up @@ -23,11 +23,8 @@ JobName=backup-bareos-fd
"${rscripts}"/setup

shutdown_mysql_server(){
if [ -z "${MYSQL_INSTALL_DB:-}" ] ; then
[ -f "mysql/mysqld.pid" ] && kill "$(cat mysql/mysqld.pid)" || :
else
[ -f "mysql/data/${HOSTNAME}.pid" ] && kill "$(cat mysql/data/${HOSTNAME}.pid)" || :
fi
[ -f "mysql/mysqld.pid" ] && kill "$(cat mysql/mysqld.pid)" || :
[ -f "mysql/data/${HOSTNAME}.pid" ] && kill "$(cat mysql/data/${HOSTNAME}.pid)" || :
}


Expand Down

0 comments on commit f0c52d1

Please sign in to comment.