Installation

Skip Navigation

Hierarchical Navigation

Previous and Next

Abstract

In this section, We explain how to install clamav-update. At First, we explain how to download source archives. Next we explain install steps by using install-script and its manual.

Download

Steps

You can download the Latest clamav-update from our clamav-update Project Page. Please visit that page.

  1. Go to the "Download" link of "clamav-update package" in "the Latest Release Information" Table.

    Go to release place of relevant package (= clamav-update) in the release file list page.

    Figure1. example of clamav-update 2.2.1
    Those are order in clamav-update 2.2.1 , Release Notes, Change Log, clamav-update-2.2.1.tar.gz, 25.4KB, 160, 2007-04-14 02:22, 19a4f677f447d14bc0f8fffe1b85b477
  2. Go to link of relevant file name (= clamav-update-2.2.1.tar.gz).

    Go to mirror server selection page

  3. You can select mirror server. Please select nearest server "Physical Place" from your machine. Go to "Download"

    You may see Download Icon or "download" character string.

    Now you can download it. If you cannot download it any more, Please follow notation of that page.

verification of files

If you can get archive of clamav-update, we recommend to verify that it's identical with original one. Because anyone can modify and redistribute clamav-update, you might get some another version of clamav-update with the same file name of ours. Especially, In cases that you got it from another ftp site. See Section "Warning of security" in Chapter "Execution" for that security

In order to verification of that archive, you need to go to the page of release file listagain. The Alphanumeric string in the line of relevant file name is the correct "checksum" (correctly MD5 hash value) . If you can get the same MD5 hash value from local file, both local and remote files are almost identical. To get MD5 hash value form local file, Use openssl command, like this;

openssl md5 Pathname of relevant file

If you have clamav-update-2.2.1.tar.gz in your Desktop directory

openssl md5 ~/Desktop/clamav-update-2.2.1.tar.gz

You can get follow results

MD5(Path name of the file)= 19a4f677f447d14bc0f8fffe1b85b477

This alphanumeric string "19a4f677f447d14bc0f8fffe1b85b477" is checksum. if it's equal to the checksum in the page of release file list, those are the same files.

But you go to download page to check correct checksum, you can download from that page. In case of some LAN environment such that FTP is limited, this step is meaningful. (Thus is also useful for checking whether download file is broken or not)

Install steps

In clamav-update package, we put on the install command. Please use it for install.

In ClamXav user case

If you use ClamXav on Mac OS X, you want to install ClamAV in /usr/local/clamXav/ for ClamXav, then you follow this steps to install it.

