Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
Go Back   Zimbra :: Forums > Zimbra Collaboration Suite > Developers

Welcome to the Zimbra :: Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 06-13-2007, 08:02 AM
Starter Member
 
Posts: 2
Default libexec/zmmtaconfig not reaping children, bug?

Hi,

We have a zimbra (4.5.5_GA_838) installation on RHEL 4 and after a while, we get a lot of java zombie processes hanging around:

zimbra 10339 6568 0 Jun12 ? 00:00:00 [java] <defunct>
zimbra 14581 6568 0 Jun12 ? 00:00:00 [java] <defunct>
zimbra 15254 6568 0 Jun12 ? 00:00:00 [java] <defunct>
zimbra 15822 6568 0 Jun12 ? 00:00:01 [java] <defunct>


The PPID is 6568 which in this case is zmmtaconfig. I checked the code and found out that catchSignal() is used to catch SIGCHLD signals which are ignored. I changed the code to the following:

HTML Code:
sub catchSignal {
  my $sig = shift;
  if ($sig eq "CHLD") {
    while ((my $pid = waitpid(-1, WNOHANG)) > 0) {
      logMsg(2, "Reaping child pid '$pid'");
    }
    return;
  }
  logMsg(3, "Shutting down. Received signal $sig");
  exit 0;
}
And it fixed the problem, no more zombie processes. According to the perl documentation, another way to go about it would be to set the SIGCHLD handler to 'IGNORE' which would let perl cleanup child processes but in that case we wouldn't be able to log about them...

Ciao
Jean-Philippe Bouchard
Sitepak Inc.
Reply With Quote
  #2 (permalink)  
Old 06-13-2007, 08:19 AM
Starter Member
 
Posts: 2
Default

Nevermind, turns out there was a already a bug report in bugzilla (Bug 17457 - Lots of defunct "java" processes on RHEL4 after upgrade). I attached my fix to it...
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads

Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

blog.zimbra.com




 

SEO by vBSEO ©2011, Crawlability, Inc.