mirror of
https://github.com/nsacyber/HIRS.git
synced 2025-06-18 07:08:16 +00:00
fixed permission issue with mariadb.log
This commit is contained in:
@ -62,6 +62,7 @@ start_mysqlsd () {
|
|||||||
if [ ! -d "/var/lib/mysql/mysql/" ]; then
|
if [ ! -d "/var/lib/mysql/mysql/" ]; then
|
||||||
echo "Installing mariadb" | tee -a "$LOG_FILE";
|
echo "Installing mariadb" | tee -a "$LOG_FILE";
|
||||||
/usr/bin/mysql_install_db >> "$LOG_FILE"
|
/usr/bin/mysql_install_db >> "$LOG_FILE"
|
||||||
|
chown -R mysql:mysql /var/log/mariadb/
|
||||||
fi
|
fi
|
||||||
if [[ $PRINT_STATUS == "-p" ]]; then echo "Starting mysql..."; 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" &
|
||||||
@ -226,6 +227,7 @@ mysqld_reboot () {
|
|||||||
if [[ $(pgrep -c $PROCESS) -ne 0 ]]; then
|
if [[ $(pgrep -c $PROCESS) -ne 0 ]]; then
|
||||||
pkill $PROCESS
|
pkill $PROCESS
|
||||||
fi
|
fi
|
||||||
|
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" &
|
||||||
sleep 1
|
sleep 1
|
||||||
check_mysql
|
check_mysql
|
||||||
|
Reference in New Issue
Block a user