Zimbra ERROR zclient IO ERROR Tips to fix it

Are you experiencing Zimbra ERROR zclient IO ERROR?

Here is the solution.

Here at Ibmi Media, as part of our Server Management Services, we regularly help our Customers to fix Email related issues.

In this context, we shall look into the major causes of this error and how to get rid of it.

Nature of Zimbra ERROR zclient IO ERROR?

When this error occurs, you will get the following error message;

[] INFO: I/O exception (java.net.ConnectException) caught when processing request: Connection refused

[] INFO: Retrying request

ERROR: zclient.IO_ERROR (invoke Connection refused, server: localhost) (cause: java.net.ConnectException Connection refused)

In this cases, you cannot execute any Zimbra zmprov commands. This is frustrating since Zimbra Admin users use Zimbra CLI a lot.

More information about Zimbra zmprov?

The zmprov tool performs all provisioning tasks in Zimbra LDAP. It includes, creating accounts, aliases, domains, COS, distribution lists, and calendar resources.

Generally, each operation is invoked through the command-line options, each of which has a long name and a short name.

Cause of Zimbra ERROR zclient IO ERROR

The major cause of this error is when Zimbra zmprov is not configured to get results from LDAP. To fix this, we need to set zimbra_zmprov_default_to_ldap to TRUE.

This will make sure all the zmprov commands get replies from LDAP server.

How to fix Zimbra ERROR zclient IO ERROR?

To fix this error, follow the steps below;
1. Start by checking for the setting of zimbra_zmprov_default_to_ldap to be sure. To do this, execute;

zmlocalconfig |grep zmprov

zimbra_zmprov_default_soap_server = localhost
zimbra_zmprov_default_to_ldap = false
zmprov_safeguarded_attrs = zimbraServiceEnabled,zimbraServiceInstalled
zmprov_tmp_directory = ${zimbra_tmp_directory}/zmprov

2. If set to false, we reconfigure it to have the true flag. This will enable the setting by executing;

zmlocalconfig -e zimbra_zmprov_default_to_ldap=true

3, Then, recheck the settings by running;

zmlocalconfig |grep zmprov

zimbra_zmprov_default_soap_server = localhost
zimbra_zmprov_default_to_ldap = true
zmprov_safeguarded_attrs = zimbraServiceEnabled,zimbraServiceInstalled
zmprov_tmp_directory = ${zimbra_tmp_directory}/zmprov

4. Now we try to execute any zmprov commands and see if it is working fine. To do this, execute;

zmprov gs `zmhostname` | grep zimbraServiceEnabled

zimbraServiceEnabled: amavis
zimbraServiceEnabled: antivirus
zimbraServiceEnabled: antispam
zimbraServiceEnabled: opendkim
zimbraServiceEnabled: stats
zimbraServiceEnabled: logger
zimbraServiceEnabled: proxy
zimbraServiceEnabled: service
zimbraServiceEnabled: zimbra
zimbraServiceEnabled: zimbraAdmin
zimbraServiceEnabled: zimlet
zimbraServiceEnabled: mailbox
zimbraServiceEnabled: spell
zimbraServiceEnabled: ldap
zimbraServiceEnabled: memcached
zimbraServiceEnabled: mta
zimbraServiceEnabled: snmp
zimbraServiceEnabled: dnscache

5. If this does not solve the problem, we try changing the zimbra_zmprov_default_soap_server to the IP address of our Mailbox server.
The setting will look like this;

zmlocalconfig -e zimbra_zmprov_default_soap_server=ip-address

We have to execute the command using ‘zmprov -l’ instead of just ‘zmprov’ until mailboxd is running again. This will directly query the ldap server.

[Still having troubles with Zimbra ERROR zclient IO ERROR? We are ready to assist you today.]


This article will help to fix ERROR: zclient.IO_ERROR which can prevent us from executing any Zimbra zmprov commands.