Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 110674 - [net-misc/ntp] ntp.drift file should not be created by default
Summary: [net-misc/ntp] ntp.drift file should not be created by default
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: SpanKY
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-10-28 00:58 UTC by Ortwin Glueck
Modified: 2006-01-13 02:51 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ortwin Glueck 2005-10-28 00:58:01 UTC
The (empty) file /var/lib/ntp/ntp.drift should not be created by the ebuild.
This is because ntpd will create this file when first started and store
information about the local clock in this file. If the file is present ntpd will
not perform this important initial calibration. See man ntpd.

Actually ntpd logs an error message when started the first time:
 Oct 28 09:46:15 gollum ntpd[3622]: Frequency format error in /var/lib/ntp/ntp.drift
because the drift file is present but empty.

Reproducible: Always
Steps to Reproduce:
Comment 1 SpanKY gentoo-dev 2005-10-28 17:56:23 UTC
it does it because there were reports iirc about the drift file not being able
to be created properly due to permission issues

if you remove the file and run in droproot mode, does ntpd generate the file
properly ?
Comment 2 Ortwin Glueck 2005-10-29 15:21:35 UTC
Droproot is not enabled by default. But the drift file is created by default. So
the behaviour is not consistent. I expect an ebuild to work out of the box if I
don't change anything, not the opposite.
Comment 3 SpanKY gentoo-dev 2005-10-29 18:26:05 UTC
droproot is enabled by default

USE=-nodroproot + conf.d/ntpd has NTPD_OPTS="-u ntp:ntp"
Comment 4 Ortwin Glueck 2005-10-30 00:01:08 UTC
Oh, true. Sorry. Well, it doesn't matter anyway. The drift file is created
correctly as ntp has it's own folder in /var/lib. And an empty drift file is
invalid in any case.
Comment 5 Ulrich Müller gentoo-dev 2006-01-12 04:31:48 UTC
Any progress on this issue?

ntpd will create the ntp.drift file with proper ownership if it is absent, so I believe removing the "touch" and "fowners" lines for ntp.drift from the ebuild should be enough.
Comment 6 SpanKY gentoo-dev 2006-01-13 02:51:00 UTC
the other reason the touch is there is to prevent portage from being helpful and removing the otherwise empty directory on us

ive changed the dodir to keepdir and dropped the touch/fowners