You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Dean Gaudet <dg...@arctic.org> on 1997/10/22 18:55:37 UTC

[PATCH] Re: New error_log format (fwd)

On Wed, 22 Oct 1997, Marc Slemko wrote:

> I could agree that this shouldn't perhaps be an error and perhaps it 
> should be set to more than 4; perhaps some % of currently running servers?

It shouldn't be an error, it's just FYI.  I thought I had bumped it from 4
to 8 already ... 4 is too low regardless because that's what a navigator
will spawn at the same time.  I can't decide on a good percentage of the
currently running servers -- because this is really related to the burst
sizes that hit the server...

But here's a patch which also closes PR#1293.  Note that we currently
don't count the total number of children in the loop, so I had to add
that.  With this we can probably figure out what % is a good %.

Dean

Index: http_main.c
===================================================================
RCS file: /export/home/cvs/apachen/src/main/http_main.c,v
retrieving revision 1.236
diff -u -r1.236 http_main.c
--- http_main.c	1997/10/22 16:43:05	1.236
+++ http_main.c	1997/10/22 16:51:09
@@ -2984,6 +2984,7 @@
     int free_length;
     int free_slots[MAX_SPAWN_RATE];
     int last_non_dead;
+    int total_non_dead;
 
     /* initialize the free_list */
     free_length = 0;
@@ -2991,6 +2992,7 @@
     to_kill = -1;
     idle_count = 0;
     last_non_dead = -1;
+    total_non_dead = 0;
 
     sync_scoreboard_image();
     for (i = 0; i < daemons_limit; ++i) {
@@ -3023,6 +3025,7 @@
 	    break;
 	}
 	if (ss->status != SERVER_DEAD) {
+	    ++total_non_dead;
 	    last_non_dead = i;
 #ifdef OPTIMIZE_TIMEOUTS
 	    if (ss->timeout_len) {
@@ -3068,11 +3071,13 @@
 	    idle_spawn_rate = 1;
 	}
 	else {
-	    if (idle_spawn_rate >= 4) {
-		aplog_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, server_conf,
-		    "server seems busy, spawning %d children (you may need "
-			"to increase StartServers, or Min/MaxSpareServers)",
-			    idle_spawn_rate);
+	    if (idle_spawn_rate >= 8) {
+		aplog_error(APLOG_MARK, APLOG_NOERRNO|APLOG_INFO, server_conf,
+		    "server seems busy, (you may need "
+		    "to increase StartServers, or Min/MaxSpareServers), "
+		    "spawning %d children, there are %d idle, and "
+		    "%d total children", idle_spawn_rate,
+		    idle_count, total_non_dead);
 	    }
 	    for (i = 0; i < free_length; ++i) {
 		make_child(server_conf, free_slots[i], now);


Re: [PATCH] Re: New error_log format (fwd)

Posted by Martin Kraemer <Ma...@mch.sni.de>.
On Wed, Oct 22, 1997 at 10:55:37AM -0700, Dean Gaudet wrote:
> But here's a patch which also closes PR#1293.  Note that we currently
> don't count the total number of children in the loop, so I had to add
> that.  With this we can probably figure out what % is a good %.

Looks good; esp. gives the admin more information about the situation.
+1 definitely.

    Martin
-- 
| S I E M E N S |  <Ma...@mch.sni.de>  |      Siemens Nixdorf
| ------------- |   Voice: +49-89-636-46021     |  Informationssysteme AG
| N I X D O R F |   FAX:   +49-89-636-44994     |   81730 Munich, Germany
~~~~~~~~~~~~~~~~My opinions only, of course; pgp key available on request