Dec 232009

On a fresh Centos server with CPanel installed it seems that chkservd was not running. chkservd is a little CPanel utility that allows you to check from WHM what applications it will monitor, and in case there is a problem with any of those services it will restart it and send a notification to the administrative account. If for some reason chkservd was not installed during the initial installation process of CPanel we can reinstall it later by running:


But running this on this Centos system can given the following error:

Unable to locate chkservd init script for OS CentOS 4.3

It seems that the install script is checking the OS installed. A quick look inside the script will show us that this is done using some internal CPanel function:

$os = Cpanel::cPanelFunctions::getos();

To solve this, without changing the internal CPanel scripts, was to make it think that this is one of the supported systems and since Centos4, is basically RHEL4, I changed the distribution banner to RHEL, this way:

CentOS release 4.3 (Final)

#change from:
“CentOS release 4.3 (Final)”
#change to
“Red Hat Enterprise Linux ES release 4”

After this change, the install script ran without any error and installed chkservd properly and it started it ok. I then changed the banner back to the original statement.

This could have been done also by copying the init scripts from redhat:


and renaming them


After this chkservd is running just fine on this Centos server and it can be configured from WHM (Service Configuration >> Service Manager) as on any other CPanel system.

 Posted by at 1:15 am