AppSuite:Syslog Configuration

Revision as of 15:25, 15 February 2013 by Usman.ahmad (talk | contribs) (rsyslod)

Open-Xchange Syslog Configuration

Abstract

Open-Xchange provides OSGi packages (open-xchange-log4j and open-xchange-commons-logging-log4j) to enable remote logging via syslog. This is useful for distributed setups or if a logging strategy is already present at the environments the servers are running. If you choose syslog to be the logging mechanism, the syslog service needs some configuration to accept remote logging, even if the service is running on localhost.

The syslog remote logging will open port 514/udp, so don't forget to firewall it properly if it's a security risk for you. The default logging facility of Open-Xchange is defined at the /opt/open-xchange/{groupware,admindaemon}/etc/log4j.xml file. For more granular log filtering this facility can be changed. Please refer to the syslog and syslog-ng documentation for further information.

Install on OX App Suite

Debian GNU/Linux 10.0

Add the following entry to /etc/apt/sources.list.d/open-xchange.list if not already present:

deb https://software.open-xchange.com/products/appsuite/stable/backend/DebianBuster/ /
# if you have a valid maintenance subscription, please uncomment the 
# following and add the ldb account data to the url so that the most recent
# packages get installed
# deb https://[CUSTOMERID:PASSWORD]@software.open-xchange.com/products/appsuite/stable/backend/updates/DebianBuster/ /

and run

$ apt-get update
$ apt-get install open-xchange-log4j

Debian GNU/Linux 11.0

Add the following entry to /etc/apt/sources.list.d/open-xchange.list if not already present:

deb https://software.open-xchange.com/products/appsuite/stable/backend/DebianBullseye/ /
# if you have a valid maintenance subscription, please uncomment the 
# following and add the ldb account data to the url so that the most recent
# packages get installed
# deb https://[CUSTOMERID:PASSWORD]@software.open-xchange.com/products/appsuite/stable/backend/updates/DebianBullseye/ /

and run

$ apt-get update
$ apt-get install open-xchange-log4j


Configuration

Please note, there are numerous syslog daemons available and the configuration may also differ between Linux distributions. To make open-xchange-log4j running in collaboration with the syslog daemon of your choice, you have to enable logging via UDP protocol and listening port 514. Please read for details the documentation of your running syslog service.

rsyslod

Here documentation steps for the popular rsyslod. The parameter configuration is now completely done at a configuration file at /etc/rsyslog.conf

# provides UDP syslog reception
$ModLoad imudp
$UDPServerRun 514

Then restart the rsyslog service to enable remote logging.

$ /etc/init.d/rsyslog restart

By default, all Open-Xchange log messages are put to /var/log/syslog.

SUSE Linux Enterprise Server 11

SLES11 comes with syslog-ng, modify the configuration at /etc/syslog-ng/syslog-ng.conf:

source src {
       #
       # include internal syslog-ng messages
       # note: the internal() soure is required!
       #
       internal();

       #
       # the default log socket for local logging:
       #
       unix-dgram("/dev/log");

       #
       # uncomment to process log messages from network:
       #
       udp(ip("0.0.0.0") port(514));
};

Uncomment the last statement of the src definition and restart the syslog service to enable logging.

$ /etc/init.d/syslog restart

By default, all Open-Xchange log messages are put to /var/log/messages.