Koozali.org: home of the SME Server

receive an e-mail as CLAM updates himself

Offline Jáder

  • *
  • 1,099
  • +0/-0
    • LinuxFacil
receive an e-mail as CLAM updates himself
« on: August 18, 2016, 08:16:06 PM »
I´d like to receive an e-mail anytime the clam updates himself... but on another account not in root!

There are some DB VARIABLE to change or should I change some file ?

Thanks

Jáder

EDIT: I just found "/sbin/e-smith/freshclam-update-ok"   should I change it  and cron to each 4/6/8 hours ?
« Last Edit: August 18, 2016, 08:32:46 PM by jader »
...

Offline Stefano

  • *
  • 10,894
  • +3/-0
Re: receive an e-mail as CLAM updates himself
« Reply #1 on: August 18, 2016, 09:10:24 PM »
Just a question: why?

Offline Jáder

  • *
  • 1,099
  • +0/-0
    • LinuxFacil
Re: receive an e-mail as CLAM updates himself
« Reply #2 on: August 19, 2016, 12:19:29 AM »
The client is a financial  institution subject to some compliance rules...one of them is to show updated AV SW on server.
It´s easier to prove showing an e-mail than capture a screen each day.
...

Offline Fumetto

  • *
  • 899
  • +1/-0
Re: receive an e-mail as CLAM updates himself
« Reply #3 on: August 19, 2016, 12:55:37 AM »
smeserver-mailsorting on admin account can be a good solution.

Offline Knuddi

  • *
  • 540
  • +0/-0
    • http://www.scanmailx.com
Re: receive an e-mail as CLAM updates himself
« Reply #4 on: September 02, 2016, 07:16:10 PM »
You can also make a simple cronjob that mails you the output of "freshclam -V" - right now "ClamAV 0.99.2/22173/Fri Sep  2 17:27:58 2016" in my setup

basically as bash script
/usr/bin/freshclam -V | mail yourname@domain.com -s "ClamDB status"


Or more "complex" - change the file /sbin/e-smith/freshclam-update-ok to do the same or uncomment the content and change "admin" to the right user.
« Last Edit: September 02, 2016, 07:20:04 PM by Knuddi »

Offline Jáder

  • *
  • 1,099
  • +0/-0
    • LinuxFacil
Re: receive an e-mail as CLAM updates himself
« Reply #5 on: September 06, 2016, 06:00:47 PM »
Knuddi,

That´s a cleaner solution... It´s easier to final user to read a date only.
I´ve implemented your tip on  /sbin/e-smith/freshclam-update-ok file.
...