diff --git a/MySQL-ModInst.sh b/MySQL-ModInst.sh index 3612aa5..fc88ced 100644 --- a/MySQL-ModInst.sh +++ b/MySQL-ModInst.sh @@ -46,7 +46,7 @@ elif [[ "${dist}" == *"centos"* ]] && [[ "${dist_ver}" == *"8"* ]]; then PKGM="dnf" PKGI="${PKGM} install --setopt=install_weak_deps=False --best -y" PKGLIST="dnf.pkg.list" - shortdist=cent8 + shortdist=el8 else echo "This OS is not supported" exit diff --git a/conf.sh b/conf.sh index d2bc5b1..1bfa02c 100644 --- a/conf.sh +++ b/conf.sh @@ -12,7 +12,7 @@ if [ "$shortdist" = "ubu1804" ] || [ "$shortdist" = "ubu2004" ] || [ "$shortdist MYSQLSNAME=mysql systemctl stop $MYSQLSNAME sed -i 's#MySQLlog#/var/log/mysql/error.log#g' /etc/mysql/my.cnf -elif [ "$shortdist" = "cent8" ]; then +elif [ "$shortdist" = "el8" ]; then MYSQLSNAME=mysqld systemctl stop $MYSQLSNAME sed -i 's#MySQLlog#/var/log/mysqld.log#g' /etc/mysql/my.cnf @@ -21,7 +21,7 @@ fi systemctl start $MYSQLSNAME systemctl enable $MYSQLSNAME -if [ "$shortdist" = "cent8" ]; then +if [ "$shortdist" = "el8" ]; then mysql -u root -p$(awk '/A temporary password is generated for/ {a=$0} END{ print a }' /var/log/mysqld.log | awk '{print $(NF)}') --connect-expired-password -e "ALTER USER 'root'@'localhost' IDENTIFIED BY '$password'"; fi diff --git a/mysql-8.0.sh b/mysql-8.0.sh index b1ac909..ed681f2 100644 --- a/mysql-8.0.sh +++ b/mysql-8.0.sh @@ -43,7 +43,7 @@ elif [[ "${dist}" == *"centos"* ]] && [[ "${dist_ver}" == *"8"* ]]; then PKGM="dnf" PKGI="${PKGM} install --setopt=install_weak_deps=False --best -y" PKGLIST="dnf.pkg.list" - shortdist=cent8 + shortdist=el8 echo "This os in not supported" exit else