Bug 200884 - www/thttpd - Option to remove stats in syslog?
Summary: www/thttpd - Option to remove stats in syslog?
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Alexey Dokuchaev
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-06-15 19:59 UTC by donnex
Modified: 2016-07-02 06:00 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (danfe)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description donnex 2015-06-15 19:59:48 UTC
I just upgraded my thttpd package to the latest version thttpd-2.26_1

Since the upgrade I get stats outputed to syslog every hour (3600 secs). I don't know if this is the proper channel, but it would be really nice if there were a way to configure and turn off the stats output from thttpd to syslog.

I tracked the stats output down to config.h, it seems possible to turn it off.

/* CONFIGURE: Seconds between stats syslogs.  If this is undefined then
** no stats are accumulated and no stats syslogs are done.
*/
#define STATS_TIME 3600

## messages
Jun 15 19:45:57 thttpd[64878]: up 14400 seconds, stats for 3600 seconds:
Jun 15 19:45:57 thttpd[64878]:   thttpd - 8 connections (0.00222222/sec), 1 max simultaneous, 200000 bytes (55.5556/sec), 2 httpd_conns allocated
Jun 15 19:45:57 thttpd[64878]:   libhttpd - 30 strings allocated, 8200 bytes (273.333 bytes/str)
Jun 15 19:45:57 thttpd[64878]:   map cache - 0 allocated, 0 active (0 bytes), 0 free; hash size: 0; expire age: 1800
Jun 15 19:45:57 thttpd[64878]:   fdwatch - 2156 kevents (0.598889/sec)
Jun 15 19:45:57 thttpd[64878]:   timers - 3 allocated, 3 active, 0 free
Jun 15 20:45:57 thttpd[64878]: up 18000 seconds, stats for 3600 seconds:
Jun 15 20:45:57 thttpd[64878]:   thttpd - 0 connections (0/sec), 0 max simultaneous, 0 bytes (0/sec), 2 httpd_conns allocated
Jun 15 20:45:57 thttpd[64878]:   libhttpd - 30 strings allocated, 8200 bytes (273.333 bytes/str)
Jun 15 20:45:57 thttpd[64878]:   map cache - 0 allocated, 0 active (0 bytes), 0 free; hash size: 0; expire age: 1800
Jun 15 20:45:57 thttpd[64878]:   fdwatch - 730 kevents (0.202778/sec)
Jun 15 20:45:57 thttpd[64878]:   timers - 3 allocated, 3 active, 0 free
Jun 15 21:37:57 thttpd[64878]: up 21120 seconds, stats for 3120 seconds:
Jun 15 21:37:57 thttpd[64878]:   thttpd - 0 connections (0/sec), 0 max simultaneous, 0 bytes (0/sec), 2 httpd_conns allocated
Jun 15 21:37:57 thttpd[64878]:   libhttpd - 30 strings allocated, 8200 bytes (273.333 bytes/str)
Jun 15 21:37:57 thttpd[64878]:   map cache - 0 allocated, 0 active (0 bytes), 0 free; hash size: 0; expire age: 1800
Jun 15 21:37:57 thttpd[64878]:   fdwatch - 634 kevents (0.203205/sec)
Jun 15 21:37:57 thttpd[64878]:   timers - 3 allocated, 3 active, 0 free
Comment 1 commit-hook freebsd_committer freebsd_triage 2016-07-02 05:54:44 UTC
A commit references this bug:

Author: danfe
Date: Sat Jul  2 05:54:12 UTC 2016
New revision: 417909
URL: https://svnweb.freebsd.org/changeset/ports/417909

Log:
  - Make thttpd's collecting of internal stats and printing them to system
    log every hour optional, because apparently some users do not want it
  - Convert to option helper targets (post-patch-FOO-off) while here, which
    allows us to remove `.include <bsd.port.options.mk>'

  PR:	200884

Changes:
  head/www/thttpd/Makefile
Comment 2 Alexey Dokuchaev freebsd_committer freebsd_triage 2016-07-02 06:00:14 UTC
Option had been added in ports r417909 to disable the stats.