How to Disable cPanel Service Monitoring via SSH

Cpanel by default monitors all services installed on a server using chkservd daemon

Chkservd monitors all the services and if for some reason a service goes down it automatically tries to restart it.

In the process it sends email notifications and with time this can result to having thousands of emails in your inbox.

Disabling and/or enabling service monitoring can be done from the WHM interface but if the license is not renewed then this will need to be done via the CLI

Below are the steps involved when enabling and/or disabling services from cPanel monitoring via CLI.

  1. Log in to your server as root
  2. Copy the original chkservd configuration file before editing using the command below

    cp -p /etc/chkserv.d/chkservd.conf /etc/chkserv.d/chkservd.conf.$(date +%F)

    This creates a copy of the config file before editing preserving the last edit information.

    It is good practice to always create a copy of a config file before editing just in case you need to revert back to the original settings.

  3. Open the configuration file using your favorite editor

    vi /etc/chkserv.d/chkservd.conf

  4. The services can be enabled and disabled by using 0 and 1

(image1)

  1. Restart chkservd

    /scripts/restartsrv_chkservd

Leave a Reply

Your email address will not be published.