Log Files#

This section contains information about log files in Carbonio and their location, and commands to manually retrieve information from them.

The processes related to Carbonio create files for the majority of its activities. However, to troubleshoot issues related to Carbonio, it is usually not needed to search each log files to find useful information, because the most relevant messages appear, as well, in many main log files, i.e., the standard Linux log files, like for example, syslog (which specifies the activities of the MTA), Logger, Authentication, and Directory. The log files location are the following

  • /opt/zextras/log/ stores log files produced by Carbonio core services

  • /var/log is the standard Linux directory where all daemons and services write their log file

  • /var/log/carbonio is used by some Carbonio Modules (e.g., Files, Docs) to write their log files

Java’s logging framework, log4j

Log files created by jetty services are managed by log4j, Java’s logging framework, which by default is configured to write its log messages to the local file system.

Logs created by log4j are rotated at 00:00 and compressed by a scheduled task.

In table Table 6, some of the most relevant log files are shown, along with their content and the service that creates them.

Table 6 List of Relevant Log Files#

Log File

Service

Content

/var/log/carbonio.log

syslog

MTA, LDAP, System

/opt/zextras/log/audit.log

log4j User and Admins authentication

/opt/zextras/log/clamd.log

ClamAV

ClamAV antivirus messages

/opt/zextras/log/freshclam.log

Freshclam

Freshclam (ClamAV signature updater) messages

/opt/zextras/log/mailbox.log

log4j

All mailbox activities

/opt/zextras/log/nginx.access.log

Nginx

Nginx access logs

/opt/zextras/log/zmmailboxd.out

Jetty

mailboxd daemon output

/var/log/carbonio/files

Carbonio Files

Messages from Carbonio Files

/var/log/carbonio/docs

Carbonio Docs

Messages from Carbonio Docs

/var/log/carbonio/docs-db-connector

Carbonio Docs-connector

Messages from Carbonio Docs-connector

/var/log/carbonio/preview

Carbonio Preview

Messages from Carbonio Preview

Searching Keywords in Log Files#

An important monitoring task is to watch log files messages and search for some keywords, especially during startup processes when all services are initialised and started.

Important among the log files mentioned in the section above, is the file /opt/zextras/log/mailbox.log, which contains a lot of information related to user actions. Therefore, searching for keywords can show limits reached by the system during the everyday usage. For example, the following snippet shows that the limit for SOAP session was reached:

[name=…...@example.com;mid=116;oip=88.32.89.34;port=40600;ua=CarbonioWebClient -
GC91 (Mac)/8.8.15_GA_4026;soapId=76fe42;] session - Too many SOAP
sessions (21 > 20), closing SoapSession{id=1335,
authAcct=02c4d68c-bbdc-42f8-8be8-84ba383406b7,
lastAccessed=2021-06-09 13:44:57,231}

You can search for these kind of limits in the Carbonio configuration using CLI commands, zmlocalconfig and carbonio prov.

Command zmlocalconfig

When using the command without arguments, the output will be the full configuration; a typical use of this command is to pipe the output for specific values, for example:

zextras$ zmlocalconfig | grep session

The output will include these parameters, while the actual values may differ:

zimbra_session_limit_admin = 5
zimbra_session_limit_imap = 15
zimbra_session_limit_soap = 20
zimbra_session_limit_sync = 5
zimbra_session_max_pending_notifications = 400
zimbra_session_timeout_soap = 600
Command carbonio prov

Also in this case, supplying no arguments, the output will be the full configuration. To retrieve specific values (e.g., the maximum number of threads for various services), you can use the following command to filter the full output

zextras$ carbonio prov gacf | grep -i threa | grep -i num

The output will be similar to:

CarbonioAdminImapImportNumThreads: 20
CarbonioHttpNumThreads: 250
CarbonioHttpSSLNumThreads: 50 (deprecated)
CarbonioImapNumThreads: 200
CarbonioLmtpNumThreads: 20
CarbonioMilterNumThreads: 100
CarbonioPop3NumThreads: 100
zimbraScheduledTaskNumThreads: 20

Modifying Configuration Values#

Warning

While modifying the Carbonio configuration is a simple task that in most cases requires only to run a CLI command, Please keep in mind that changing any parameter may hinder Carbonio performances and normal activity. Proceed with care!

To modify any of these values, you need to make sure that there are sufficient resources on the system. If the Carbonio system continuously uses all the available RAM Memory, it makes little sense to increase any of the limits in the previous limits! Indeed, before doing so, you need to add more RAM to the system, to allow for accommodating more sessions.

Provided system resources suffice, you can increase the values found in the outputs of the commands as follows.

Command zmlocalconfig

To modify any value, use command zmlocalconfig -e. For example, to raise the SOAP limit to 25, execute command

zextras$ zmlocalconfig -e zimbra_session_limit_soap=25

To change other parameters, remember to supply them in key=value format.

Command carbonio prov

To modify any value, use command carbonio prov mcf. The following command increases parameters zimbraImapNumThreads and CarbonioLmtpNumThreads to 400 and 50, respectively.

zextras$ carbonio prov mcf zimbraImapNumThreads 400 CarbonioLmtpNumThreads 50