ClamAV 0.95 - lstat() failed [SOLVED]

Forum for getting help with Project Gamera, Spamassassin, Clamav, qmail-scanner and other anti-spam tools.
albans
Forum User
Forum User
Posts: 59
Joined: Tue Mar 28, 2006 4:03 am

ClamAV 0.95 - lstat() failed [SOLVED]

Unread post by albans »

Hello,
I installed ClamAV 0.95 from the atomic repository, and now I see this in my logwatch email:

lstat() failed on: /var/spool/qscan/tmp/host.tld123879626679212033
lstat() failed on: /var/spool/qscan/tmp/host.tld123879681779212278
lstat() failed on: /var/spool/qscan/tmp/host.tld123879682279212300
lstat() failed on: /var/spool/qscan/tmp/host.tld123879740679212594
lstat() failed on: /var/spool/qscan/tmp/host.tld123879751079212695
lstat() failed on: /var/spool/qscan/tmp/host.tld123879752379212716
lstat() failed on: /var/spool/qscan/tmp/host.tld123879754079212738
lstat() failed on: /var/spool/qscan/tmp/host.tld123879763379212809

What can I do to correct this problem (which doesn't seem to block any email)?
Could it be an access problem to /var/spool/qscan/tmp/ by clamd?
Thanks!
scott
Atomicorp Staff - Site Admin
Atomicorp Staff - Site Admin
Posts: 8355
Joined: Wed Dec 31, 1969 8:00 pm
Location: earth
Contact:

Re: ClamAV 0.95 - lstat() failed

Unread post by scott »

That means that clamd cant read the file, its generally permissions related.
mrhankey_ch
Forum User
Forum User
Posts: 26
Joined: Wed Feb 11, 2009 7:42 am

Re: ClamAV 0.95 - lstat() failed

Unread post by mrhankey_ch »

Okay, I chmoded /var/spool/qscan/tmp/ to 777 (not so clean) and everything works fine again!
singeX
Forum User
Forum User
Posts: 28
Joined: Sat Jul 21, 2007 7:31 pm

Re: ClamAV 0.95 - lstat() failed [SOLVED]

Unread post by singeX »

This is an older thread but for people looking for a solution to the problem try this:

It may be as easy as restarting clamd. It was in my case. To be sure though go through these steps:

Code: Select all

ps -ef | grep clamd
Look at the first column. If the user is clamd and not qscand then check the clamd conf file for the line "User qscand":

Code: Select all

vi /etc/clamd.conf
/User
If it says "User clamd" then change it to "User qscand". Either way, restart clamd afterwards.

Code: Select all

service clamd restart
Verify that the process is now owned by qscand:

Code: Select all

ps -ef | grep clamd
Then verify that /var/spool/qscan/tmp is owned by qscand:

Code: Select all

ls -l /var/spool/qscan
If it's not, then change it:

Code: Select all

chmod -R qscand:qscand /var/spool/qscan/tmp
This was based on Centos 5.3 with the following packages:
clamd-0.95.2-1.el5.art
qmail-scanner-2.06-1.el5.art
Post Reply