We've moved to a new support system!

The Nagios Answer Hub is a place where you can get help with technical questions from our experts. There, you can quickly open tickets and join discussion boards.

Request Nagios Answer Hub access here: https://info.nagios.com/answer-hub-access-new-users

After completing the access form, you will be given access to a portal where new tickets can be created. We will keep the old customer forum sections and ticket system available for current cases to be resolved.

Go to the Answer Hub

Grok pattern Nxlog configuration wildfly

Engage with the community of users including those using the open source solutions.
Includes Nagios Core, Plugins, and NCPA

Grok pattern Nxlog configuration wildfly

Postby vedat.matzir@hays.de » Thu Jul 07, 2022 5:26 am

Hi community,
currently we are facing the issue to find a grok pattern for wildfly logs when there as a multiline entry like a stacktrace:

Example log entry:
2022-07-07 00:00:10,662 +0200 ERROR [EJB default - 5][or.jb.as.ej.timer:183] WFLYEJB0020: Error invoking timeout for timer: [id=xxxxxxxxxxxxxxxxxxxxxxxxxxxx timedObjectId=test-service-impl-2022.5.0.test-service-impl-2022.5.0.HomepageJobSchedulers auto-timer?:false persistent?:true timerService=org.jboss.as.ejb3.timerservice.TimerServiceImpl@586ssfsf previousRun=Wed Jul 06 20:00:00 CEST 2022 initialExpiration=null intervalDuration(in milli sec)=0 nextExpiration=Thu Jul 07 04:00:00 CEST 2022 timerState=IN_TIMEOUT info=de.scheduler.scheduled.homepage.jobassets.HomepageJobSchedulers] ScheduleExpression [second=0;minute=0;hour=*/4;dayOfMonth=*;month=*;dayOfWeek=1-5;year=*;timezoneID=null;start=null;end=null]: javax.ejb.EJBException: WFLYEJB0442: Unexpected Error
at org.jboss.as.ejb3.tx.CMTTxInterceptor.invokeInOurTx(CMTTxInterceptor.java:271)
at org.jboss.as.ejb3.tx.CMTTxInterceptor.required(CMTTxInterceptor.java:388)
Caused by: java.lang.NoClassDefFoundError: org/jsoup/Jsoup
.......

With online Grok debugger this: %{TIMESTAMP_ISO8601} %{ISO8601_TIMEZONE} %{LOGLEVEL} %{GREEDYDATA} is working fine, but when we insert the same pattern in nxlog configuration file it does not work.

Configuration to send to Nagios Logserver in Json:
<Input in>
Module im_file
File '%WILDFLY_LOG_DIR%\\server2.log'
<Exec>
log_debug($raw_event);
if match_grok($Message, "%{TEST_LOG}")
{
to_json();
}
else
{
log_info('Event did not match any pattern');
}
</Exec>
</Input>

Any help or ideas would be fine :D


Kind regards,
Vedat
vedat.matzir@hays.de
 
Posts: 1
Joined: Thu Jul 07, 2022 3:24 am

Return to Community Support

Who is online

Users browsing this forum: No registered users and 17 guests