Grep .gz files on linux
I was looking to a method to search a lot of .gz files through. It was some logfiles, you can use zgrep to do this.
zgrep ‘Search word’ /path/to/yours.gz
So I do this to search a lot of gz files through:
Zgrep ‘130.226.165.XXX’ /var/log/apache2/access*.gz
If you just want to cat a single gz file, you can use zcat.