Skip to main content
17-Peridot
July 22, 2014
Question

Log4j Log File Viewer

  • July 22, 2014
  • 2 replies
  • 7125 views

Hi there

What kind of log viewer do you use for programming and monitoring (without System Monitor) Windchill? I'm using LogExpert and I'm happy with it but I'm pretty sure, there are some better ones around.

One more question is, how do you open the methodserver logs? Because they contain the PID number after every Windchill restart, the log name changes. I know, that you can rename the log-files, but if you have multiple method servers, it's not recommended to redirect everything into one file.

Thanks for any tips

Björn

2 replies

12-Amethyst
July 22, 2014

A couple of suggestions:

  1. For a low-level file viewing approach, use wtcore/jsp/jmx/logFiles.jsp (Site -> Utilities -> Server Status -> Monitoring Tools -> Log File Viewer) to browse and search Windchill and Apache log files.
  2. For a higher-level log-event viewing approach, use wtcore/jsp/jmx/logEvents.jsp (SIte -> Utilities -> Server Status -> Monitoring Tools -> Persisted Log Events) to view (warning and error) log events which have been persisted to the database.
    • On a related note, one might check out wtcore/jsp/jmx/logEventsHistogram.jsp (SIte -> Utilities -> Server Status -> Monitoring Tools -> Log Event Histogram), which provides a summary of recent persisted log events by logger, severity, and exception type.

logFiles.jsp and logEvents.jsp both operate across cluster nodes and have existed since Windchill 10.0.

logEvents.jsp also contains links to search log files via logFiles.jsp. These links and other Monitoring Tools links (e.g. from logEventsHistogram.jsp to logEvents.jsp) were recently improved in 10.2 M020.

That's not to say not to use various log4j log viewers. There are some downsides to such viewers, though. For starters, you have to teach them about the PatternLayout used and they then have to parse the logs. Also, they don't necessarily understand following a directory of log files rather than single files with well known names. Finally, they don't understand Windchill clusters -- you have to explicitly configure for each node's log directory. You can get around these by introducing a SocketAppender to send events to a central location, but that's essentially how logEvents.jsp operates already (in conjunction with Windchill's AsyncJDBCAppender).

The persisted log events behind logEvents.jsp (and many of the other Monitoring Tools pages) are stored in non-modeled database tables and should be fairly easy to query.

12-Amethyst
July 22, 2014

P.S. There's also a Free Form SQL Query page on the Monitoring Tools page that you can configure to enable. There's an article on it somewhere floating around on the tech support site, I believe....

17-Peridot
November 14, 2014

Thanks for all the answers. I do start to like the "online" log file viewers. Unfortunately sometimes it would be easier to have the logfiles tailed open and see what that moment the output is.

Björn