Zimbra Some Services Are Not Running: 4 Easy Fixes, No Bugs
Zimbra some services are not running is the message you see when the Server Status page of the admin console lists services with a red mark, although the Zimbra processes themselves can be fine. This happens often right after you install Zimbra in a multi server setup (a separate LDAP, mailbox and MTA server). This post shows the fix that worked in that case: restart the cron and rsyslog services, enable the UDP syslog input, run zmsyslogsetup and then zmupdateauthkeys as the zimbra user. It also explains from the Zimbra Administrator Guide why these steps turn the status green.
Contents
- What the message means: Zimbra some services are not running
- Before you fix Zimbra some services are not running: check the services
- How to tell a display problem from a real outage
- Step 1: restart cron when Zimbra some services are not running
- Step 2: enable the UDP input in rsyslog for Zimbra some services are not running
- Step 3: update the syslog configuration with zmsyslogsetup
- Step 4: update the authentication keys with zmupdateauthkeys
- Result: Zimbra some services are not running is gone
- Troubleshooting Zimbra some services are not running
- FAQ
- Why does a single-node Zimbra not show this error?
- Do the services restart when I run these commands?
- Where can I read more?
What the message means: Zimbra some services are not running
In the admin console the page Home, Monitor, Server Status lists, for each monitored server, its services and the time of the last status. In the failing case the services of the LDAP, mailbox and MTA servers are shown with a red mark, as in the screenshot:
The status page does not ask the services directly, which is why Zimbra some services are not running can appear while the mail flow still works. The Administrator Guide explains the chain: a cron job named status logging runs zmstatuslog every two minutes, zmstatuslog calls zmcontrol status and writes the result to syslog, and the Zimbra logger reads this data to keep the status of the administration console up to date. So when Zimbra some services are not running is shown without a real outage, the usual cause is a broken link in this chain: cron is not running, syslog does not receive or forward the messages, or the servers cannot exchange their keys.
Before you fix Zimbra some services are not running: check the services
Log in to each server as the zimbra user and look at the real state:
su - zimbra
zmcontrol status
If a service is really stopped, start it with zmcontrol start and read its log first. The steps below are for the case where the services run and only the status page shows red.
How to tell a display problem from a real outage
Compare three things before you change any configuration. First, the output of zmcontrol status on the server that shows red: if every service is listed as running, the processes are fine. Second, whether mail still flows, for example by sending a test message to a local account and checking that it arrives. Third, the age of the status on the Server Status page: if the time column is old, the status logging job is not delivering data, and this is exactly the situation in which Zimbra some services are not running is only a monitoring problem. If one of the three checks fails, deal with that service first and come back to the syslog steps afterwards.
Step 1: restart cron when Zimbra some services are not running
The status logging job needs cron. On the CentOS/RHEL system used in this setup, restart crond and make it start at boot (commands as root):
service crond restart
chkconfig crond on
Step 2: enable the UDP input in rsyslog for Zimbra some services are not running
The Administrator Guide says that, in a multi server installation, you must configure syslog on the logger monitor host to accept syslog messages from remote machines. With the legacy rsyslog syntax used on CentOS 6 you uncomment two lines in /etc/rsyslog.conf:
vim /etc/rsyslog.conf
$ModLoad imudp
$UDPServerRun 514
The original post wrote these lines as $modload imupd and $UDPServerRun514; the correct module name is imudp and the port is separated by a space. Then restart rsyslog and enable it at boot:
service rsyslog restart
chkconfig rsyslog on
Because the input listens on UDP port 514, allow that port from your Zimbra servers only and block it from other networks.
Step 3: update the syslog configuration with zmsyslogsetup
On each server, as root, run the Zimbra helper that writes the Zimbra part of the syslog configuration. The Administrator Guide calls it the step that updates the syslog configuration to enable gathering server statistics:
/opt/zimbra/libexec/zmsyslogsetup
The guide adds that this is not necessary for a single-node installation, which is why a single server rarely shows this problem.
Step 4: update the authentication keys with zmupdateauthkeys
Now switch to the zimbra user and fetch the SSH keys that Zimbra generated for the servers. The Administrator Guide describes zmupdateauthkeys as the tool used to fetch the ssh encryption keys created by zmsshkeygen:
su - zimbra
zmupdateauthkeys
Run it on the LDAP server, the mailbox server and the MTA server of the environment. If an error remains, restart the Zimbra services on that server with zmcontrol restart and look at the status again.
Result: Zimbra some services are not running is gone
Wait for the next status logging run (every two minutes, according to the guide), refresh the Server Status page and check that the services are marked as running:
Troubleshooting Zimbra some services are not running
- Still red after five minutes. Check
service crond statusandservice rsyslog statuson every server, and confirm that the logger host really listens on UDP 514 withss -ulnp. - Only one server is red. Run steps 3 and 4 again on that server; each server needs its own
zmsyslogsetup. - Services really stopped. This is a real outage and not only a display problem. Use
zmcontrol status; a stopped service is a different problem from a wrong status page. - Firewall. Zimbra servers must reach UDP 514 on the logger host, otherwise the status messages never arrive.
FAQ
Why does a single-node Zimbra not show this error?
The guide says that the syslog steps for server statistics are not necessary for a single-node installation, because everything is logged on the same host. With several servers the messages must travel to the logger host.
Do the services restart when I run these commands?
Restarting crond and rsyslog does not restart Zimbra. Only zmcontrol restart does that.
Where can I read more?
See the guides on the zclient IO error and how to check Zimbra account status, and the Zimbra Administrator Guide sections on monitoring and the logger.
To clear the message Zimbra some services are not running on a multi server setup: restart cron and rsyslog, enable the UDP input, run zmsyslogsetup and zmupdateauthkeys, then check the Server Status page again.
Helpful Post
ReplyDeleteThanks
Thanks for reading my blog!
DeleteCảm ơn bác đã viết bài này. Bác đã cứu mấy ngày của em :D
ReplyDeleteCám ơn bạn đã đọc bài viết của mình :)
ReplyDeleteCảm ơn bác đã viết bài này. Bác đã cứu mấy ngày của em
ReplyDeletemy problem persist, i restart zimbra service but no fix error
ReplyDeleteSame problem after apply this solution Zimbra 8.8.15
ReplyDelete