Tag Archives: logrotate

Adding a hostname to Logrotate email subjects

I have logrotate running on my virtual servers ( both local and Amazon EC2 based ) and configured to send myself all log files by email daily. They are all running virtually the same configuration, and this makes it difficult to work out which log file is tied to which machine. The simplest way to fix this, is to ensure all logrotate emails append the hostname of the machine it is sending from within the subject of the email.

Continue reading