For the log files in /var/log
,
it appears that the wtmp
and also the rotated wtmp.n
are not ASCII file and can only be read by the last
command, so if they are compressed, one has to first uncompress them and then use last -f ...
to read. The other compressed log files can be easily read using an editor such as emacs since they are ASCII text files.
Is there a way to set "compress" for all other logs files except the wtmp.n?
(I assume that if one uncomments the #compress
in the /etc/logrotate.conf
,
# uncomment this if you want your log files compressed
#compress
then all log files will be compressed, including the wtmp
.)
Thanks