Page 1 of 2 12 LastLast
Results 1 to 10 of 12

Thread: [SOLVED] Clamd.pid - no such file

  1. #1
    Join Date
    Sep 2007
    Location
    Berkeley, CA
    Posts
    24
    Rep Power
    8

    Default [SOLVED] Clamd.pid - no such file

    I noticed today that Zimbra isn't working, and that the reason seems to have something to do with the virus scanner.

    I did a zmclamdctl status, and the result was /opt/zimbra/log/clamd.pid: No such file or directory...

    I can't imagine what would cause this, but I performed: locate clamd.pid, and that didn't bring up any results, so this is a bit worrisome...any ideas on how to fix this?

    Thanks.

  2. #2
    Join Date
    May 2006
    Location
    USA
    Posts
    6,242
    Rep Power
    21

    Default

    Welcome to the forums,

    What version are you running? (zmcontrol -v)

    Is your mail going to the differed queue?

    Do you see anything like: "Can't connect to INET socket 127.0.0.1:3310: Connection refused" in the logs?
    (check /var/log/zimbra.log)

    If your on 4.5.6 try modifying /opt/zimbra/libexec/zmmtaconfig line 59 & change the interval from 120 to something 180+
    & if your up to over 320 still with no luck, create a clamd.pid in /opt/zimbra/log/ then try to startup.
    Last edited by mmorse; 10-07-2007 at 10:56 PM.

  3. #3
    Join Date
    Sep 2007
    Location
    Berkeley, CA
    Posts
    24
    Rep Power
    8

    Default

    Hi Mike.

    Thanks for the help - I hadn't realized that was my first post. I guess I had been thinking about posting for a little while.

    To answer your question, I'm running Zimbra Release 4.5.6_GA_1044.UBUNTU6, UBUNTU6 FOSS edition, and I ought to metion I'm running it on Ubuntu 7.04.

    You're right, the mail is going to the deferred queue as of now. As for error messages you're right on the money. I guess that means that I'm making some beginner's mistake, but I don't understand what that message means.

    I upped the value in the zmmtaconfig file to 320, restarting the server, and checked the status of the server, and antivirus still wasn't running, so I made a clamd.pid file in /opt/zimbra/log/, via touch /opt/zimbra/log/clamd.pid, but that didn't do the trick either.

    Am I missing something? Thanks.

  4. #4
    Join Date
    May 2006
    Location
    USA
    Posts
    6,242
    Rep Power
    21

    Default

    Quote Originally Posted by mlissner View Post
    Thanks for the help - I hadn't realized that was my first post. I guess I had been thinking about posting for a little while.
    I saw you were a member since Sept 21st though

    Quote Originally Posted by mlissner View Post
    You're right, the mail is going to the deferred queue as of now. As for error messages you're right on the money. I guess that means that I'm making some beginner's mistake, but I don't understand what that message means.
    Am I missing something? Thanks.
    Nope it's not your fault, make a backup & upgrade to 4.5.7 SourceForge.net: Files or .8 /community/downloads.html
    The clamav version in 4.5.6 needed some fixing. In-short you end up in a clamav restart loop, hence why I first suggested changing the watchdog timeout.

    Optionally you can also update manually, again make a backup and see Updating CLAMAV - ZimbraWiki

    Quote Originally Posted by mlissner View Post
    I upped the value in the zmmtaconfig file to 320, restarting the server, and checked the status of the server, and antivirus still wasn't running, so I made a clamd.pid file in /opt/zimbra/log/, via touch /opt/zimbra/log/clamd.pid, but that didn't do the trick either.
    If you want to keep trying with the .pid - though if you're already not getting any luck past 5 min I doubt it will help...
    Backup the /opt/zimbra/bin/zmantivirusctl file
    As the zimbra user create /opt/zimbra/log/clamd.pid.fake
    Then as root, in /opt/zimbra/bin/zmantivirusctl right after the line
    Code:
    /opt/zimbra/bin/$i start norewrite
    insert
    Code:
    cp /opt/zimbra/log/clamd.pid.fake /opt/zimbra/log/clamd.pid
    so that everytime clamav starts it creates the clamd.pid file from clamd.pid.fake

    If you we're curious, one of the bugs was here: Bug 18312 - ClamAV: clamd corrupt db
    The most succinct summary:
    One theory is that since clamAV 0.90 has a very long start-up, and zmmtaconfig/watchdog runs once a minute, it's entirely possible that corruptions are happening when a second clamAV is started. So getting a faster start-up (0.91.1) may fix this.
    Last edited by mmorse; 10-08-2007 at 01:46 PM. Reason: other methods - but you might as well update to 4.5.8

  5. #5
    Join Date
    Sep 2007
    Location
    Berkeley, CA
    Posts
    24
    Rep Power
    8

    Default

    OK - I think I can do either of these three routes (update clamav, update zimbra or set up the clamd.pid copy trick). I think I will go with the first, but it doesn't sound like your recommendation. I had a heck of a time installing Zimbra the first time, and I'd hate to go through that all over again if it wasn't absolutely necessary. As for the file copy trick, it is quite tempting, but it seems like it would ultimately break as soon as I updated anything, so that doesn't sound like a good fix.

    Before I go through with updating clamav though, why is it that this problem began in the first place? I had a functional installation at one point...I don't think I did any updating or anything that would have caused this problem...

  6. #6
    Join Date
    May 2006
    Location
    USA
    Posts
    6,242
    Rep Power
    21

    Default

    Quote Originally Posted by mlissner View Post
    OK - I think I can do either of these three routes (update clamav, update zimbra or set up the clamd.pid copy trick). I think I will go with the first, but it doesn't sound like your recommendation. I had a heck of a time installing Zimbra the first time, and I'd hate to go through that all over again if it wasn't absolutely necessary. As for the file copy trick, it is quite tempting, but it seems like it would ultimately break as soon as I updated anything, so that doesn't sound like a good fix.
    Upgrading is actually really fast, easy, & and your most reliable bet to get this up as fast as possible.
    See the bottom of the release notes for instructions /pdf/Zimbra OS Release Notes.pdf

    4.5.7 also had a bunch of tomcat & ldap stability enhancements - 4.5.8 is just a release under Yahoo's license to appease the lawyers

    Quote Originally Posted by mlissner View Post
    Before I go through with updating clamav though, why is it that this problem began in the first place? I had a functional installation at one point...I don't think I did any updating or anything that would have caused this problem...
    I edited my above post & put the original bug link in (probably after you had started replying).
    Quote Originally Posted by mmorse View Post
    If you we're curious, one of the bugs was here: Bug 18312 - ClamAV: clamd corrupt db
    The most succinct summary:
    One theory is that since clamAV 0.90 has a very long start-up, and zmmtaconfig/watchdog runs once a minute, it's entirely possible that corruptions are happening when a second clamAV is started. So getting a faster start-up (0.91.1) may fix this.
    Last edited by mmorse; 10-07-2007 at 11:50 PM.

  7. #7
    Join Date
    May 2006
    Location
    USA
    Posts
    6,242
    Rep Power
    21

    Default

    Though I did forget to mention:
    After you get this working with 4.5.7 (or .8 if you wish) with no more differed mails, "Can't connect to INET socket 127.0.0.1:3310" errors, etc you may wish to update clamav manually.
    See here a list of fixes: Bug 20568 - Clamav update to version 0.91.2
    As always, be sure to have a full backup of your /opt/zimbra/ directory first!

    We always recommend to get on the current version anyway; because if you have a problem that builds from this, it's hard to troubleshoot if it's a bug or if it's just you
    (Someone had trouble on a v3 version the other day & that's a little old when v5.0 is about to roll out...& even v4.0 -not to be confused with v4.5- is approaching EOL)
    Just the DB:
    su - zimbra
    mkdir /tmp/clamdb
    mv /opt/zimbra/clamav/db/* /tmp/clamdb
    zmprov ms `zmhostname` +zimbraServiceEnabled antivirus
    /opt/zimbra/clamav/bin/freshclam --config-file=/opt/zimbra/conf/freshclam.conf
    zmamavisctl stop
    zmamavisctl start
    Last edited by mmorse; 03-02-2008 at 07:06 PM.

  8. #8
    Join Date
    Sep 2007
    Location
    Berkeley, CA
    Posts
    24
    Rep Power
    8

    Default

    This is a bit odd, but suddenly during the night, everything started working...can I trust that I'll soon have problems again, or is everything OK? I'm a bit hesitant to do any installs/upgrades unless I really need to...

    Is the concensus on the version I'm running that it pretty much MUST be upgraded eventually?

  9. #9
    Join Date
    May 2006
    Location
    USA
    Posts
    6,242
    Rep Power
    21

    Default

    If you can survive great, the problems usually crop up on reboots, if you can plan sometime to upgrade to .7/.8 (which has now been found to contain the stats fix) go for it, else keep an eye on your box & you already know the 3 fix methods...
    Though it did take 66 comments on that bug if that says anything...
    Last edited by mmorse; 10-08-2007 at 09:33 PM.

  10. #10
    Join Date
    Jul 2006
    Location
    ireland
    Posts
    388
    Rep Power
    9

    Talking thanks for the post

    thanks for the post also found extra steps on bugz:

    su - zimbra
    mkdir /tmp/clamdb
    mv /opt/zimbra/clamav/db/* /tmp/clamdb
    zmprov ms `zmhostname` +zimbraServiceEnabled antivirus
    /opt/zimbra/clamav/bin/freshclam --config-file=/opt/zimbra/conf/freshclam.conf
    zmamavisctl stop
    zmamavisctl start

Similar Threads

  1. centos 5 zimbra 4.5.6 no statistics
    By rutman286 in forum Installation
    Replies: 9
    Last Post: 08-14-2007, 09:30 AM
  2. Opensource backup Question.
    By nfear24 in forum Administrators
    Replies: 3
    Last Post: 03-31-2007, 11:47 PM
  3. Replies: 5
    Last Post: 03-01-2007, 02:20 AM
  4. Traslation SVN tree status
    By meikka in forum I18N/L10N - Translations
    Replies: 7
    Last Post: 02-13-2007, 10:13 AM
  5. M3 problem with shares
    By titangears in forum Users
    Replies: 4
    Last Post: 01-12-2006, 12:01 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •