wiki.ipfire.org

The community-maintained documentation platform of IPFire

User Tools

Site Tools


configuration:network:update-booster

Update Accelerator

Imagine this situation: Microsoft has just released another “patch Tuesday” update, the virus scan software has to be updated and Adobe and Symantec are releasing new updates at the same time. You have multiple systems to update and they all need to download the same files.

The Update Accelerator has been created especially for this type of scenario. It has been developed for networks with multiple clients. The Update Accelerator caches, similar to the Proxy server updates for the Operating System, Virus scanners and the like. The load on the Internet connection is reduced and it also prevents long waiting times when loading updates to multiple clients.

Important Unlike to the standard 'squid' proxy, Update Accelerator saves and caches whole files only. Therefore the first access to a file starts two downloads. The first by the client and the second by Update Accelerator.

Definitions

Update Accelerator process

This program is the 'heart' of the module.
It is implemented as a rewriter for Squid ( the proxy ). Each URL processed by Squid is sent to the rewriter chain ( URLFilter, Update Accelerator, Squid Clamav ) first. A rewriter decides, whether the URL is related to its task and probably changes the URL.
In case of Update Accelerator the URL is matched against the regular expressions describing the download links for the files managed.
If a match is found, the stored file is checked against the file to be downloaded. If the file in the repository is up-to-date, the URL is changed to a link to the repository. Otherwise the requesting URL isn't changed, but a download process is started in parallell.

Vendor

Also called Source. This name describes the source for the update. Examples are Microsoft ( commonly used for Windows updates ), Avira, AVG ( antivir software ), Mozilla ( Firefox, Thunderbird ). Vendor names start with an uppercase letter. Vendors are defined by the Update Accelerator process ( see 'Extensions' below ).

Update Cache ( Repository )

Disk space for storage of the cached files. The path is /var/updatecache. This directory consists of subdirectories for each vendor. The vendor directories contain subdirectories for each cached file, identified by a UUID for fast access. These (sub)directories also contain meta-data ( access time, source URL, … ) for the cached files.

Performance Characteristic

  • smaller waiting times for updates (full LAN-speed)
  • user defined configuration
  • overview of all the files in cache
  • permanently growing list of supported apps
  • low CPU load (configurable)

In the default settings, the Update Accelerator has to be activated in the Webproxy page. The Accelerator itself is pre-configured and normally doesn't need any change. Only when there is little disk space (less than 5GB) available, should the settings have to be changed.

A configuration example:


Parameters:

  • Enable passive mode … When this is enabled Update Accelerator doesn't download new files to the repository. Only files already in the repository are delivered. (Do not enable this when first using Update Accelerator)
  • Max. disk usage … Update Accelerator doesn't add files, if the usage of the file system holding the repository exceeds this number.

And a cache filled with updates:

The Cache-Statistic shows exact information of the used disk space and the number and sizes of the files.

Extensions

Here you can find some more extensions for miscellaneous software updates. All extensions needs to adjust to “updxlrator” which you can found in “/usr/sbin/“. Further it is necessary to store .gif files for display by the WUI in ”/src/web/ipfire/html/images/updbooster”.
These files must be named 'updxl-src-<vendor>.gif', where <vendor> is the vendor name in lowercase.

Update Accelerator is currently rewritten. ( see https://forum.ipfire.org/viewtopic.php?f=50&t=12984 ). This new version includes separate vendor definitions.


Norman Antivirus:

File:/usr/sbin/updxlrator
         # -------------------------------------------------------------------------------
	 # Section: Norman Downloads (mehr Erweiterungen unter www.csg-pc.de/updatebooster )
	 # -------------------------------------------------------------------------------
 
	 if ($source_url =~ m@^[f|h]t?tp://normanasa.vo.llnwd.net/.*/.*\.(NSA)$@i)
	 {
         $xlrator_url = &check_cache($source_url,$hostaddr,$username,"Norman",$mirror);
	 }

Nero Software:

File:/usr/sbin/updxlrator
	# -----------------------------------------------------------------------------
	# Section: Nero Downloads (mehr Erweiterungen unter www.csg-pc.de/updatebooster )
	# -----------------------------------------------------------------------------
 
	 if ($source_url =~ m@^http://.*\.nero\.com/.*\.(7z|exe|msi|zip)$@i)
	 {
         $xlrator_url = &check_cache($source_url,$hostaddr,$username,"Nero",$mirror);
	 }

intel Software:

File:/usr/sbin/updxlrator
	# ------------------------------------------------------------------------------
	# Section: Intel Downloads (mehr Erweiterungen unter www.csg-pc.de/updatebooster )
	# ------------------------------------------------------------------------------
 
	 if ($source_url =~ m@^http://.*\.intel\.com/.*\.(7z|exe|msi|zip)$@i)
	 {
         $xlrator_url = &check_cache($source_url,$hostaddr,$username,"Intel",$mirror);
	 }

AVAST Downloads:

File:/usr/sbin/updxlrator
         # ----------------------------------------------------------- 
         # Section: Avast Downloads 
         # -----------------------------------------------------------  
 
         if ($dsturl =~ m@^http://download[0-99]\.avast\.com/.*\.(exe|zip|vps|stamp|vpu)$@i) 
         { 
         $from_local_cache = &cache_access($dsturl,$hostaddr,$username,"Avast"); 
         } 

Linux Updates:

File:/usr/sbin/updxlrator
        # -----------------------------------------------------------
        #  Section: Linux Downloads
        # -----------------------------------------------------------
 
        if ($source_url =~ m@^[h|f]t?tp://[^?]+\.(tar.gz|tar.gz|tar.bz2|tgz|bz|gz2|run|deb|rpm)$@i)
        {
        $xlrator_url = &check_cache($source_url,$hostaddr,$username,"Linux",$mirror);
        }

ESET NOD32 - Antivirus Updates:

Datei:/usr/sbin/updxlrator
	# ------------------------------------------------------------------------------
	# Section: ESET Downloads (for Logo and Extensions PM @firefant | 10.05.2014)
	# ------------------------------------------------------------------------------
 
	 if ($source_url =~ m@^http://(um01|um02|um03|um04|um05|um06|um21|um23|update|download)\.eset\.com/.*\.(ver|exe|msi|nup|cab)$@i)
	 {
         $xlrator_url = &check_cache($source_url,$hostaddr,$username,"Eset",$mirror);
	 }
configuration/network/update-booster.txt · Last modified: 2018/09/23 21:22 by Jon