bin/103425: ntpdate(8) utility does not obey the -s option the right way

Mindaugas gloomy at gloomy.eu
Wed Sep 20 07:40:47 PDT 2006


>Number:         103425
>Category:       bin
>Synopsis:       ntpdate(8) utility does not obey the -s option the right way
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Sep 20 14:40:30 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Mindaugas
>Release:        5.4-STABLE
>Organization:
>Environment:
FreeBSD floridamortgagemadeeasy.com 5.4-STABLE FreeBSD 5.4-STABLE #1: Fri Jan 13 06:21:03 UTC 2006     mindaugas at beta.floridamortgagemadeeasy.com:/usr/src/sys/i386/compile/beta  i386

>Description:
the manual of ntpdate (man ntpdate) tells:
 -s      Divert logging output from the standard output (default) to the
             system syslog(3) facility.  This is designed primarily for conve-
             nience of cron(8) scripts.

I have ntpdate command executed every 4 to 24 hours on various servers by
the cron. While using -s option i still get information output to the
standard output (the cron emails that output text by the email). The -s
option *does not* divert the output from the standart output to the syslog.
It just adds extra logging to the syslog.

Examining ntpdate source confirms that.

According to the manual it should shutdown the output to the standard output
and use syslog instead.

And this is quite annoying to get email from crontab every time ntpdate
updates the time ;)
>How-To-Repeat:
set ntpdate with -s option on crontab
>Fix:
Parse the ntpdate.c
(http://www.freebsd.org/cgi/cvsweb.cgi/src/contrib/ntp/ntpdate/ntpdate.c?rev=1.1.1.7&content-type=text/x-cvsweb-markup)
and maybe other files to properly check the status of syslogit variable
each time the program has anything to output.

>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-bugs mailing list