> My main g4 mini seems to be struggling with keeping time and has been
> for ages. After a reboot it keeps time just fine for days (with ntpd
> running). Then at some point it just falls apart and starts losing
> time steadily (like, a few minutes a day). This time round I kept an
> eye on it, to see when it's gonna start doing that and it took about
> 20 days. Nothing interesting in the logs.
I wonder if the built-in time base is drifting too much for ntpd
to be able to compensate. ntpd tolerates up to 500ppm, but takes
a while to figure out how large the drift actually is.
This is the sort of manual adjustments I've made to one of mine:
ambrosia: {8} pwd
/usr/src/sys/arch/macppc/conf
ambrosia: {9} cat AMBROSIA
# AMBROSIA
#
# GENERIC kernel, plus tweaked timebase frequency
include "arch/macppc/conf/GENERIC"
# Adjust TIMEBASE_FREQ, ref powerpc/oea/ofwoea_machdep.c
# Note that /usr/obj/sys/arch/macppc/compile/AMBROSIA/ofwoea_machdep.o
# needs to be manually removed/cleaned before rebuild.
# Previous attempt(s):
#options TIMEBASE_FREQ=41600661 # read from OFW
#options TIMEBASE_FREQ=41500496 # freq -12.8 ppm
options TIMEBASE_FREQ=41501058 # freq 0.362 ppm
ambrosia: {10} uname -a
NetBSD ambrosia.urc.uninett.no 10.1 NetBSD 10.1 (AMBROSIA) #1: Sat Apr 12 10:15:28 CEST 2025 he%ambrosia.urc.uninett.no@localhost:/usr/obj/sys/arch/macppc/compile/AMBROSIA macppc
ambrosia: {11} ntpq -c rv
...
tc=10, mintc=3, offset=+2.031770, frequency=+0.874, sys_jitter=2.808629,
clk_jitter=2.568, clk_wander=0.106
ambrosia: {12}
Note the "frequency=" is in ppm if I'm not terribly mistaken.
ambrosia: {13} cat /var/db/ntp.drift
0.873
ambrosia: {14}
Regards,
- Havard