You must log in as administrator account to Mac OS X .

  1. double click downloaded the archive on Finder to expand it.

    a directory, has name as clamav-update-X.Y.Z, created.

  2. open the new directory and double click install.command file on Finder to execute it.

    Then some Terminal will be executed automatically for interactive installing ClamAV. First you can see the ClamAV mirror site list:

    Select ClamAV mirror site
    [1] Asia: Ishikawa, Japan
    [2] Asia: Tainan, Taiwan
    [3] Australia: Sydney, Australia
    [4] Europe: Brussels, Belgium
    [5] Europe: Lausanne, Switzerland
    [6] Europe: Bern, Switzerland
    [7] Europe: Duesseldorf, Germany
    [8] Europe: Berlin, Germany
    [9] Europe: Dublin, Ireland
    [10] Europe: Bologna, Italy
    [11] Europe: Amsterdam, The Netherlands
    [12] Europe: Kent, UK
    [13] North America: McLean, Virginia
    [14] North America: Seattle, Washington
    [15] North America: San Jose, CA
    [16] North America: Phoenix, AZ
    [17] South America: Curitiba, Brazil
    Input number and type enter key [1]: 
  3. Select mirror server site for ClamAVs downloading

    You can select number from 1 to 17. Please select the nearest mirror server number and them type number and hit enter. (default:1) If your machine is in Japan, hit enter only. After your selection, then you can see another selection list.

    Select clamav-update mirror site
    [1] Tokyo Japan: OSDN Japan
    [2] Osaka Japan: GLOBALBASE
    [3] Ishikawa Japan: Japan Advanced Institute of Science and Technology
    [4] Keihanna Japan: Kansai Science City Internet Community
    Input number and type enter key [1]: 
  4. Select mirror server site for clamav-update downloading

    You can select number from 1 to 4. Please select the nearest mirror server number and them type number and hit enter. (default:1) If you are out of Japan, select 1:Tokyo. So hit enter only. After you selection, it request Administrator password, Like this.

    Password:
  5. Input administrator's password and hit enter

    You are ready and installation is start actually. This install script use sudo command to get super user privilege to install it. In such case, sudo require administrator's password.

    If you input correct password , you can see following indication and installation has finished with your configuration. those details are depend on your environment and configuration.

    ---- Variables ----
    prefix: /usr/local/clamXav
    clamavPrefix: /usr/local/clamXav
    UsingClamd: 1
    ClamdRestartCommand: [qw(/Library/StartupItems/ClamAntiVirusDaemon/ClamAntiVirusDaemon restart)]
    UsingFreshclam: 1
    FreshclamRestartCommand: [qw(/Library/StartupItems/FreshClamDaemon/FreshClamDaemon restart)]
    ClamavDownloadFrom: http://jaist.dl.sourceforge.net/sourceforge/clamav
    DownloadFrom: http://osdn.dl.sourceforge.jp/clamav-update
    AdminGroup: admin
    
    ---- Execute ----
    install -bp -o root -g "admin" -m 0755 "./clamav-update.pl" "/usr/local/clamXav/bin/clamav-update.pl"
    install -bp -o root -g "admin" -m 0664 "/tmp/install.sh.QWFODH8C" "/usr/local/clamXav/etc/clamav-update.conf"
    install -bp -o root -g "admin" -m 0664 "./clamav-update-update.conf" "/usr/local/clamXav/etc/clamav-update-update.conf"

    Variables section represents parameter values for install. Execute section represents some commands contents to install. Last arguments in each Execute section represents installed files.

    installed files and their roles by install.command
    file role
    /usr/local/clamXav/bin/clamav-update.pl clamav-update main part:Perl script
    /usr/local/clamXav/etc/clamav-update.conf configuration file for ClamAV updating
    /usr/local/clamXav/etc/clamav-update-update.conf configuration file for clamav-update updating(fixed)
    /etc/clamav-update-update.conf configuration file for clamav-update updating(Environmental part)
    This file is optional

    This installer avoid to overwrite those configuration files and back up old files with suffix .old added to its file name.

  6. You must check clamav-update.conf and /etc/clamav-update-update.conf and customize if you need.

    Please open /usr/local/clamXav/etc/clamav-update.conf -- and /etc/clamav-update-update.conf if you have -- by textediter and check it. Those are configuration files of clamav-update. Please go to next section for its details.

In Other Case

