Send server logs to Syslog server
How to configure the server.xml to send log messages to a Syslog server.
The configuration file is stored in cscs/app/config/server.$CSS_ID.xml.
Syslog sample from server.xml
<!-- syslog sample, available since 2014-04-14, censhare 4.7.26, 4.8.7, 4.9.2 -->
<!-- handler@formatter defaults to "com.censhare.support.util.logging.SimpleFormatter" -->
<!-- handler@level defaults to "INFO" -->
<!-- handler@facility for a list of possible values see https://tools.ietf.org/html/rfc3164, default = 1 (user-level messages) -->
<!--
<handler
type="custom"
level="ALL"
class="com.censhare.support.util.logging.SyslogHandler"
hostname="lxsrv.censhare.de"
facility="1"
>
<logger name=""/>
</handler>
Configure server.xml
- Uncomment the sample lines from
<handler
to</handler>
. - Set the hostname property to your Syslog server.
- Restart the censhare Server to activate the changes.
Properties
level - log level
hostname - Syslog destination server
Result
Server logs are sent to the Syslog server.