How to simplify massive numbers of log files
How do you simplify ROS's logging system so it doesn't generate a massive number of log files?
I'm trying to diagnose a problem with a specific node crashing upon launch. So, the first thing I want to check is its logging output. Sounds simple, right? Unfortunately, it's quite a headache. I went to the default log directory in ~/.ros/log
and I see:
What in the world is this? I have, maybe, 6 nodes running. Why are so many log files necessary? Where do I begin to find the one containing output from my node?
If this is the default, how do I override this so either:
- everything goes to a single easily searchable log file?
- name the log files by the name of the node that writes to them, instead of some meaningless UUID?
Cut-and-paste text instead of screenshots of text is a lot easier to read and analyze.
You want me to cut and paste the
ls
output showing the thousands of random log file names? How would that help you? Normally I'd agree that copy and paste is better, but not in this instance.Just capture about a screens worth of output, it could be exactly what is in the existing image except text, or less since it will be a bit bigger due to font size. A
...
at the end could be added to say there is more output that has been excluded.Just an observation: from the screenshot it appears that someone/something is invoking
rosservice
(the command line utility) about every 7 or 8 seconds. As @mig already explained, each invocation will result in a log file. That would seem to be the primary cause of the many log files.