If you use UNIX-like OS except Mac OS X or you want to install ClamAV to somewhere except /usr/local/clamXav/ then you use install.sh instead of install.command.

  1. expand the archive file.
    tar xfz clamav-update-version number.tar.gz
  2. go to the expanded directory
    cd clamav-update-version number
  3. read help of install.sh, select options and values.
    ./install.sh --help

    see detail of options ofinstall.sh in later section.

  4. switch user toroot.
    su
  5. execute install.shwith correct options and their values

    installed files are following.

    installed files and their roles by install.sh
    path name role
    {--prefix option's value}/bin/clamav-update.pl clamav-update main part Perl script
    {--prefix option's value}/etc/clamav-update.conf configuration file for ClamAV updating
    {--prefix option's value}/etc/clamav-update-update.conf configuration file for clamav-update updating (fixed)
    /etc/clamav-update-update.conf configuration file for clamav-update updating (Environment part)

    installer avoid overwrite those configuration files and back up old files as some suffix added. (environment dependence)

  6. check clamav-update.conf and /etc/clamav-update-update.conf and edit it if you need.

    Those 2 configuration files are text format. you can edit any textediter. We explain detail of those in next section.

manual of install.sh

SYNOPSIS

./install.sh [options]

./install.sh --help

./install.sh --version

DESCRIPTION

install.sh is an install script for clamav-update (Perl script) and configuration files for ClamAV update and clamav-update self-update. Those are customizable by parameters given by options Any user except root must not execute this install.sh .

--help show installer help and quit. those help messages are put in standard out.

--version show version of clamav-update that install.sh can install and quit. those version messages are put in standard out.

OPTIONS

--prefix=DIR

specify DIR as installation top directory of clamav-update . clamav-update.pl is installed in DIR/bin/. clamav-update.conf and clamav-update-update.conf are installed in DIR/etc/

default value is /usr/local.

--clamav-prefix=DIR

specify DIR as directory which ClamAV installed in. clamav-update require to search for clamav-config . this value affects environment variable PATH to find that command.

You'd better a directory path where ClamAVs prefix value when you installed clamav. If you can execute clamav-config, try following way if you use sh/bash.

./install.sh --clamav-prefix=`clamav-config --prefix` ...

default value is /usr/local

--clamd

specify clamd daemon is working.

--clamd-restart=COMMAND

specify COMMAND as re-starting command of clamd daemon. For COMMAND, 3 forms are available: strings,Perl reference to arrays, and Perl reference to function.

if COMMAND is strings or Perl reference to arrays, and when clamav-update re-start clamd daemon, execute them via system function of Perl. if COMMAND is Perl reference to function, when it restart that daemon, execute relevant function.

default value is [qw(/etc/rc.d/init.d/clamd restart)]

--freshclam

specify freshclam as daemon is working

--freshclam-restart=COMMAND

specify COMMAND as re-starting command offreshclam. For COMMAND, 3 forms are available : strings, Perl reference to arrays, and Perl reference to function.

if COMMAND is strings or Perl reference to arrays, and when clamav-update re-start freshclam daemon, execute them via system function of Perl. if COMMAND is Perl reference to function, when it restart that daemon, execute relevant function.

default value is [qw(/etc/rc.d/init.d/freshclam restart)]

--download-from=URL

specify URL as URL of mirror server for clamav-update

at present, 4 bellow values are available.

http://osdn.dl.sourceforge.jp/clamav-update
Mirror server in Tokyo,Japan managed by OSDN
http://globalbase.dl.sourceforge.jp/clamav-update
Mirror server in Osaka, Japan managed by GLOBALBASE
http://jaist.dl.sourceforge.jp/clamav-update
Mirror server in Ishikawa, Japan managed by Japan Advanced Institute of Science and Technology
http://keihanna.dl.sourceforge.jp/clamav-update
Mirror server in Kyoto, Japan managed by Kansai Science City Internet Community

default value is http://osdn.dl.sourceforge.jp/clamav-update

--clamav-download-from=URL

specify URL as URL of mirror server for ClamAV

at present, 17 bellow values are available.

http://jaist.dl.sourceforge.net/sourceforge/clamav
Mirror server in Asia, Japan, Ishikawa
http://nchc.dl.sourceforge.net/sourceforge/clamav
Mirror server in Asia, Taiwan, Tainan
http://optusnet.dl.sourceforge.net/sourceforge/clamav
Mirror server in Australia, Sydney
http://belnet.dl.sourceforge.net/sourceforge/clamav
Mirror server in Europe, Belgium, Brussels
http://switch.dl.sourceforge.net/sourceforge/clamav
Mirror server in Europe, Switzerland, Lausanne
http://puzzle.dl.sourceforge.net/sourceforge/clamav
Mirror server in Europe, Switzerland, Bern
http://mesh.dl.sourceforge.net/sourceforge/clamav
Mirror server in Europe, Germany, Dusseldorf
http://dfn.dl.sourceforge.net/sourceforge/clamav
Mirror server in Europe, Germany, Berlin
http://heanet.dl.sourceforge.net/sourceforge/clamav
Mirror server in Europe, Ireland, Dublin
http://garr.dl.sourceforge.net/sourceforge/clamav
Mirror server in Europe, Italy, Bologna
http://surfnet.dl.sourceforge.net/sourceforge/clamav
Mirror server in Europe, Holland, Amsterdam
http://kent.dl.sourceforge.net/sourceforge/clamav
Mirror server in Europe, Great Britain, Kent
http://superb-east.dl.sourceforge.net/sourceforge/clamav
Mirror server in North America, Virginia, McLain
http://superb-west.dl.sourceforge.net/sourceforge/clamav
Mirror server in North America, Washington, Seattle
http://internap.dl.sourceforge.net/sourceforge/clamav
Mirror server in North America, CA, San Jose
http://easynews.dl.sourceforge.net/sourceforge/clamav
Mirror server in North America, AZ, Phoenix
http://ufpr.dl.sourceforge.net/sourceforge/clamav
Mirror server in South America, Brazil, Curitiba

default value is http://jaist.dl.sourceforge.net/sourceforge/clamav .

--admin-group=NAME

Specify NAME as UNIX group name. this value use for clamav-update.pl and other configuration file's group name.

default value is root

--verbose

Execute verbose mode

--help

show help and quit.

--version

show version of install-target (=clamav-update.pl) and quit

EXAMPLE

In case of just ClamAV installing from source code without configuration and use in Tokyo, Japan
./install.sh
In case of ClamAV installing from source code and use freshclam in /etc/rc.d/init.d/freshclam and in Tokyo Japan
./install.sh --freshclam
In case of ClamAV installing from source code in Germany.
./install.sh --clamav-download-from=http://mesh.dl.sourceforge.net/sourceforge/clamav
In case of ClamAV installing from RPM on Fedora Core 6 , using clamd via amavisd in Tokyo Japan
./install.sh --clamav-prefix=/usr --clamd --clamd-restart='[qw(/etc/rc.d/init.d/clamd.amavisd restart)]' --freshclam