Private Local mirrors
There are some situations in which it may be desiderable to set up a private mirror for distributing CVD updates.
If you run
ClamAV on many clients on your network, each installation will download a copy of new .cdiff files. This is a waste of bandwidth and resources for your network and for our mirrors network.
Sometimes the servers which perform the scan are not directly connected to Internet and can only download updates from a server in the same network segment.
For people who face these problems, we recommend using one of the following 3 setups.
Use an HTTP proxy
This solution is really easy to implement and is bandwidth efficient.
Install a proxy server (i.e. squid) and then tell your freshclam clients to use it. This can be done by setting the
HTTPProxyServer parameter in freshclam.conf (see man 5 freshclam.conf for the details).
Serve .cvd files from a local web server
This solution is really simple to implement but it's only effective if your clients are all on the same local network and bandwidth is not an issue for you.
Configure a local webserver on one of your machines (say machine1.mylan) and let freshclam download the *.cvd files from
http://database.clamav.net to the webserver’s
DocumentRoot.
Add this line to freshclam.conf on machine1.mylan:
ScriptedUpdates off
First the database will be downloaded to the local webserver and then the other clients on the network will update their copy of the database from it. For this to work you have to change freshclam.conf on your clients so that it reads:
DatabaseMirror machine1.mylan
ScriptedUpdates off
Serve .cvd+.cdiff files from a local web server
This solution is bandwidth efficient but it's a little bit trickier to set up and involves the use of custom scripts in place of freshclam.
Because of this, the scripts might need to be updated from time to time to cope with the corresponding changes in freshclam.
Configure a local webserver on one of your machines (say machine1.mylan) and use this script developed by Frederic Vanden Poel to download cvd+cdiff files into the
DocumentRoot:
First the cvd+cdiff files will be downloaded to the local webserver and then the other clients on the network will update their copy of the database from it. For this to work you have to change freshclam.conf on your clients so that it reads:
DatabaseMirror machine1.mylan
--
LucaGibelli - 2010-11-02