<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- Start of avast.htm --><!-- delayed after doctype-->
<html>
<head>
<link rel="stylesheet" type="text/css" href="../../css2/netwin.css">
	<script type="text/javascript" src="template/js2/netwin.js"></script>
<!--
	<script type="text/javascript" src="template/js2/dbg.js"></script>
-->

<!--
	<link rel="stylesheet" type="text/css" href="template/css2/netwin.css">

	<link rel="stylesheet" type="text/css" href="template/css2/test.css">
	<link rel="stylesheet" type="text/css" href="template/css2/sw.css">
	<link id ="cnr_css" rel="stylesheet" type="text/css" href="template/css2/cnr4.css">
-->

<!--[if lt IE 7]>
	<link rel="stylesheet" href="template/css2/ie6.css" type="text/css" />
<![endif]-->


<!-- Back to avast.htm -->

<!-- #BeginEditable "Headerstuff"-->
<title>Avast Antivirus</title>
<META NAME="keywords" CONTENT="">
<META NAME="description" CONTENT="">
<meta http-equiv="Content-Type" content="text/html;">


<!-- #EndEditable -->
</head>
<body class="s_body">


<div id="width_limit_div" class="width_limit" style="padding-bottom:0;">

<!-- HEADER CONTENT -->
<div class="header">
  <div class="search_box"><table valign="center" cellSpacing="0" cellPadding="0" border="0">
	<form id="form1" name="form1" method="GET" action="http://www.google.com/custom">

	  <input type=hidden name=domains id=search_domains value="netwinsite.com">
	  <input type=hidden name=sitesearch id=search_sitesearch value="netwinsite.com">
	  <input type=hidden name=cof VALUE="LW:135;L:http://www.netwinsite.com/img2/logo_med_onwhite.png;LH:44;AH:center;S:http://www.netwinsite.com;AWFID:773914251fd85055;">

	  <tr valign="center">
		<td valign="center" style="padding-right:5px;"><span id="search_description" style="font-family:Verdana,Arial,Helvetica; font-size:9pt; ">Search website:</span>
		</td>
		<td valign="center">
			<input size="15" maxLength="80" name="q" style="font-family: Tahoma, Arial; font-size: 8pt">
		</td>
		<td valign="center">
			<input TYPE="image" src="template/img2/search.gif" alt="Search Netwinsite.com!" Name="I1" style="width:17px;height:17px;margin-left:5px;border:0;">
		</td>
	  </tr>
	</form>
  </table></div>

  <div class="page_logo"><table valign="center" border="0" cellpadding="0" cellspacing="10" >
	  <tr>
		<td style="padding-left:20px;">
		  <a href=""><img border="0" src="template/img2/logo_med_onwhite.png" height="44px" vspace="5" id="main_logo"> </a>
		</td>
		<td>
		  <div style="padding-top:14px;">
			<span class="s_header_text">Advanced Server Software<span>
		  </div>
		</td>
	  </tr>
  </table></div>
</div>

<!-- MENU CONTENT -->
<div class="bar_padding" onmousemove="stopEvent(event);return false;">
	<div class="bar" style="text-align:center">
		<table id="page_menu" class="t menu" onmousemove="menu_handler(event);" style="margin:auto"><tr>
	<td valign=top><table class="top_item" mid="menu_home"><tr><td class="btn_l"><td class="btn_c"><a href="http://netwinsite.com/index.htm" class="pad">Home</a><td class="btn_r"></table>
	<td valign=top><table class="top_item" mid="menu_products"><tr><td class="btn_l"><td class="btn_c"><a href="http://netwinsite.com/products.htm" class="pad">Products</a><td class="btn_r"></table>
	<td valign=top><table class="top_item" mid="menu_download"><tr><td class="btn_l"><td class="btn_c"><a href="http://netwinsite.com/download.htm" class="pad">Download</a><td class="btn_r"></table>
	<td valign=top><table class="top_item" mid="menu_buy"><tr><td class="btn_l"><td class="btn_c"><a href="http://netwinsite.com/prices.htm" class="pad">Buy&nbsp;Now</a><td class="btn_r"></table>
	<td valign=top><table class="top_item" mid="menu_support"><tr><td class="btn_l"><td class="btn_c"><a href="http://netwinsite.com/support.htm" onmouseup="x()" class="pad">Support</a><td class="btn_r"></table>
	<td valign=top><table class="top_item" mid="menu_company"><tr><td class="btn_l"><td class="btn_c"><a href="http://netwinsite.com/company.htm" onmouseup="x()" class="pad">Company</a><td class="btn_r"></table>
		</table>
	</div>

	<div id="menu_home" class="xmenu hidden" onmouseup="menu_hide_ex(event,'menu_home')" onmouseout="menu_action_mouseout(event,'menu_home')" onmouseover="menu_action_mouseover(event,'menu_home')" style="width:220px; display:none;">
	</div>

	<div id="menu_products" class="xmenu hidden" onmouseup="menu_hide_ex(event,'menu_products')" onmouseout="menu_action_mouseout(event,'menu_products')" onmouseover="menu_action_mouseover(event,'menu_products')" style="width:220px;">
		<a href="http://netwinsite.com/surgemail/" class="menu_row pad2"><div class="menu_icon_surgemail"></div>
			SurgeMail<span class="menu_extra"></span><br><span class="menu_info">Fully featured email server </span></a>
		<a href="http://netwinsite.com/surgeftp/" onmouseup="x()" class="menu_row pad2 divider"><div class="menu_icon_surgeftp"></div>
			SurgeFTP<span class="menu_extra"></span><br><span class="menu_info">High performance FTP server </span></a>
		<a href="http://netwinsite.com/dbabble/index.html" onmouseup="x()" class="menu_row pad2"><div class="menu_icon_dbabble"></div>
			DBabble <span class="menu_extra"></span><br><span class="menu_info">Instant messenging server </span></a>
		<a href="http://netwinsite.com/surgeweb/" onmouseup="x()" class="menu_row pad2 divider"><div class="menu_icon_surgeweb"></div>
			SurgeWeb<br><span class="menu_info">Modern Ajax web email client</span></a>
		<a href="http://netwinsite.com/products.htm" onmouseup="x()" class="menu_row divider">
			All products...</a>
	</div>

	<div id="menu_download" class="xmenu hidden" onmouseup="menu_hide_ex(event,'menu_download')" onmouseout="menu_action_mouseout(event,'menu_download')" onmouseover="menu_action_mouseover(event,'menu_download')" style="width:220px">
		<a href="/cgi-bin/keycgi.exe?cmd=download&product=surgemail&" onmouseup="x()" class="menu_row"><div class="menu_icon_surgemail"></div>
			Surgemail<span class="menu_extra"></span></a>
		<a href="/cgi-bin/keycgi.exe?cmd=download&product=surgeftp&" onmouseup="x()" class="menu_row"><div class="menu_icon_surgeftp"></div>
			SurgeFTP<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/dbabble/download.htm" onmouseup="x()" class="menu_row"><div class="menu_icon_dbabble"></div>
			DBabble <span class="menu_extra"></span></a>
		<a href="/cgi-bin/keycgi.exe?cmd=download&product=surgemail&" onmouseup="x()" class="menu_row divider"><div class="menu_icon_surgeweb"></div>
			SurgeWeb</a>
		<a href="http://netwinsite.com/surgemail/help/install.htm" onmouseup="x()" class="menu_row">
			Installing Surgemail</a>
		<a href="http://netwinsite.com/download.htm" onmouseup="x()" class="menu_row">
			Download any product...</a>
	</div>

	<div id="menu_buy" class="xmenu hidden" onmouseup="menu_hide_ex(event,'menu_buy')" onmouseout="menu_action_mouseout(event,'menu_buy')" onmouseover="menu_action_mouseover(event,'menu_buy')" style="width:220px">
		<a href="http://netwinsite.com/prices.htm" onmouseup="x()" class="menu_row divider">
			Pricing</a>
		<a href="http://netwinsite.com/https://netwinsite.com/cgi-bin/keycgi.exe?cmd=buy_new&product=surgemail" onmouseup="x()" class="menu_row"><div class="menu_icon_surgemail"></div>
			Surgemail<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/https://netwinsite.com/cgi-bin/keycgi.exe?cmd=buy_new&product=surgeftp" onmouseup="x()" class="menu_row"><div class="menu_icon_surgeftp"></div>
			SurgeFTP<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/https://netwinsite.com/cgi-bin/keycgi.exe?cmd=buy_new&product=dbabble" onmouseup="x()" class="menu_row"><div class="menu_icon_dbabble"></div>
			DBabble <span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/https://netwinsite.com/cgi-bin/keycgi.exe?cmd=buy_new&product=surgemail" onmouseup="x()" class="menu_row divider"><div class="menu_icon_surgeweb"></div>
			SurgeWeb</a>
		<a href="http://netwinsite.com/activate.htm" onmouseup="x()" class="menu_row">
			Activation guide</a>
		<a href="http://netwinsite.com/prices.htm" onmouseup="x()" class="menu_row">
			Purchase any product...</a>
	</div>

	<div id="menu_support" class="xmenu hidden" onmouseup="menu_hide_ex(event,'menu_support')" onmouseout="menu_action_mouseout(event,'menu_support')" onmouseover="menu_action_mouseover(event,'menu_support')" style="width:220px">
		<a href="http://netwinsite.com/documentation.htm" onmouseup="x()" class="menu_row divider">
			Online documentation<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/surgemail/post.htm" onmouseup="x()" class="menu_row">
			Contact support<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/support.htm#email_list" onmouseup="x()" class="menu_row">
			Standard email support<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/http://news.netwinsite.com:8119/webnews?group=netwin.surgemail&cmd=list" onmouseup="x()"  class="menu_row divider">
			Community forum <span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/support.htm" onmouseup="x()" class="menu_row">
			Support overview...</a>
	</div>

	<div id="menu_company" class="xmenu hidden" onmouseup="menu_hide_ex(event,'menu_company')" onmouseout="menu_action_mouseout(event,'menu_company')" onmouseover="menu_action_mouseover(event,'menu_company')" style="width:220px">
		<a href="http://netwinsite.com/company.htm" onmouseup="x()" class="menu_row">
			About us<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/surgemail/customers.htm" onmouseup="x()" class="menu_row">
			Customers<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/support.htm#sales_questions" onmouseup="x()" class="menu_row divider">
			Contact us</a>
	</div>
	<div style="background:url(template/img2/white_small.png);height:8px;font-size:1px;"></div>
</div>
<!-- Back to avast.htm -->

<div class="content_outer">


<!-- Back to avast.htm -->
<div class="L2C2_column_left">
<!-- Back to avast.htm -->
<div style="width:160px;">
  <div id="floating_index" class="floating_index nav-menu _document_index" style="width:160px;">
	<h2 class="menu_top">Help Index</h2>
	<ul class="level-0">

		<li class="group_hidden"><a href="#" onclick="index_toggle(event)">Getting Started</a><ul class="level-1">
			<li id="idx_surgemail.htm"><a href="surgemail.htm" target="_top">SurgeMail in a nutshell</a><ul class="level-2"></ul></li>
			<li id="idx_startingoff.htm"><a href="startingoff.htm" target="_top">Before you install</a><ul></ul></li>
			<li id="idx_install.htm"><a href="install.htm" target="_top">Installation &amp; Upgrading</a><ul></ul></li>
			<li id="idx_migration.htm"><a href="migration.htm" target="_top">Migration to SurgeMail</a><ul></ul></li>
			<li id="idx_updates.htm"><a href="updates.htm" target="_top">Change history</a><ul></ul></li>
			<li id="idx_postinstall.htm"><a href="postinstall.htm" target="_top">Post Installation</a><ul></ul></li>
			<li id="idx_faq.htm"><a href="faq.htm" target="_top">FAQ</a><ul></ul></li>
			<li id="idx_support.htm"><a href="support.htm" target="_top">Customer Support</a><ul></ul></li>
		</ul></li>

		<li class="group_hidden"><a href="#" onclick="index_toggle(event)">Anti Spam / Virus</a><ul class="level-1">
			<li id="idx_protected.htm"><a href="protected.htm#virusscanner">Virus Protection</a></li>
			<li id="idx_spam.htm"><a href="spam.htm">Spam Prevention</a></li>
			<li id="idx_protected.htm"><a href="protected.htm#mfilter">Mail Filtering</a> </li>
			<li id="idx_protected.htm"><a href="protected.htm#friends">Friendly Relations System</a></li>
			<li id="idx_rbl.htm"><a href="rbl.htm">Realtime Blackhole Lists</a></li>
		</ul></li>

		<li class="group_hidden"><a href="#" onclick="index_toggle(event)">Server Management </a><ul class="level-1">
			<li id="idx_status.htm"><a href="status.htm">Server Status</a></li>
			<li id="idx_log.htm"><a href="log.htm">Searching the log files</a></li>
			<li id="idx_report.htm"><a href="report.htm">Report generation</a></li>
			<li id="idx_accounts.htm"><a href="accounts.htm">Managing accounts</a></li>
			<li id="idx_tellmail.htm"><a href="tellmail.htm">Using the tellmail utility.</a></li>
		</ul></li>
		
		<li class="group_hidden"><a href="#" onclick="index_toggle(event)">SurgeMail Settings</a><ul class="level-1">
			<li id="idx_domain.htm"><a href="domain.htm">Domain specific settings</a></li>
			<li id="idx_global.htm"><a href="global.htm">Global settings</a></li>
			<li id="idx_webmail.htm"><a href="webmail.htm">WebMail settings</a></li>
		</ul></li>

		<li class="group_hidden"><a href="#" onclick="index_toggle(event)">Configuration Guides</a><ul class="level-1">
			<li id="idx_authent.htm"><a href="authent.htm">Authentication  Modules</a></li>
			<li id="idx_domains.htm"><a href="domains.htm">Virtual  Domains</a></li>
			<li id="idx_clustering.htm"><a href="clustering.htm">Clustering</a></li>
			<li id="idx_mirror.htm"><a href="mirror.htm">Mirror the server</a></li>
			<li id="idx_scalable.htm"><a href="scalable.htm">Performance &amp; Scalability</a></li>
			<li id="idx_lookandfeel.htm"><a href="lookandfeel.htm">Custom look and feel</a></li>
			<li id="idx_internal_email.htm"><a href="internal_email.htm">Custom internal emails </a></li>
			<li id="idx_language.htm"><a href="language.htm">Language translation</a></li>
			<li id="idx_redirection.htm"><a href="redirection.htm">Mail Redirection</a></li>
			<li id="idx_surgewall.htm"><a href="surgewall.htm">SurgeWall</a></li>
			<li id="idx_sms.htm"><a href="sms.htm">SMS</a></li>
			<li id="idx_lists.htm"><a href="lists.htm">Mailing lists and bulletins</a></li>
			<li id="idx_secure.htm"><a href="secure.htm">Securing the server</a></li>
			<li id="idx_webdav.htm"><a href="webdav.htm">WebDav</a></li>
			<li id="idx_incoming.htm"><a href="incoming.htm">Incoming MX servers</a></li>
			<li id="idx_load_balance.htm"><a href="load_balance.htm">Load balancing</a></li>
			<li id="idx_ndb.htm"><a href="ndb.htm">NDB NetWin folder format</a></li>
			<li id="idx_domainkeys.htm"><a href="domainkeys.htm">DomainKeys Support</a></li>
			<li id="idx_ipv6.htm"><a href="ipv6.htm">IPV6 Support</a></li>
			<li id="idx_amazon-ses.htm"><a href="amazon-ses.htm">Amazon-SES gateway</a></li>
			<li id="idx_examples.htm"><a href="examples.htm">Example configurations</a></li>
		</ul></li>
	</ul>
  </div>
  &nbsp;	<!-- required to render div -->
</div>
<script>window.do_scroll_menu=false</script>
<!-- Back to avast.htm -->
</div>

<!-- Back to avast.htm -->

<div class="L2C2_column_content">
<!-- Back to avast.htm -->
<!-- #BeginEditable "Body" -->

  <script language="JavaScript"> search_details('Search SurgeMail Manual:','http://netwinsite.com/surgemail/help'); </script>
  <script language="JavaScript"> display_crumbs_doc(['Home','Documentation','SurgeMail Help Index','Avast Antivirus'],3); </script>
  <script language="JavaScript"> index_select('idx_avast.htm'); </script>

  <p class="warning">If you are having trouble with Avast for linux have a read of the <a href="#memorybugs">memory access related bugs</a> at the bottom if this page.

  <h1>Avast Antivirus</h1>

  <h3 align="left">How do I install</h3>
  <p><font face="Arial, Helvetica, sans-serif">Currently the Windows and Linux
    procedures are slightly different:</font></p>
  <p><font face="Arial, Helvetica, sans-serif">On Windows (implemented as scanning
    libraries loaded directly by SurgeMail):</font></p>
  <ol>
    <li><font face="Arial, Helvetica, sans-serif">Click install on the common
      settings page</font></li>
    <li><font face="Arial, Helvetica, sans-serif">Wait until installed and updated
      to latest version (check status on settings page or advanced status page)</font></li>
    <li><font face="Arial, Helvetica, sans-serif">Enable SurgeMail integration
      by ticking the checkbox &quot;Enable Avast integration&quot;, press save.</font></li>
    <li><font face="Arial, Helvetica, sans-serif">Confirm that it is scanning
      mail and blocking viruses (by sending in <a href="http://www.eicar.org/anti_virus_test_file.htm">eicar.com</a>
      as an attachment, or using one of the online virus testing pages: eg. <a href="http://www.declude.com/Articles.asp?ID=99">declude.com</a>)</font></li>
  </ol>
  <a name="linux"></a>
  <p><font face="Arial, Helvetica, sans-serif">On Linux (implemented as av_avast
    vpipe scanner that interfaces to the Avast libraries):</font></p>
  <ol>
<!--
	<li><font face="Arial, Helvetica, sans-serif">Download the <a href="ftp://netwinsite.com/pub/surgemail/util/avast4surgemail_linux_engine470b.tar.gz">Avast
      linux distribution</a>, uncompress and run ./install.sh from the temp directory<br>
      Note: Changes to the Avast updates procedure mean you need to install this <a href="ftp://netwinsite.com/pub/surgemail/util/av_avast_1.4.tgz">av_avast binary</a> instead now,
      or install a more <a href="ftp://netwinsite.com/pub/surgemail/util/libavastengine-4.7.5-i586.tar.gz">recent avast engine build</a>. (This distribution is unmodified by netwin and you will need to manually add <a href="ftp://netwinsite.com/pub/surgemail/util/av_avast_1.4.tgz">av_avast binary</a> to the surgemail directory).
      </font></li>
-->
	<li><font face="Arial, Helvetica, sans-serif">Download the Alwil Software <a href="ftp://netwinsite.com/pub/surgemail/util/libavastengine-4.7.5-i586.tar.gz">Avast
      linux distribution</a>, uncompress and run ./mkinstall.sh. This may take a while as it downloads the latest virus definition database. Ignore the license related warning, this will be supplied by av_avast.<br>
      </font>
<pre>
[root@linux root]# wget ftp://netwinsite.com/pub/surgemail/util/libavastengine-4.7.5-i586.tar.gz
[root@linux root]# ls -l libavastengine-4.7.5-i586.tar.gz
-rw-r--r--    1 root     root     31836499 Mar 15 18:54 libavastengine-4.7.5-i586.tar.gz
[root@linux root]# tar -xzf libavastengine-4.7.5-i586.tar.gz
[root@linux root]# cd libavastengine-4.7.5-i586
[root@linux libavastengine-4.7.5-i586]# ./mkinstall.sh
Copyright(C) 2003-2009 ALWIL Software.  All rights reserved.
the avast! engine for Linux will be installed on this machine
To install 'libavastengine-4.so.7.0.5' library now, press ENTER.
....
The libavastengine-4.so.7.0.5 library installation complete.
***NOTE***: the installation package does not contain a license file.
Any program using this library will not work until you will have a valid
license file (with either a DEMO or a RELEASE license).
[root@linux libavastengine-4.7.5-i586]#
</pre>
      </li>
    <li><font face="Arial, Helvetica, sans-serif">Download NetWin <a href="ftp://netwinsite.com/pub/surgemail/util/av_avast_1.4.tgz">av_avast</a> interfacing binary, uncompress and copy to surgemail directory.</font>
<pre>
[root@linux root]# wget ftp://netwinsite.com/pub/surgemail/util/av_avast_1.4.tgz
[root@linux root]# ls -l av_avast_1.4.tgz
-rw-r--r--    1 root     root       101458 Mar 15 18:40 av_avast_1.4.tgz
[root@linux root]# tar -xzf av_avast_1.4.tgz
[root@linux root]# cp av_avast /usr/local/surgemail
</pre>
      </li>
    <li><font face="Arial, Helvetica, sans-serif">Check that you have avast running
      (and have the library prerequisites) by running &quot;./av_avast -test&quot;
      in the SurgeMail directory</font>
<pre>
[root@linux root]# cd /usr/local/surgemail
[root@linux surgemail]# ./av_avast -test
This test will:
 - dynamically load avast libraries (checking dependencies)
 - attempt to scan an infected message
 - attempt to scan a clean message...
Loading avast libraries
Scanning infected email : SUCCESS - Virus detected (EICAR Test-NOT virus!!!)
Scanning clean email    : SUCCESS - Message is clean
Avast installed and working :-)
[root@linux surgemail]#
</pre>
	</li>
    <li><font face="Arial, Helvetica, sans-serif">Enable surgemail integration
      by adding to surgemail.ini<br>
      - g_virus_filter cmd=&quot;av_avast&quot; type=&quot;&quot; <br>
      <b>note</b>: if using admin interface you would set "Filter command line"
      to "av_avast"<br>
      - g_virus_avast &quot;true&quot;<br>
      and optionally<br>
      - g_virus_avast_hour &quot;0,6,12,18&quot; </font></li>
    <li><font face="Arial, Helvetica, sans-serif">Restart surgemail</font></li>
    <li><font face="Arial, Helvetica, sans-serif">Confirm that it is scanning
      mail and blocking viruses (by sending in <a href="http://www.eicar.org/anti_virus_test_file.htm">eicar.com</a>
      as an attachment, or using one of the online virus testing pages: eg. <a href="http://www.declude.com/Articles.asp?ID=99">declude.com</a>)</font></li>
  </ol>
  <p><font face="Arial, Helvetica, sans-serif"></font></p>

  <h3>64 bit version on linux</h3>
  <p><font face="Arial, Helvetica, sans-serif">Avast for linux requires the 32 bit compatibility libraries to be installed in order to be
  	able to run on 64 bit servers. Also on some servers the default distribution will segfault as soon as any av_avast command is run.
  	This is due to faults in the linux distributions that do not call the dynamic library initialisation functions correctly. To fix this, install
  	<a href="ftp://netwinsite.com/pub/surgemail/util/avast4surgemail_linux_engine470c_64bitpatch.tar.gz">this patch</a>
  	by following <a href="avast_upgrade.htm">these instructions</a>.
  	You need to upgrade the avast binaries and make sure you have av_avast 1.4 and add the "64BITFIX_INIT true" av_avast.ini setting.</font></p>


  <h3><a name="vpipe"></a>Scanning Engine Updates on Linux</h3>
  <p><font face="Arial, Helvetica, sans-serif">On windows the scanning engine
    is automatically updated with the virus database. On linux this must be done
    manually periodically. If you are getting errors in the log files along the
    lines of &quot;<b><i>vpipe failures 25 in a row av_avast</i></b>&quot; and
    / or &quot;Avast initialisation failed, <b><i>avworkInitialize returned 42000</i></b>&quot;
    then you must upgrade the avast engine as described here.</font></p>

<ol>
    <li><font face="Arial, Helvetica, sans-serif">Download the updated <a href="ftp://netwinsite.com/pub/surgemail/util/avast4surgemail_linux_engine470b.tar.gz">Avast
      linux distribution</a> (ftp://netwinsite.com/pub/surgemail/util/avast4surgemail_linux_engine470b.tar.gz).
      </font></li>
    <li><font face="Arial, Helvetica, sans-serif">Install the distribution by running
      the ./install.sh script and answering yes to all questions.</font></li>
</ol>
  <p><font face="Arial, Helvetica, sans-serif">Here is a detailed example of this
    <a href="avast_upgrade.htm">test and upgrade process</a>.</font></p>
  <p><font face="Arial, Helvetica, sans-serif"><b>Note:</b> If the avast engine
    on linux continues to crash for you make sure you are running the 4.7 version
    of the scannign engine and not the 4.6 version.</font></p>
  <p><font face="Arial, Helvetica, sans-serif">To test which version of the scanning
    engine you are running against on linux, list the following file in your default
    libraries location:</font></p>
  <p>eg: running against 4.7.0 version of scanning engine:<br>
    [root@linux surgemail]# ls -l /usr/lib/libavastengine.so<br>
    lrwxrwxrwx 1 root root 25 Jan 10 11:22 /usr/lib/libavastengine.so -&gt; libavastengine-4.so.7.0.0<br>
  </p>

  <h3>What do the displayed statistics mean?</h3>
  <pre>	AVAST antivirus blocked 956 of 11723 messages (max concurrent=limited to 1)<br>		Scanned message  size: av=8.5kb peak=3.1mb  scantime: av=0.0s peak=3.1s<br>		av_avast version: 1.0<br>		Avast engine version: unknown<br>		Avast virus database version: 416-1 (15.04.2004)<br>		Last update run 0.8 hrs ago SUCCESS(with upgrade)<br>		Avast scanner uptime 2 days 00:06:42 <br>		Messages stored as: failed=0 slow=0 (see http://netwinsite.com/surgemail/help/avast.htm)<br>	Authent module resets  0<br>	Vpipe scanner restarts 0<br>	Viruses blocked: g_virus_cmd=0 g_virus_fprot=0 g_vpipe=956
</pre>
  <p><font face="Arial, Helvetica, sans-serif">A bunch of statistics are displayed
    on the behaviour of Avast antivirus. The most important information displayed
    is the number of messages processed and blocked because they were classified
    as unwanted (infected, unmonitorable etc). eg: above &quot;blocked 956 of
    11723 messages&quot;</font></p>
  <p><font face="Arial, Helvetica, sans-serif">In addition you should check that
    the database is getting regularly updated. The current virus database version
    is displayed &quot;416-1 (15.04.2004)&quot; and the last time this was updated
    with the result of the update. The result of the update can be:</font></p>
  <ul>
    <li> SUCCESS(with upgrade) - A new virus database update was found and was
      successfully installed</li>
    <li>SUCCESS(no upgrade) - A new virus database update was not found</li>
    <li>FAILED(reason) - The upgrade failed and the reason is displayed. Check
      log files</li>
    <li>In Progress - The upgrade is currently in progress</li>
    <li>(none since startup) - No updates have been run since startup</li>
    <li>(disabled) - Automatic updates are only run by surgemail if g_virus_avast
      &quot;true&quot; is set. In addition the frequency can be modified with
      g_virus_avast_hour.</li>
  </ul>
  <p><font face="Arial, Helvetica, sans-serif">Further information is available
    on the performance of your Avast virus scanner. This includes average and
    peak scan time and message size, the uptime of this vpipe instance of the
    running scanner. If any problems have been encountered scanning messages these
    are stored as surgemail/avast/avast_failure_n.msg and avast_slow_n.msg. If
    you are getting vpipe scanner restarts or any messages stored as failed or
    many messages stored as slow this should discussed with </font><font face="Arial, Helvetica, sans-serif">surgemail-support@netwinsite.com.</font>
  </p>
  <p>&nbsp; </p>

  <h3><a name="avast_warning1"></a><i>Avast status warning: n MESSAGES FAILED TO BE SCANNED AND BLOCKED</i></h3>
  <p><font face="Arial, Helvetica, sans-serif">If you receive this warning on
    the advanced status page this means that you are running Avast antivirus and
    an error condition has been encountered that prevented the message from being
    scanned. The message will have been bounced and stored as avast_failureNN.msg
    for analysis. </font></p>
  <p><font face="Arial, Helvetica, sans-serif">You should first check that you
    do not have another realtime filesystem level virus scanner installed (such
    as Norton Antivirus). If you do, you need to prevent the avast temp directory
    (&quot;_avast4_&quot;) from getting scanned. You will find this somewhere
    in a Windows temp folder like c:\windows\TEMP\_avast4_.</font></p>
  <p><font face="Arial, Helvetica, sans-serif">If you have checked the above and
    continue to receive this error, please report this to surgemail-support@netwinsite.com
    such that appropriate action can be taken (ie Netwin will report the problem
    to Alwil software).</font></p>

  <h3>Log files</h3>
  <p><font face="Arial, Helvetica, sans-serif">Av_avast logs all information to
    av_avast.log file. This is a log file that allows different log levels and
    control of what is logged to this file. To change the av_avast logging behaviour
    change the av_avast.ini settings. The default av_avast.ini file has an explanation
    and an example of all configuration settings.</font></p>
  <p><font face="Arial, Helvetica, sans-serif">The avast.log and avast.stat are
    the log files used (for a similar purpose but less control over what was logged)
    by the version of Avast integrated with SurgeMail on windows.</font></p>

  <h3>Notes</h3>
  <p><font face="Arial, Helvetica, sans-serif">Avast is a third party product
    developed and maintained by <a href="http://www.avast.com">ALWIL Software</a>,
    and is based on ALWIL antivirus technology. We endeavour to resolve any issues
    in short order by working closely with ALWIL Software but the maintenance
    of the virus database and actual scanning technology is not under NetWin control
    and as such NetWin does provide any guarantees on the ability for Avast Antivirus
    to catch all viruses.</font></p>
  <p><font face="Arial, Helvetica, sans-serif">Previously Avast was only available
    on Windows. Now Avast is available on Windows and Linux. The Linux version
    is implemented as a vpipe filter. The Windows version was previously run by
    loading all the Avast dlls into the SurgeMail process. </font></p>
  <p>&nbsp;</p>

<h2>Avast Troubleshooting</h2>

   <h3><a name="memorybugs"> Memory access related avast bugs </h3>

   <p>Recently some people have been experiencing that updates leave linux avast in a state where it will not run.
   It seems to be changing shared memory requirements mean that in some cases avast will segfault on startup and in
   other cases will return the error "avworkInitialize returned 22".

   <p>If this is happening for you, first try increasing the SHM segments using this command:
   <pre>sysctl -w kernel.shmmax=128000000</pre>

   <p>Also you can try and install this build instead: <a href="ftp://netwinsite.com/pub/surgemail/util/libavastengine-4.7.5-i586.tar.gz">recent avast engine build</a>.
   <p>
   This build comes direct from Alwil software and has not been modified by Netwin to include the necessary <a href="ftp://netwinsite.com/pub/surgemail/util/av_avast">av_avast</a> surgemail interfacing executable (this is already in place in the surgemail directory if you installed the older 4.7 netwin modified avast installer).
   If you install the above Avast distribution it will install a newer version of the Avast engine, and supply you with a warning regarding memory limits and how to resolve them.
   <p>
   Also in some cases the calls to the avast library surgemail runs to execute the updates fail to be able to replace the installed virus database. If this is happening for you try running avastvpsupdate.pl instead and if necessary add this as a cron job. Let us know on surgemail-support@netwinsite.com if this is happening for you / you continue to have trouble with Avast.

   <h3><a name="updates"> Update issues</h3>

   <p>If you are having trouble with updates on linux try the following steps to resolve:
   <ol>
   <li>Make sure your surgemail upgrades license is uptodate
   <li>Try running "./av_avast -update" which is running surgemail's avast upgrade code
   <li>Try running "avastvpsupdate.pl" which is running Alwil Software's script to do the same as surgemails update.
   </ol>
   In rare cases the script seems to work where running the update via av_avast does not. In this case just add avastvpsupdate.pl as a cron job.


	<h3>Further Detail on SHM issues</h3>

	<p> <i>Avast4Linux doesn't work with latest VPS (100328-1 and later)?</i>

	<p>Here is advice from Alwil software's website on correcting this:

	<div class="plain_table" style="padding:5px;">

	<p>Starting with the 400.vps, version 100328-1, one of it's internal block reached the inner limit 33554432 bytes. It's a kernel variable which is (quite artificially) limiting the maximum size of any SHM memory block - and 33554432 was a default for some kernels.

	<p>Solution? Set the limit to higher values (as root):

<pre>
From command line type
sysctl -w kernel.shmmax=128000000
OR
echo 128000000 >/proc/sys/kernel/shmmax

Place those lines to /etc/init.d/rcS or equivalent file (it's a bit distribution-specific
- see /etc/inittab, the sysinit runlevel) to have them set automatically (just after boot).

Step by step:

1.- Open terminal
2.- Type: "sudo su" (then introduce your password)
3.- Type: "echo 128000000 >/proc/sys/kernel/shmmax" (this will solve the problem in the current session).
4.- Type: "gedit /etc/init.d/rcS"
5.- Include the line as follows:
    #! /bin/sh
    #
    # rcS
    #
    # Call all S??* scripts in /etc/rcS.d/ in numerical/alphabetical order
    #
    sysctl -w kernel.shmmax=128000000
    exec /etc/init.d/rc S
6.- Save the file and that's all.
<pre>
	</div>



<br><br>
<!-- #EndEditable -->
<!-- CONTENT END -->
</div>

<!-- Back to avast.htm -->
</div>

<!-- Back to avast.htm -->

<div class="prefooter">&nbsp;</div>
<div id="footer" class="footer">
 <table align="center" CELLPADDING="0" CELLSPACING="0" WIDTH="900" HEIGHT="100" BORDER="0" >
  <tr>
    <td HEIGHT="100%" >
      <p align="center" style="margin-top: 8pt; margin-bottom: 2pt; margin-left: 8pt">
  	  <a href="http://netwinsite.com/sitemap.htm" class="footer_link">Site Map</a><span class="style2"> | </span>
  	      <a href="http://netwinsite.com/index.htm" class="footer_link">Home</a><span class="style2"> | </span>
	      <a href="http://netwinsite.com/products.htm" class="footer_link">Products</a><span class="style2"> | </span>
	      <a href="http://netwinsite.com/surgemail/post.htm" class="footer_link">Contact Netwin</a><span class="style2"> | </span>
	      <a href="http://netwinsite.com/company.htm" class="footer_link">Company</a><span class="style2"> | </span>
	      <a href="http://netwinsite.com/license_all.htm" class="footer_link">Licensing</a><span class="style2"> | </span>
	      <a href="http://netwinsite.com/links.htm" class="footer_link">Links</a><span class="style2">  </span>
		<br>
		<a href="/surgemail/" class="footer_link">Windows Mail Server Software</a><span class="style2"> |  </span> 
		<a href="/webmail/" class="footer_link">Linux Webmail</a><span class="style2"> | </span> 
		<a href="/surgemail/free_mail_server.htm" class="footer_link">Free Windows Mail Server</a>

        <table align=center width="370" border="0" style="margin-bottom: 2pt">
        <tr>
          <td width="32"><img src="template/img2/logo_small_ongray.png" height="25" hspace="1" vspace="1" align="bottom"></td>
          <td width="350"><p class="smaller" style="margin-top: 14pt;">Copyright &copy; 2011 Netwin Ltd. All rights reserved.
		  </td>
        </tr>
      </table>
	</td>
  </tr>
</table>
</div>
</div>

<br><br>
</body>

<!-- Back to avast.htm -->

</body>
</html>

<!-- End of avast.htm -->

