From 91c661bb40477c7b770d0dfa1d53f7cabfe22e41 Mon Sep 17 00:00:00 2001 From: Christoph Date: Tue, 15 Jan 2019 17:14:53 +0000 Subject: [PATCH] install_mysql.sh: fix error replacing 'EnvironmentFile' variable at service file (parallel installation). --- install_mysql.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/install_mysql.sh b/install_mysql.sh index 5c95c02..99a0086 100755 --- a/install_mysql.sh +++ b/install_mysql.sh @@ -4849,8 +4849,8 @@ EOF echo "## -" >> ${logdir}/main.log if grep -q -E "^\s*EnvironmentFile\s*=" /etc/systemd/system/$MYSQL_SERVICE_FILE ; then - echo "perl -i -n -p -e \"s/^(\s*EnvironmentFile\s*=.*)/#\1\nEnvironmentFile=-${SYSTEMD_ENV_FILE}\" /etc/systemd/system/$MYSQL_SERVICE_FILE" >> ${logdir}/main.log - perl -i -n -p -e "s/^(\s*EnvironmentFile\s*=.*)/#\1\nEnvironmentFile=-${SYSTEMD_ENV_FILE}/" \ + echo "perl -i -n -p -e \"s#^(\s*EnvironmentFile\s*=.*)#\#\1\nEnvironmentFile=-${SYSTEMD_ENV_FILE}#\" /etc/systemd/system/$MYSQL_SERVICE_FILE" >> ${logdir}/main.log + perl -i -n -p -e "s#^(\s*EnvironmentFile\s*=.*)#\#\1\nEnvironmentFile=-${SYSTEMD_ENV_FILE}#" \ /etc/systemd/system/$MYSQL_SERVICE_FILE >> ${logdir}/main.log 2>&1 _retval=$? else