When trying to track an issue in log files on a live system, I find it handy to tail the logs. If the logs are being populated to quickly too find what I am looking for, I would pipe tail to grep and match on a pattern.
tail -f query.log | grep "thing I'm interested in" --color
Now you will see any new lines added to query.log that contain “thing I’m interested in” highlighted. Any other lines will be ignored.

There are times where I’m not exactly sure which logfile will be getting the output, so I’ll give tail wildcards or multiple files, and it’ll glob it and watch all the files on the command line. It can be very handy.
I’m getting ready to put out a large entry on logging on my blog, so if you’re interested in it, keep an eye out.
Good hint, thanks!
–Matt
Thanks for the tip. I’ll keep an eye on your feed.
Tony