From 5ea0aa88dde5acb6dade0c4892a9b8dfa38902ab Mon Sep 17 00:00:00 2001 From: iadgovuser26 Date: Fri, 13 Oct 2023 16:38:34 +0000 Subject: [PATCH] fixed call to mysqld_safe --- package/scripts/db/mysql_util.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/package/scripts/db/mysql_util.sh b/package/scripts/db/mysql_util.sh index 03acbd0e9..08d62daf5 100755 --- a/package/scripts/db/mysql_util.sh +++ b/package/scripts/db/mysql_util.sh @@ -57,7 +57,7 @@ start_mysqlsd () { chown -R mysql:mysql /var/lib/mysql/ >> "$LOG_FILE" fi if [[ $PRINT_STATUS == "-p" ]]; then echo "Starting mysql..."; fi - /usr/bin/mysqld_safe --skip-syslog & >> "$LOG_FILE"; + /usr/bin/mysqld_safe --skip-syslog >> "$LOG_FILE" & chown -R mysql:mysql /var/lib/mysql/ >> "$LOG_FILE" echo "Attempting to start mariadb" else #not a container @@ -89,7 +89,7 @@ check_mysql () { if [[ $(pgrep -c -u mysql $PROCESS ) -eq 0 ]]; then echo "mariadb not running , attempting to restart" chown mysql:mysql /var/log/mariadb/mariadb.log >> "$LOG_FILE"; - /usr/bin/mysqld_safe --skip-syslog & >> "$LOG_FILE" + /usr/bin/mysqld_safe --skip-syslog >> "$LOG_FILE" & fi else # not in a contianer DB_STATUS=$(systemctl status mysql |grep 'running' | wc -l ) @@ -179,5 +179,5 @@ mysqld_reboot () { mysql -u root --password=$DB_ADMIN_PWD -e "SHUTDOWN" sleep 2 check_for_container - start_mysqlsd + start_mysqlsd >> "$LOG_FILE"; }