The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

spamd child eating 100% of Cpu help

Discussion in 'General Discussion' started by bsasninja, Jul 16, 2007.

  1. bsasninja

    bsasninja Well-Known Member

    Joined:
    Sep 2, 2004
    Messages:
    528
    Likes Received:
    0
    Trophy Points:
    16
    Spamd child is eating 100% of CPU.
    It happens only with a mail account.

    Notes:
    Spamassasin is globaly enabled on all domains, but I cant disable in this one.
    Mail account is empty

    The only fix I found by now is to stop and start exim. Is there a permanent solution to this?????

    Help will be apreciated!

    Thanks
     
  2. bsasninja

    bsasninja Well-Known Member

    Joined:
    Sep 2, 2004
    Messages:
    528
    Likes Received:
    0
    Trophy Points:
    16
    solution: terminate the account and add it again.
     
  3. jack01

    jack01 Well-Known Member

    Joined:
    Jul 21, 2004
    Messages:
    200
    Likes Received:
    0
    Trophy Points:
    16
    bsasninja,

    We have this same problem on 2 of our servers, the same user (different on each server) keeps hogging a "spamd child" process with high cpu, as if its endlessly looping or something.

    Can you confirm that since reinstalling the account as per your solution that this really did stop for good?

    Thanks.

    P.S. does anyone else have a fix that does not involve removing the affected account(s)?
     
    #3 jack01, Aug 1, 2007
    Last edited: Aug 1, 2007
  4. yapluka

    yapluka Well-Known Member

    Joined:
    Dec 24, 2003
    Messages:
    301
    Likes Received:
    1
    Trophy Points:
    18
    Location:
    France
    cPanel Access Level:
    Root Administrator
    Check that the account is not running out of space. I had the very same issue and this was the cause...

    Good luck :)
     
  5. bsasninja

    bsasninja Well-Known Member

    Joined:
    Sep 2, 2004
    Messages:
    528
    Likes Received:
    0
    Trophy Points:
    16
    150mb of space, 116mb used.

    Using spamassassin 3.2.1

    Thanks
     
  6. yapluka

    yapluka Well-Known Member

    Joined:
    Dec 24, 2003
    Messages:
    301
    Likes Received:
    1
    Trophy Points:
    18
    Location:
    France
    cPanel Access Level:
    Root Administrator
    Did you try to trace the process ?
     
  7. bsasninja

    bsasninja Well-Known Member

    Joined:
    Sep 2, 2004
    Messages:
    528
    Likes Received:
    0
    Trophy Points:
    16
    shows the following

    open("/home/user/.spamassassin/auto-whitelist.lock.server1.domain.com.31435", O_WRONLY|O_CREAT|O_TRUNC|O_LARGEFILE, 0666) = 11
    ioctl(11, SNDCTL_TMR_TIMEBASE or TCGETS, 0xbfe854f8) = -1 ENOTTY (Inappropriate ioctl for device)

    stat64("/home/user/.spamassassin/auto-whitelist", {st_mode=S_IFREG|0600, st_size=10510336, ...}) = 0
    open("/home/user/.spamassassin/auto-whitelist", O_RDWR|O_LARGEFILE) = 11

    is there a way to tell spamassassin not to scan files over 1mb or so ?

    Thanks
     
  8. dexus

    dexus Well-Known Member

    Joined:
    Jan 14, 2006
    Messages:
    169
    Likes Received:
    0
    Trophy Points:
    16
    cPanel Access Level:
    Root Administrator
    I had the same problem for last few days, but when my spamd stucks it did this:

    Code:
    stat64("/home/user/.spamassassin/bayes_toks.new", 0xbfffb120) = -1 ENOENT (No such file or directory)
    open("/home/user/.spamassassin/__db.bayes_toks.new", O_RDWR|O_CREAT|O_EXCL|O_LARGEFILE, 0600) = -1 EEXIST (File exists)
    open("/home/user/.spamassassin/__db.bayes_toks.new", O_RDWR|O_CREAT|O_EXCL|O_LARGEFILE, 0600) = -1 EEXIST (File exists)
    open("/home/user/.spamassassin/__db.bayes_toks.new", O_RDWR|O_CREAT|O_EXCL|O_LARGEFILE, 0600) = -1 EEXIST (File exists)
    stat64("/home/user/.spamassassin/bayes_toks.new", 0xbfffb120) = -1 ENOENT (No such file or directory)
    open("/home/user/.spamassassin/__db.bayes_toks.new", O_RDWR|O_CREAT|O_EXCL|O_LARGEFILE, 0600) = -1 EEXIST (File exists)
    open("/home/user/.spamassassin/__db.bayes_toks.new", O_RDWR|O_CREAT|O_EXCL|O_LARGEFILE, 0600) = -1 EEXIST (File exists)
    
    So I just deleted file /home/user/.spamassassin/__db.bayes_toks.new and spamd got out of loop :)
     
  9. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
    Also make sure you have perl 5.8.8
    and if you aren't using nfs

    uncomment lock_method flock in /etc/mail/spamassassin/local.cf and run
    Code:
    /scripts/restartsrv_exim
     
  10. isputra

    isputra Well-Known Member

    Joined:
    May 3, 2003
    Messages:
    576
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Mbelitar
    In my case, my customer is running out of space.
    So i do like dexus said and works.

    I have perl 5.8.8 :
    ----------
    root@server [~]# perl -v
    This is perl, v5.8.8 built for i686-linux
    ----------

    cpanelnick, could you explain to me what is lock_method flock in /etc/mail/spamassassin/local.cf for ?
     
  11. adapter

    adapter Well-Known Member
    PartnerNOC

    Joined:
    Sep 17, 2003
    Messages:
    391
    Likes Received:
    0
    Trophy Points:
    16
    same problem here, if i delete the db file in the spamassasin folder i am out from the loop, but is there any fast way to fix this problem? i can't do it for all my server and over quota account

    Thx
     
  12. myrtlenet

    myrtlenet Registered

    Joined:
    Apr 19, 2005
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Same problem

    Some accounts close to quota, others have plenty of space. Other thing is it seems to be random. It started out with 3 accounts, now its around 7.

    I ended up turning Bayesian off altogether
     
  13. Arsalan

    Arsalan Well-Known Member

    Joined:
    Jan 5, 2002
    Messages:
    51
    Likes Received:
    0
    Trophy Points:
    6
    try deleting the databases of Bayesian in /home/user/.spamassassin


    We found that large databases are usually responsible for this problem. Removing the files usually resolves the issue. Further more, keep an eye out on their size.
     
  14. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
    This is a bug in the berkleydb library. We have tracked it down and are testing a work around patch for spamassassin. We have also reported the problem to spamassassin and the DB_File author. We will release an autofixer for spamassassin once the testing has been completed and proven to not create any unwanted side effected.

    Note: RHEL 5 && Centos 5 are not affected
     
  15. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
  16. isputra

    isputra Well-Known Member

    Joined:
    May 3, 2003
    Messages:
    576
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Mbelitar
  17. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
  18. bmcpanel

    bmcpanel Well-Known Member

    Joined:
    Jun 1, 2002
    Messages:
    546
    Likes Received:
    0
    Trophy Points:
    16
    Thanks nick. Great service.
     
  19. adapter

    adapter Well-Known Member
    PartnerNOC

    Joined:
    Sep 17, 2003
    Messages:
    391
    Likes Received:
    0
    Trophy Points:
    16
    we apply this fix but the problem is the same
     
  20. xphost

    xphost Well-Known Member

    Joined:
    Nov 12, 2003
    Messages:
    76
    Likes Received:
    0
    Trophy Points:
    6
    have the same problem after bug fix

    User Domain %CPU %MEM MySQL Processes
    login login.com 9.59 2.47 0.0
    Top Process %CPU 34.8 spamd child
    Top Process %CPU 33.9 spamd child
    Top Process %CPU 32.2 spamd child
     
Loading...

Share This Page