The http section sets the username and password for the Monit web interface, we also specify the SSL certificate generated earlier. If you use Mailgun then follow this guide for configuring Monit email alerts with Mailgun The Mail settings configuration below can be uncommented (by removing # starting from set mail-format line) and used for sending Monit alerts through gmail. Paste this Monit configuration as a starting point. Now restart the Monit Service sudo service monit restart Basic Monit Configurationīack up the original Monit configuration sudo mv /etc/monit/monitrc /etc/monit/monitrc.bakĬreate a new Monit configuration sudo nano /etc/monit/monitrc Sudo ln -s /etc/monit/monitrc /etc/monitrc Wget $MONITVER/monit-$MONITVER -linux-圆4.tar.gz change -linux-圆4.tar.gz to MONITVER=$(wget -q -O - | html2text | grep DIR | tail -n 1 | tr -d / | awk '') If you see i686 you need the 32 bit version i.e. If you see x86_64 you don’t have to change anything below. sudo service monit stopĬheck your CPU architecture since it determines which Monit binary you will use. Install html2text to easily parse the Monit download URL. Stop the Monit service first since we are going to overwrite the old Monit binary with a new one. If you don’t get any version information you can install the latest Monit now. This is Monit version 5.18īuilt with ssl, with pam and with large filesĬopyright (C) 2001-2016 Tildeslash Ltd. If you get this version information then you have a somewhat current version of Monit. Install Monit from the Ubuntu repository sudo apt install monit -y This command changes the permissions of the Monit ssl certificate sudo chmod 0700 /var/certs/monit.pem Install Latest Monit on Ubuntu etc/monit/monitrc:124: Error: SSL server PEM file permissions check failed 'allow' Modify the permissions of the SSL certificate to prevent this error monit: The SSL server PEM file '/var/certs/monit.pem' must have permissions no more than -rwx- (0700) right now permissions are -rw-r-r- (0644). sudo openssl req -new -x509 -days 365 -nodes -out /var/certs/monit.pem -keyout /var/certs/monit.pem Generate an SSL key, you can enter the information it prompts for if you want but you can also just leave it blank. Install OpenSSL sudo apt install openssl -yĬreate the SSL certs folder sudo mkdir -p /var/certs ![]() ![]() We want Monit to be secure so first we are going to generate an SSL certificate for the Monit web interface. Create an SSL Certificate for the Monit web interface.Install Latest Monit on Ubuntu 16.04 and Later It will send you email alerts if load becomes excessively high usually meaning a process has gone amok or you are under attack.Īn array of Monit configurations for monitoring your WordPress server will be posted to make sure everything is running as smoothly as possible and all your services are running. Monit can help monitor your web server to ensure all of its essential processes are running. Like all servers, for one reason or another services can be unstable or crash. Linux systems make solid web servers for hosting WordPress sites.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |