Skip to end of metadata
Go to start of metadata

You want a current rpm of monit but you are running CentOS.

Step-by-step guide

Use the following as a guide to fetch the source or precompiled tarball, fetch the older packaged RPM, explode the package into a directory, replace the binaries documentation and configs, and repackage for distribution

This was the steps I took for monit 5.11 on CentOS 7 

mkdir source
cd source
wget http://mmonit.com/monit/dist/binary/5.11/monit-5.11-linux-x64.tar.gz
tar -xzvf monit-5.11-linux-x64.tar.gz
cd ..
#get all your fpm stuff
yum install ruby-devel gcc rpmbuild
gem install fpm
#get the distro rpm
yum install monit --downloadonly
cp /var/cache/yum/x86_64/7/epel-7-x86_64/packages/monit-5.6-1.el7.x86_64.rpm .
#explode it to a dir
fpm -s rpm -t dir monit-5.6-1.el7.x86_64.rpm
#replace the old with the new
mv source/monit-5.11/bin/monit monit.dir/usr/bin/monit
mv source/monit-5.11/conf/monitrc monit.dir/etc/monitrc
gzip source/monit-5.11/man/man1/monit.1
mv source/monit-5.11/man/man1/monit.1.gz monit.dir/usr/share/man/man1/monit.1.gz
mv source/monit-5.11/COPYING monit.dir/usr/share/doc/monit-5.6/
mv monit.dir/usr/share/doc/monit-5.6/ monit.dir/usr/share/doc/monit-5.11
#create an after upgrade script to reload the monit.service file
echo '#!/bin/sh
/bin/systemctl daemon-reload'>>upgrade
chmod +x upgrade
#package it up and distribute
fpm -s dir -t rpm --architecture x86_64 --name monit --version 5.11 --package /root/monit-5.11-1.el7.x86_64.rpm -C /root/monit.dir/ --after-upgrade /root/upgrade --config-files etc/monitrc usr etc