Can't see the error of my ways - Clamd

Steve Campbell campbell at cnpapers.com
Tue Nov 11 14:40:33 GMT 2008



Julian Field wrote:
>
>
> Steve Campbell wrote:
>> Really frustated, as I should be able to see this.
>>
>> I have installed the latest MS and the Clamd rpms on a machine, and 
>> then, after seeing that it is running fine, onto two other machines. 
>> The first is still running fine. The other two are reporting the 
>> error in my maillog:
>>
>> ::ERROR:: UNKNOWN CLAMD RETURN ./lstat() failed. ERROR :: 
>> /var/spool/MailScanner/incoming/10897
>>
>> Now, I have tried to figure out where the ownership and permissions 
>> are going haywire, but haven't been able to. I am running sendmail.
>>
>> I can stop MS, change the ownership of the incoming directory to 
>> clamav.root on the bad machine as it is on the nicely-running 
>> machine. When I start MS and it creates the first temp directory 
>> under incoming, it changes the ownership back to root.clamav for the 
>> directory incoming and the temp directories. I have tried comparing 
>> the MS.conf files and the clamd.conf files, but see no difference.
>>
>> Does anyone have a clue?
> Have you checked all the ownership and permissions settings in 
> MailScanner.conf? I would suspect that's where your problem is, 
> MailScanner will be overwriting your manually set permissions.
>
> Jules
>

Well, that seems to be the problem. I had the options mixed up terribly, 
but when I fixed them, it still didn't correct the problem. (I had the 
group as 0640!!!!!). Gosh I hate bifocals.

The comments in the conf file indicate that I cannot change the incoming 
directory user if I am running MS as user root, which I am, unless the 
clamav user is in the root group, which it is not. I had the user set 
blank and group set to clamav for the incoming dir. So just for the hell 
of it, I set both user and group to clamav, and the error went away.

Still confused but working. Thanks Jules for the second set of eyes. I 
must have look at those 20 times before.

Steve



More information about the MailScanner mailing list