Thread View: news.software.nntp
1 messages
1 total messages
Started by Jeff Garzik
Mon, 02 Jun 1997 00:00
More stats for INN
Author: Jeff Garzik
Date: Mon, 02 Jun 1997 00:00
Date: Mon, 02 Jun 1997 00:00
62 lines
2452 bytes
2452 bytes
This is a multi-part message in MIME format.
--------------7E4671BD4CDE57851D4B059
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Here's a little Perl script I wrote to display the current status of
the INN server. It shows the inn mode, each incoming connection and
its status, outgoing connections, and connected readers. It caches page
output so that the ctlinnd calls are made, at most, every 200 seconds.
Live output is at
http://news.spinne.com/cgi-bin/inn-status
The patch to display connection stats is attached below. It modifies
the "ctlinnd name" output to display current accepted, rejected, and
refused stats. I tried to get the patch to display seconds-connected as
well, but I kept getting a short read error?? The Perl source code for
the simple CGI display script is at
ftp://ftp.spinne.com/pub/usenet/tools/inn-status.pl
--
Jeff Garzik
News Administrator, Spinne, Inc.
http://www.spinne.com/usenet/
--------------7E4671BD4CDE57851D4B059
Content-Type: text/plain; charset=us-ascii; name="cc.c.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline; filename="cc.c.patch"
*** ../inn-plain/innd/cc.c Tue Dec 17 09:40:40 1996
--- innd/cc.c Mon Jun 2 05:21:16 1997
***************
*** 876,881 ****
--- 877,883 ----
register char *p;
register int count;
int i;
+ char Gs1[128];
p = av[0];
if (*p != '\0') {
***************
*** 892,897 ****
--- 894,902 ----
BUFFappend(&CCreply, NL, 1);
p = CHANname(cp);
BUFFappend(&CCreply, p, strlen(p));
+ sprintf(Gs1, ":accepted %ld:refused %ld:rejected %ld",
+ cp->Received, cp->Refused, cp->Rejected);
+ BUFFappend(&CCreply, Gs1, strlen(Gs1));
}
BUFFappend(&CCreply, NIL, 1);
return CCreply.Data;
--------------7E4671BD4CDE57851D4B059--
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads