Hub logs

The Hub writes its events to a log file ejh_server.log. This file is saved in the logs folder inside your Hub installation directory. Apart from ejh_server.log, wrapper.log is another log file present in the logs directory. The wrapper.log file logs any errors that were not logged in the Hub logs, including logs generated when the Hub Server is not running like before startup or after a crash.

These log files help you locate issues in the case of errors or when the Hub is behaving abnormally. Whenever logs are requested, always submit both log files to Evolphin Support.

It is possible to control the various log configurations by editing the file log4jConf.xml in the conf folder inside your Hub installation directory. By editing log4jConf.xml you can control:

  1. Log file’s directory and name – controlled by the tag <FileName>
  2. Rolling properties of log files
  3. The maximum number of archived log files
  4. Various log levels – controlled by tag <Root level>

In most cases, the default settings for logs will work for you. If you still need to change something, look at the sample log4jConf.xml to update these values:

<?xml version=”1.0″ encoding=”UTF-8″?>
<Configuration>
<Appenders>
<RollingFile name=”RollingFile”>
<FileName>../logs/ejh_server.log</FileName>
<FilePattern>../logs/ejh_server-%i.log</FilePattern>
<PatternLayout>
<Pattern>%d{yyyy-MMM-dd HH:mm:ss:SSS a} [%t] %-5level [%C{1}.%M] – %msg%n</Pattern>
</PatternLayout>
<Policies>
<SizeBasedTriggeringPolicy size=”5 MB”/>
</Policies>
<DefaultRolloverStrategy max=”20″/>
</RollingFile>
</Appenders>
<Loggers>
<Root level=”info”>
<AppenderRef ref=”RollingFile”/>
</Root>
<Logger name=”org.springframework” level=”WARN”>
<AppenderRef ref=”RollingFile”/>
</Logger>
<Logger name=”org.hibernate” level=”WARN”>
<AppenderRef ref=”RollingFile”/>
</Logger>
<Logger name=”org.apache.http.impl.conn.Wire.wire” level=”WARN”>
<AppenderRef ref=”RollingFile”/>
</Logger>
<Logger name=”org.apache.http.wire” level=”WARN”>
<AppenderRef ref=”RollingFile”/>
</Logger>
<Logger name=”org.apache.http.headers” level=”WARN”>
<AppenderRef ref=”RollingFile”/>
</Logger>
<Logger name=”org.apache.http.impl.conn” level=”WARN”>
<AppenderRef ref=”RollingFile”/>
</Logger>
</Loggers>
</Configuration>

These options are available:

  1. FileName: This is the log file name along with its path where the hub log will be saved. It is usually named as ejh_server.log. The file will be created on the specified path.
  2. SizeBasedTriggeringPolicy size: This is the file size limit for the log file specified above.
  3. FilePattern: This is the file name pattern along with the path where the archived logs are kept. When the default log file created above crosses the size limit specified, then the existing log file will be written to the file name with the pattern and path specified here and a new empty log file is created as the default log file. The %i in the file pattern is replaced with a number starting with 1 as new archived log files are created. The latest archived file always has number 0 and older ones are moved to have numbers 1, 2, 3 onwards.
  4. DefaultRolloverStrategy max: This defines the maximum number of archived log files that will be maintained. Once the archived log file numbers cross this value, the oldest file is deleted and the rest are moved to consecutive higher numbers in the log directory, so the total number of archived log files never exceeds this number.
    The size occupied by all archived log files = (DefaultRolloverStrategy max) multiplied by (SizeBasedTriggeringPolicy size) = 20 * 5Mb (max size above) = 100MB 
  5. Root level: This defines the log level to be reported in the log files. The values for log4j log levels are explained here.

After updating the desired values, save and close the file.

Restart the Hub service (check Starting and Stopping Zoom Services (Linux) or Starting and Stopping Zoom Services (Windows) to know more about restarting this service).

These log options are now saved.