httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cliff Skolnick <cl...@organic.com>
Subject WWW Form Bug Report: "reclaim_child_processes not called on server restart" on Solaris 2.x (fwd)
Date Tue, 28 May 1996 19:04:23 GMT

no ack sent

--
Cliff Skolnick                                      cliff@organic.com

"They that can give up essential liberty to obtain a little temporary
safety deserve neither liberty nor safety." -- Benjamin Franklin, 1759

---------- Forwarded message ----------
Date: Tue May 28 5:41:35 1996
From: jk@tools.de
To: cliff@organic.com
Subject: WWW Form Bug Report: "reclaim_child_processes not called on server restart" on Solaris
2.x

Submitter: jk@tools.de
Operating system: Solaris 2.x, version: 
Version of Apache Used: 1.1b2 1.1b3-dev
Extra Modules used: 
URL exhibiting problem: 

Symptoms:
--
When the server listens to multiple ports (via
the httpd.conf 'Listen <port>' directive), a 
SIGHUP sent to the main server doesn't call
reclaim_child_processes.  The status of the killed
child processes is collected much later, after the
server is fully restarted.  Also an error log
entry for the SIGHUP is missing in logs/error_log.

Suggested patch:

*** apache_19960527130015-orig/src/http_main.c  Wed May 22 21:00:14 1996
--- apache_19960527130015/src/http_main.c       Tue May 28 14:31:44 1996
***************
*** 1322,1328 ****
      struct sockaddr_in sa_server;
  
      standalone = 1;
!     sd = -1;
      
      if (!one_process) detach(); 
      
--- 1343,1349 ----
      struct sockaddr_in sa_server;
  
      standalone = 1;
!     sd = listenmaxfd = -1;
      
      if (!one_process) detach(); 
      
***************
*** 1335,1347 ****
      signal (SIGHUP, SIG_IGN); /* Until we're done (re)reading config */
      
      if(!one_process)
  #ifndef NO_KILLPG
!       killpg(pgrp,SIGHUP);    /* Kill 'em off */
  #else
!       kill(-pgrp,SIGHUP);
  #endif
!     
!     if (sd != -1) {
        reclaim_child_processes(); /* Not when just starting up */
        log_error ("SIGHUP received.  Attempting to restart", server_conf);
      }
--- 1356,1371 ----
      signal (SIGHUP, SIG_IGN); /* Until we're done (re)reading config */
      
      if(!one_process)
+     {
  #ifndef NO_KILLPG
!       if (killpg(pgrp,SIGHUP) < 0)    /* Kill 'em off */
  #else
!       if (kill(-pgrp,SIGHUP) < 0)
  #endif
!       log_unixerr ("killpg SIGHUP", NULL, NULL, server_conf);
!     }
! 
!     if (sd != -1 || listenmaxfd != -1) {
        reclaim_child_processes(); /* Not when just starting up */
        log_error ("SIGHUP received.  Attempting to restart", server_conf);
      }

--

Backtrace:
--

--


Mime
View raw message