Version 18 (modified by JoelSherrill, on 11/23/10 at 01:06:26) (diff) |
---|
LoggingTools
Table of Contents
Introduction
When creating, testing, and running RTEMS appplications, many developers use the printf family of functions to log information. For large applications, viewing logs is a pain. Logs are often cluttered, making it difficult to find the information that you need. This page suggests some uses for logging information and describes open source tools that can be used to view and manage logs.
Common Uses for Logging
- Debugging embedded applications
- Offline tuning of PID (or arbitrary) control loops
- Real time monitoring and/or maintenance of embedded systems
- Optimizing applications by profiling them, analyzing performance, and identifying possible speed improvements
Open Source Logging Tools
All of these tools work out of the box with generic log files. Please note that many of them cannot run on RTEMS itself. You'll need to connect your RTEMS system to another computer for analysis.
- Tuning and Analysis Utilities (TAU) - TAU is the recommended tool for application profiling. TAU is a set of libraries and tools for profiling and analyzing applications. Events can be logged manually or automatically with Fortran, C++, C, Java, and Python. It provides a variety of tools for analysis, visualization, and data-mining. Former QNX users will find that TAU is a viable alternative to QNX's Application Profiler.
- RRDTool - RRDTool is the recommended tool for graphing time-series data. RRDTool is a library for writing custom monitoring tools. It can easily create custom graphs with your data. If you don't want to write any code, there are a multitude of RRDTool-based programs which can parse and graph your logs automatically.
- Log2Timeline - Log2Timeline is the recommended tool for creating stunning and interactive visualizations of simple logs. Log2Timeline converts log files to "timeline body files," which can be viewed with tools like Simile Timeline and Simile Timeplot.
- Octopussy - Octopussy is a web-based server for log monitoring. It supports live monitoring, events filtering, and email alerts. Octopussy is usually used to monitor Apache and the like, however it can be customized to analyze any type of log file. See here for information on setting up Octopussy - you'll have to dump RTEMS logs into /var/lib/octopussy/logs/<device_name>/Incoming/
Statistical Analysis
For more complex event analysis, you may want to consider Mathematica, R, or Sage.
Notes
This page was written as part of the Google Code-In 2010 contest. Please see http://www.google-melange.com/gci/task/show/google/gci2010/rtems/t129018536044 for more information.