Install latest/stable of logsearch
Ubuntu 16.04 or later?
Make sure snap support is enabled in your Desktop store.
This tool helps searching large numbers of files across multiple locations. It is particularly useful when looking for information in sosreports and can be run against multiple sosreports to get data across hosts.
Note that since this is a strictly confined snap the log files must be under $HOME
Install
sudo snap install logsearch
If you need to search a path on a remote file-system you will need:
sudo snap connect logsearch:removable-media
Examples
Basic search - all messages containing ERROR in /var/log/apache:
logsearch -d apache -k error mysosreports/
Or to look for errors in /var/log/syslog* (i.e. files not dir)
logsearch -f syslog -k error mysosreports/
Advanced search - all messages containing "2ae8d37" in /var/log/neutron and filtering out any debug or info level messages:
logsearch -d neutron -k 2ae8d37 -e 'DEBUG|INFO' mysosreports/
Generate an embeddable card to be shared on external websites.
Choose your Linux distribution to get detailed installation instructions. If yours is not shown, get more details on the installing snapd documentation.