On 29.05.2015 02:24, Mikolaj Kucharski wrote:
Hi,

I've initially reported this problem a while ago and I thought problem
was related to IPv6. Now I belive it is not. I did some research and
this is what I've found. I contacted Reyk couple of days ago, but didn't
get any reply from him yet, so decided to post here.

I'm using OpenNTPD's constraint from the time it was introduced. However
I found that ntpd(8) often is getting stuck at the very beginning when
it starts and never recovers from that scenario. Usually it looks as
follows when you hit the problem:

# ntpctl -sa
0/4 peers valid, clock unsynced

peer
   wt tl st  next  poll          offset       delay      jitter
87.232.1.41 0.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
54.171.104.100 1.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
193.1.193.157 2.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
85.91.1.180 3.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----

Hi,
I observed this problem too. I'm following -current and after every reboot OpenNTPd stuck as
you describe. Only my NMEA sensor is working.

[ns]~$ ntpctl -sa
0/13 peers valid, 1/1 sensors valid, clock synced, stratum 1

peer
   wt tl st  next  poll          offset       delay      jitter
not resolved from pool 1.bg.pool.ntp.org
    1  2  -    0s   15s             ---- peer not valid ----
2001:470:1f0a:98e::2 from pool 2.bg.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
2a01:8740:ffff:fffd::123 from pool 2.bg.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
2a02:80e0:0:2::123 from pool 2.bg.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
2a02:6800:0:99::2 from pool 2.bg.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
77.70.121.24 from pool 2.bg.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
92.247.168.103 from pool 2.bg.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
87.97.157.120 from pool 2.bg.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
176.12.47.129 from pool 2.bg.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
213.154.229.24 from pool 3.europe.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
79.175.127.142 from pool 3.europe.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
91.235.212.22 from pool 3.europe.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----
82.197.164.46 from pool 3.europe.pool.ntp.org
    1  2  -    0s    0s             ---- peer not valid ----

sensor
   wt gd st  next  poll          offset  correction
nmea0  GPS
 * 10  1  0   12s   15s        -0.003ms     0.600ms

[ns]~$ uptime
12:08PM  up 12:18, 1 user, load averages: 0.47, 0.71, 0.55


All counters are zero and all peers are not valid. For me it usually
stays like that and never recovers until rcctl restart ntpd. Then often
it fails like above again. Multiple restarts in a row solve the problem.

Only rcctl restart ntpd helps.

[ns]~$ cat /etc/ntpd.conf
# $OpenBSD: ntpd.conf,v 1.13 2015/05/18 13:48:38 deraadt Exp $

# Addresses to listen on (ntpd does not listen by default)
listen on *

servers 1.bg.pool.ntp.org
servers 2.bg.pool.ntp.org
servers 3.europe.pool.ntp.org

server ntp.rootshells.eu weight 7

# use a specific local timedelta sensor (radio clock, etc)
sensor nmea0 correction 600 weight 10 refid GPS

# get the time constraint from a well-known HTTPS site
constraints from "https://www.google.com";


OpenBSD 5.8-beta (GENERIC) #1059: Fri Jul  3 12:47:22 MDT 2015
    dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC
real mem = 2130575360 (2031MB)
avail mem = 2062237696 (1966MB)
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: SMBIOS rev. 2.4 @ 0xfb7f0 (50 entries)
bios0: vendor American Megatrends Inc. version "080011" date 02/20/2009
bios0: Supermicro H8SSL
acpi0 at bios0: rev 2
acpi0: sleep states S0 S1 S4 S5
acpi0: tables DSDT FACP APIC OEMB
acpi0: wakeup devices P1P2(S4) USB0(S1) USB1(S1) USB2(S1) PS2K(S4) PS2M(S4) SLPB(S1)
acpitimer0 at acpi0: 3579545 Hz, 32 bits
acpimadt0 at acpi0 addr 0xfee00000: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: AMD Opteron(tm) Processor 146, 1995.33 MHz
cpu0: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,SSE3,NXE,M
MXX,FFXSR,LONG,3DNOW2,3DNOW,LAHF
cpu0: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 1MB 64b/line 16-way L2 cache cpu0: ITLB 32 4KB entries fully associative, 8 4MB entries fully associative cpu0: DTLB 32 4KB entries fully associative, 8 4MB entries fully associative
cpu0: AMD erratum 89 present, BIOS upgrade may be required
mtrr: Pentium Pro MTRR support, 8 var ranges, 88 fixed ranges
cpu0: apic clock running at 199MHz
ioapic0 at mainbus0: apid 1 pa 0xfec00000, version 11, 16 pins
ioapic1 at mainbus0: apid 2 pa 0xfec01000, version 11, 16 pins
ioapic2 at mainbus0: apid 3 pa 0xfec02000, version 11, 16 pins
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus 1 (P0P1)
acpiprt2 at acpi0: bus 2 (P1P2)
acpicpu0 at acpi0
acpibtn0 at acpi0: PWRB
acpibtn1 at acpi0: SLPB
pci0 at mainbus0 bus 0
ppb0 at pci0 dev 1 function 0 "ServerWorks HT-1000 PCI" rev 0x00
pci1 at ppb0 bus 1
ppb1 at pci1 dev 13 function 0 "ServerWorks HT-1000 PCIX" rev 0xb2
pci2 at ppb1 bus 2
bge0 at pci2 dev 3 function 0 "Broadcom BCM5704C" rev 0x10, BCM5704 B0 (0x2100): apic 2 int 8, address 00:30:48:5
6:b4:60
brgphy0 at bge0 phy 1: BCM5704 10/100/1000baseT PHY, rev. 0
bge1 at pci2 dev 3 function 1 "Broadcom BCM5704C" rev 0x10, BCM5704 B0 (0x2100): apic 2 int 9, address 00:30:48:5
6:b4:61
brgphy1 at bge1 phy 1: BCM5704 10/100/1000baseT PHY, rev. 0
pciide0 at pci1 dev 14 function 0 "ServerWorks HT-1000 SATA" rev 0x00: DMA
pciide0: using apic 1 int 11 for native-PCI interrupt
pciide0: port 0: 1.5Gb/s
wd0 at pciide0 channel 0 drive 0: <HITACHI HTS541680J9SA00>
wd0: 16-sector PIO, LBA48, 76319MB, 156301488 sectors
wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 5
pciide0: port 1: PHY offline
pciide0: port 2: 1.5Gb/s
wd1 at pciide0 channel 2 drive 0: <SAMSUNG MZMPA016HMCD-000L1>
wd1: 16-sector PIO, LBA48, 15272MB, 31277232 sectors
wd1(pciide0:2:0): using PIO mode 4, Ultra-DMA mode 6
pciide0: port 3: PHY offline
pciide1 at pci1 dev 14 function 1 "ServerWorks HT-1000 SATA" rev 0x00
piixpm0 at pci0 dev 2 function 0 "ServerWorks HT-1000" rev 0x00: polling
iic0 at piixpm0
admcts0 at iic0 addr 0x2c
spdmem0 at iic0 addr 0x50: 512MB DDR SDRAM ECC PC3200CL3.0
spdmem1 at iic0 addr 0x51: 512MB DDR SDRAM ECC PC3200CL3.0
spdmem2 at iic0 addr 0x52: 512MB DDR SDRAM non-parity PC3200CL3.0
spdmem3 at iic0 addr 0x53: 512MB DDR SDRAM non-parity PC3200CL3.0
pcib0 at pci0 dev 2 function 2 "ServerWorks HT-1000 LPC" rev 0x00
ohci0 at pci0 dev 3 function 0 "ServerWorks HT-1000 USB" rev 0x01: apic 1 int 10, version 1.0, legacy support ohci1 at pci0 dev 3 function 1 "ServerWorks HT-1000 USB" rev 0x01: apic 1 int 10, version 1.0, legacy support ehci0 at pci0 dev 3 function 2 "ServerWorks HT-1000 USB" rev 0x01: apic 1 int 10
usb0 at ehci0: USB revision 2.0
uhub0 at usb0 "ServerWorks EHCI root hub" rev 2.00/1.00 addr 1
vga1 at pci0 dev 5 function 0 "ATI Rage XL" rev 0x27
wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation)
wsdisplay0: screen 1-5 added (80x25, vt100 emulation)
pchb0 at pci0 dev 24 function 0 "AMD AMD64 0Fh HyperTransport" rev 0x00
pchb1 at pci0 dev 24 function 1 "AMD AMD64 0Fh Address Map" rev 0x00
pchb2 at pci0 dev 24 function 2 "AMD AMD64 0Fh DRAM Cfg" rev 0x00
kate0 at pci0 dev 24 function 3 "AMD AMD64 0Fh Misc Cfg" rev 0x00
isa0 at pcib0
isadma0 at isa0
com0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
com0: console
com1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo
pckbc0 at isa0 port 0x60/5 irq 1 irq 12
pckbd0 at pckbc0 (kbd slot)
wskbd0 at pckbd0: console keyboard, using wsdisplay0
pcppi0 at isa0 port 0x61
spkr0 at pcppi0
usb1 at ohci0: USB revision 1.0
uhub1 at usb1 "ServerWorks OHCI root hub" rev 1.00/1.00 addr 1
usb2 at ohci1: USB revision 1.0
uhub2 at usb2 "ServerWorks OHCI root hub" rev 1.00/1.00 addr 1
uftdi0 at uhub1 port 2 configuration 1 interface 0 "FTDI FT232R USB UART" rev 2.00/6.00 addr 2
ucom0 at uftdi0 portno 1
vscsi0 at root
scsibus1 at vscsi0: 256 targets
softraid0 at root
scsibus2 at softraid0: 256 targets
sd0 at scsibus2 targ 1 lun 0: <OPENBSD, SR RAID 1, 005> SCSI2 0/direct fixed
sd0: 15264MB, 512 bytes/sector, 31261898 sectors
root on sd0a (84fdd34aaf0b5d78.a) swap on sd0b dump on sd0b

Reply via email to