HostOnNet Blog

TailWatch – Monitor Services in Cpanel Server

Looking for Linux Server Admin or WordPress Expert? We can help.

TailWatch is a service that monitors log files for errors in Cpanel Servers.

TailWatch also monitors following cpanel modules

  • chkservd
  • cpbandwd
  • eximstats
  • jailmanager
  • modseclog
  • recentauthedmailiptracker

chkservd

chkservd determines whether a process is online and whether to restart it.

Config files for chkservd located in folder

/etc/chkserv.d

Each service have its own file. chkservd.conf allow you to enable/disable service monitoring.

[root@server78 ~]# cat /etc/chkserv.d/chkservd.conf 
cpanel_php_fpm:1
cpdavd:1
cpgreylistd:0
cphulkd:0
cpsrvd:1
crond:1
dnsadmin:1
exim:1
ftpd:1
httpd:1
imap:1
ipaliases:1
lfd:1
lmtp:1
mailman:0
mysql:1
named:1
nscd:1
p0f:0
pop:1
rsyslogd:1
spamd:1
sshd:1
[root@server78 ~]# 

To restart chkservd, run

/scripts/restartsrv_chkservd 

Example

[root@server78 ~]# /scripts/restartsrv_chkservd 
Waiting for “tailwatchd” to restart ………waiting for “tailwatchd” to initialize ………finished.

Service Status
	tailwatchd (tailwatchd) is running as root with PID 716378 (systemd check method).
	tailwatchd (tailwatchd - chkservd - named check) is running as root with PID 716383 (systemd check method).
	tailwatchd (/usr/local/cpanel/scripts/restartsrv_base named --check --notconfigured-ok) is running as root with PID 716404 (systemd check method).

Startup Log
	Mar 14 08:52:33 server78.hostonnet.com systemd[1]: Starting tailwatchd...
	Mar 14 08:52:33 server78.hostonnet.com systemd[1]: PID file /var/run/tailwatchd.pid not readable (yet?) after start.
	Mar 14 08:52:33 server78.hostonnet.com restartsrv_tailwatchd[716366]: [Tue Mar 14 08:52:33 2017] Starting /usr/local/cpanel/libexec/tailwatch/tailwatchd daemon
	Mar 14 08:52:33 server78.hostonnet.com restartsrv_tailwatchd[716366]: Log is at /usr/local/cpanel/logs/tailwatchd_log
	Mar 14 08:52:33 server78.hostonnet.com systemd[1]: tailwatchd.service: Supervising process 716378 which is not our child. We'll most likely not notice when it exits.
	Mar 14 08:52:33 server78.hostonnet.com systemd[1]: Started tailwatchd.

tailwatchd restarted successfully.
[root@server78 ~]# 

chkservd log available at

tail /var/log/chkservd.log

TailWatch

Log file for TailWatch available at

tail /usr/local/cpanel/logs/tailwatchd_log

Posted in Cpanel Server

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.