From nobody@FreeBSD.org  Wed Jul 11 16:25:44 2012
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 6A00A106564A
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 11 Jul 2012 16:25:44 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22])
	by mx1.freebsd.org (Postfix) with ESMTP id 55ABE8FC12
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 11 Jul 2012 16:25:44 +0000 (UTC)
Received: from red.freebsd.org (localhost [127.0.0.1])
	by red.freebsd.org (8.14.4/8.14.4) with ESMTP id q6BGPiIH045467
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 11 Jul 2012 16:25:44 GMT
	(envelope-from nobody@red.freebsd.org)
Received: (from nobody@localhost)
	by red.freebsd.org (8.14.4/8.14.4/Submit) id q6BGPiEd045456;
	Wed, 11 Jul 2012 16:25:44 GMT
	(envelope-from nobody)
Message-Id: <201207111625.q6BGPiEd045456@red.freebsd.org>
Date: Wed, 11 Jul 2012 16:25:44 GMT
From: Brian Conway <bugs@zxvf.us>
To: freebsd-gnats-submit@FreeBSD.org
Subject: Openntpd port stomps on ntpdate in rcorder(8)
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         169787
>Category:       ports
>Synopsis:       net/openntpd stomps on ntpdate in rcorder(8)
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    naddy
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Jul 11 16:30:01 UTC 2012
>Closed-Date:    Tue Jul 17 14:40:45 UTC 2012
>Last-Modified:  Tue Jul 17 14:50:06 UTC 2012
>Originator:     Brian Conway
>Release:        8.3-RELEASE-p3
>Organization:
>Environment:
FreeBSD test.zxvf.local 8.3-RELEASE-p3 FreeBSD 8.3-RELEASE-p3 #4: Tue Jun 12 14:44:09 UTC 2012     root@fbsd83.zxvf.local:/usr/obj/nanobsd.tar/usr/src/sys/GENERIC.nodebug  i386
>Description:
In base, the rc.d script for ntpd includes a REQUIRE: ntpdate, which allows ntpdate to initially set the time, followed by running ntpd.

It appears openntpd's rc.d script has no such REQUIRE:, and I frequently find that openntpd will start first, and ntpdate cannot run and set the initial time. This can be a pain on a system that is significantly skewed on cold boot.
>How-To-Repeat:
Include in rc.conf, after installing openntpd port:

ntpdate_enable="YES"
ntpdate_hosts="us.pool.ntp.org"
openntpd_enable="YES"

Boot the system.
>Fix:
Update /usr/local/etc/rc.d/openntpd to include:

# REQUIRE: DAEMON ntpdate

For reference, ntpd's rc-script includes all of the following (may not be relevant):

# REQUIRE: DAEMON ntpdate cleanvar devfs

Thanks.

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->naddy 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Thu Jul 12 04:23:34 UTC 2012 
Responsible-Changed-Why:  
Fix synopsis and assign. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=169787 
State-Changed-From-To: open->closed 
State-Changed-By: naddy 
State-Changed-When: Tue Jul 17 14:35:58 UTC 2012 
State-Changed-Why:  
Instead of running ntpdate, you should really just set openntpd_flags="-s" 
to make openntpd set the time immediately at startup. 

However, I agree that the combination should be possible, so I have 
committed the change.  Thanks! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=169787 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/169787: commit references a PR
Date: Tue, 17 Jul 2012 14:36:01 +0000 (UTC)

 Author: naddy
 Date: Tue Jul 17 14:35:46 2012
 New Revision: 301005
 URL: http://svn.freebsd.org/changeset/ports/301005
 
 Log:
   In the rc.d script, have ntpd start after ntpdate.
   
   PR:		169787
   Submitted by:	Brian Conway <bugs@zxvf.us>
 
 Modified:
   head/net/openntpd/Makefile
   head/net/openntpd/files/openntpd.in
 
 Modified: head/net/openntpd/Makefile
 ==============================================================================
 --- head/net/openntpd/Makefile	Tue Jul 17 14:35:18 2012	(r301004)
 +++ head/net/openntpd/Makefile	Tue Jul 17 14:35:46 2012	(r301005)
 @@ -7,7 +7,7 @@
  
  PORTNAME=	openntpd
  PORTVERSION=	4.6
 -PORTREVISION=	1
 +PORTREVISION=	2
  PORTEPOCH=	2
  CATEGORIES=	net
  MASTER_SITES=	${MASTER_SITE_OPENBSD}
 
 Modified: head/net/openntpd/files/openntpd.in
 ==============================================================================
 --- head/net/openntpd/files/openntpd.in	Tue Jul 17 14:35:18 2012	(r301004)
 +++ head/net/openntpd/files/openntpd.in	Tue Jul 17 14:35:46 2012	(r301005)
 @@ -3,7 +3,7 @@
  # $FreeBSD$
  #
  # PROVIDE: openntpd
 -# REQUIRE: DAEMON
 +# REQUIRE: DAEMON ntpdate
  # BEFORE:  LOGIN
  # KEYWORD: nojail shutdown
  #
 _______________________________________________
 svn-ports-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/svn-ports-all
 To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
 
>Unformatted:
