Installing Anti-Virus on Linux (Ubuntu/Xubuntu)

Ok, I know what they say, you don’t need anti-virus protection on Linux. And that may be true. However, twice this past year, my wife and I have experienced fraudulent activity on one of our credit cards. The info was probably stolen from my wife’s Windows machine, or somehow stolen locally when we used one of our cards, but I’m installing anti-virus software just in case there’s some key logger or such stealing my numbers as I type them in when purchasing something on line.

There are a few options for anti-virus software for Linux1, but I chose to go with the completely free and open-source ClamAV. Here’s how to install it, along with the definitions (freshclam, which is not supported by canonical Ubuntu):

apt-get install clamav clamav-daemon clamav-freshclam clamav-unofficial-sigs

To install a GUI for it, type this in:

apt-get install clamtk

To have the definitions updated regularly, you’ll need to run ‘freshclam’. Or, set up a cron job as follows:

sudo crontab -e

If this is the first time you’ve edited a crontab, it will ask you which editor to use. Nano is the easiest (as it will tell you). I wanted my definitions to be updated daily at 8pm, so I added the following at the bottom of the file:

0 20 * * * freshclam >> /var/log/freshclam.log

The latter part will store the output in a log file every time it runs. Now keep in mind, it will only run if the machine is on. If you want to load new definitions everytime you boot up, I believe the following works if you add it instead to the crontab (haven’t tested it):

@reboot freshclam >> /var/log/freshclam.log


References:
1Malware and Antivirus Systems for Linux, linux.org

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: