<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Andryan's Random Notes &#187; ClamAV</title>
	<atom:link href="http://blog.nirkabel.org/category/clamav/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.nirkabel.org</link>
	<description>This blog is here to stay</description>
	<lastBuildDate>Fri, 20 Jan 2012 03:17:09 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>ClamAV&#8217;s clamd/freshclam permission problems</title>
		<link>http://blog.nirkabel.org/2007/06/24/clamavs-clamdfreshclam-permission-problems/</link>
		<comments>http://blog.nirkabel.org/2007/06/24/clamavs-clamdfreshclam-permission-problems/#comments</comments>
		<pubDate>Sun, 24 Jun 2007 09:12:17 +0000</pubDate>
		<dc:creator>Andryan</dc:creator>
				<category><![CDATA[ClamAV]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Technical]]></category>

		<guid isPermaLink="false">http://andryan.wordpress.com/2007/06/24/clamavs-clamdfreshclam-permission-problems/</guid>
		<description><![CDATA[Since I have always used ClamAV&#8216;s clamd as the virus filter of my email servers along with qmail-scanner, I noticed that crash-hat&#8216;s clamav RPM packages use logrotate to rotate the logs files. qmail-scanner runs as its own user (qscand), so clamd has to run under the same user. When the RPM package was first installed, [...]]]></description>
			<content:encoded><![CDATA[<p>Since I have always used <a href="http://www.clamav.net/" target="_blank">ClamAV</a>&#8216;s <em>clamd</em> as the virus filter of my email servers along with <em><a href="http://qmail-scanner.sourceforge.net/" target="_blank">qmail-scanner</a></em>, I noticed that <a href="http://crash.fce.vutbr.cz/yum-repository.html" target="_blank">crash-hat</a>&#8216;s clamav RPM packages use <em>logrotate</em> to rotate the logs files. <em>qmail-scanner</em> runs as its own user (<strong>qscand</strong>), so <em>clamd</em> has to run under the same user. When the RPM package was first installed, it created these directories: /var/run/clamav/ and /var/log/clamav/. <em>Chown</em> these 2 directories to <strong>qscand</strong> (this assumes that <strong>User</strong> directives in freshclam.conf and clamd.conf have been changed to <strong>qscand</strong>), otherwise <em>clamd</em> and <em>freshclam</em> wouldn&#8217;t be able to write any logs and pid file and neither service would start.</p>
<p>As for the <em>logrotate</em> configuration, edit <strong>clamd</strong> and <strong>freshclam</strong> in /etc/logrotate.d/ to change the log files&#8217; ownership to <strong>qscand</strong> instead of <strong>clamav</strong>. Modify line 8 where it says:</p>
<blockquote><p>create 640 <strong>clamav</strong> clamav</p></blockquote>
<p>to</p>
<blockquote><p>create 640 <strong>qscand</strong> clamav</p></blockquote>
<p>That should do the trick. <img src='http://blog.nirkabel.org/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://blog.nirkabel.org/2007/06/24/clamavs-clamdfreshclam-permission-problems/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

