diff --git a/install-librenms.sh b/install-librenms.sh index cb74ed7..9417afa 100755 --- a/install-librenms.sh +++ b/install-librenms.sh @@ -3,7 +3,7 @@ : " install-librenms.sh -This is just a script I created to handle automating the installation of LibreNMS on a CentOS8 (any rhel v8 base distro will work) host +This is just a script I created to handle automating the installation of LibreNMS on a Rocky 8 machine (any distro will do) I will update it after getting my own instance setup in my lab, as my coworkers are wanting to use this for work. Will design it to actually handle settings already being set (so it will skip the un-necessary steps) @@ -20,7 +20,7 @@ FQDN=librenms.example.com LIBRENMS_ROOT=/opt/librenms SNMP_COMMUNITY=lab -## Config Files that need to be interacte with throughout the script +## Config Files that need to be interacted with throughout the script SELINUX_CONFIG=/etc/selinux/config PHP_ini=/etc/php.ini MARIADB_CONF=/etc/my.cnf.d/mariadb-server.cnf @@ -76,7 +76,7 @@ TIMEZONE_CLEANED="${TIMEZONE/\//\\/}" ### Make backup cp $PHP_ini{,.bak} -sed -i s"/\#date.timezone=/date.timezone=$TIMEZONE_CLEANED/" $PHP_ini +sed -i s"/\;date.timezone=/date.timezone=$TIMEZONE_CLEANED/" $PHP_ini ### Configure timezone with system timedatectl set-timezone $TIMEZONE @@ -159,7 +159,7 @@ if [[ "${SELINUX_STATE,,}" =~ ^enforcing|permissive$ ]]; then fi ## If the running selinux is still set to enforcing, set it to permissive (will be diabled next boot) -if [[ `genenforce` == 'Enforcing' ]]; then +if [[ `getenforce` == 'Enforcing' ]]; then setenforce 0 fi