Bug 199855 - ping prints useless message to stderr, breaking nagios ping plugin
Summary: ping prints useless message to stderr, breaking nagios ping plugin
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: CURRENT
Hardware: amd64 Any
: --- Affects Many People
Assignee: Brooks Davis
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-05-02 01:04 UTC by Marcus Reid
Modified: 2015-05-19 19:02 UTC (History)
1 user (show)

See Also:
brooks: mfc-stable10+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Marcus Reid 2015-05-02 01:04:18 UTC
Ping sends a message to stderr during normal operation which seems unnecessary, and breaks at least the nagios ping plugin.  The message in question is "capability mode sandbox enabled", and while interesting, does not seem informative enough to be part of the output of every invocation of ping.

$ ping www.google.com
capability mode sandbox enabled
PING www.google.com (74.125.28.104): 56 data bytes
64 bytes from 74.125.28.104: icmp_seq=0 ttl=46 time=19.387 ms
...

In order to fix nagios on -CURRENT, I had to comment out the line that prints this debugging message.
Comment 1 Brooks Davis freebsd_committer freebsd_triage 2015-05-04 15:56:32 UTC
These messages aren't useful and should be removed.  If they exist at all they should go to syslog at INFO or DEBUG.  I've submitted a review request to remove them.

https://reviews.freebsd.org/D2440
Comment 2 commit-hook freebsd_committer freebsd_triage 2015-05-04 21:45:28 UTC
A commit references this bug:

Author: brooks
Date: Mon May  4 21:44:52 UTC 2015
New revision: 282436
URL: https://svnweb.freebsd.org/changeset/base/282436

Log:
  Remove "capability mode sandbox enabled" messages.

  These messages serve little purpose and break some consumers.

  PR:		199855
  Differential Revision:	https://reviews.freebsd.org/D2440
  Reviewed by:	rwatson
  Approved by:	pjd
  MFC after:	1 week
  Sponsored by:	DARPA, AFRL

Changes:
  head/contrib/tcpdump/tcpdump.c
  head/sbin/ping/ping.c
  head/usr.bin/kdump/kdump.c
Comment 3 Brooks Davis freebsd_committer freebsd_triage 2015-05-04 22:04:25 UTC
correct flag values.
Comment 4 Marcus Reid 2015-05-05 01:10:16 UTC
Fixed! Thanks!
Comment 5 commit-hook freebsd_committer freebsd_triage 2015-05-19 19:02:00 UTC
A commit references this bug:

Author: brooks
Date: Tue May 19 19:01:53 UTC 2015
New revision: 283122
URL: https://svnweb.freebsd.org/changeset/base/283122

Log:
  MFC r282436 (the portion that makes sense):

  Remove "capability mode sandbox enabled" messages.

  These messages serve little purpose and break some consumers.

  PR:		199855
  Differential Revision:	https://reviews.freebsd.org/D2440
  Reviewed by:	rwatson
  Approved by:	pjd
  Sponsored by:	DARPA, AFRL

Changes:
_U  stable/10/
  stable/10/contrib/tcpdump/tcpdump.c