• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

emailing access logs

A

akblackwel

Guest
This might be a logrotate question, but I thought I would start here. In my logrotate.conf it's set up to email the user after the log rotates.

blah blah blah
mail [email protected]
}


User's is not getting an email of the logs. I looked in the mail and the logrotate logs, but have found no hints as to why this might be happening. I don't necessarily need the answer, but an idea on where to look would also be helpful.
 
By default the code of the logrotate.conf is as follows:

include /usr/local/psa/etc/logrotate.d

/usr/local/psa/admin/logs/*_log {
weekly
rotate 12
missingok
notifempty
copytruncate
compress
}

if you want to e-mail this all you have to do is as follows:

include /usr/local/psa/etc/logrotate.d

/usr/local/psa/admin/logs/*_log {
weekly
rotate 12
missingok
notifempty
copytruncate
compress
mail [email protected]

}

If this does not works let me know what is present in your logrotate.conf so that I can tell you further.

Thanks.
Anand
 
This is what I already have.

/usr/local/psa/home/vhosts/somewhere.com/statistics/logs/*.processed {
daily
rotate 50
nocompress
missingok
mail [email protected]
}
/usr/local/psa/home/vhosts/somewhere.com/statistics/logs/error_log {
daily
rotate 50
nocompress
missingok
copytruncate
mail [email protected]
}
/usr/local/psa/home/vhosts/somewhere.com/statistics/logs/error_ssl_log {
daily
rotate 50
nocompress
missingok
copytruncate
mail [email protected]
}

This config is currently not working.

Kevin
 
Can you tell me ti chich mail address you are trying to send it?
Coz I think it will not send to any othe mail address other than the server, or try sending it to root@servername.

Telll me if it works, if it works then it indicates that the conf file is working fine.
Let me know what happens.


Thanks.
Anand
 
I know it a a user in a domain that's alreay on the server. If that helps.

Kevin
 
Try sending it to a E-Mail address of the domain which is present on the server, i think it might work

thanks.
Anand
 
Back
Top