From owner-freebsd-current@FreeBSD.ORG Fri Nov 28 20:39:10 2003 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7988616A4CE; Fri, 28 Nov 2003 20:39:10 -0800 (PST) Received: from ganymede.hub.org (u46n208.hfx.eastlink.ca [24.222.46.208]) by mx1.FreeBSD.org (Postfix) with ESMTP id 20C6F43F75; Fri, 28 Nov 2003 20:39:09 -0800 (PST) (envelope-from scrappy@hub.org) Received: by ganymede.hub.org (Postfix, from userid 1000) id 9117234599; Sat, 29 Nov 2003 00:36:22 -0400 (AST) Received: from localhost (localhost [127.0.0.1]) by ganymede.hub.org (Postfix) with ESMTP id 8FFF334403; Sat, 29 Nov 2003 00:36:22 -0400 (AST) Date: Sat, 29 Nov 2003 00:36:22 -0400 (AST) From: "Marc G. Fournier" To: Kris Kennaway In-Reply-To: <20031129025137.GA92629@xor.obsecurity.org> Message-ID: <20031129003221.F99096@ganymede.hub.org> References: <20031128212342.G99096@ganymede.hub.org> <20031129025137.GA92629@xor.obsecurity.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: freebsd-current@freebsd.org cc: freebsd-stable@freebsd.org Subject: Re: Time jumping on both 4.x and 5.x ... X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Nov 2003 04:39:10 -0000 On Fri, 28 Nov 2003, Kris Kennaway wrote: > On Fri, Nov 28, 2003 at 09:32:30PM -0400, Marc G. Fournier wrote: > > > > In trying to isolate an issue where the PostgreSQL 'explain analyze' is > > showing "odd results" (namely, negative time estimates on queries), Tom > > Lane wrote a quick C program to test gettimeofday() (program attached) ... > > the results on a 4.9-PRERELEASE kernel of Sep 20 14:16:48 ADT 2003 shows: > > > > neptune# time ./timetest > > out of order tv_sec: 1070068479 99040, prev 1070069174 725235 > > out of order tv_usec: 1070068479 99040, prev 1070069174 725235 > > out of order tv_sec: 1070069175 19687, prev 1070068479 99040 > > out of order tv_usec: 1070069175 19687, prev 1070068479 99040 > > out of order tv_sec: 1070068499 99377, prev 1070069194 625573 > > out of order tv_usec: 1070068499 99377, prev 1070069194 625573 > > out of order tv_sec: 1070069194 808542, prev 1070068499 99377 > > ^C1.171u 23.461s 0:24.68 99.7% 5+169k 1+0io 0pf+0w > > > > One person on the list has tried the same script on a 5.2 kernel, and > > reports seeing similar results, but after a longer period of time (~30min) > > ... > > What hardware, kernel configuration, etc? Do you have a misconfigured > ntpd/timed that is manually flapping the time around? Hardware for the above is a Dual-Xeon, 4Gig of RAM, and about 421 processes running on it currently ... kernel config is at the bottom, but I don't think there is anything 'abnormal' about it ... and note that I've had others be able to reproduce the problem on both 4.x and 5.x systems ... as to ntpd/timed ... don't run either ... run ntpdate twice a day (11:59 and 23:59), but that is it as far as playing with the clock is concerned ... ---- Marc G. Fournier Hub.Org Networking Services (http://www.hub.org) Email: scrappy@hub.org Yahoo!: yscrappy ICQ: 7615664 machine i386 cpu I686_CPU ident kernel maxusers 0 makeoptions DEBUG=-g #Build kernel with gdb(1) debug symbols options NMBCLUSTERS=16384 options VM_KMEM_SIZE="(400*1024*1024)" options VM_KMEM_SIZE_MAX="(400*1024*1024)" options NULLFS #NULL filesystem options UNION #Union filesystem options NFS #Network File System options COMPAT_LINUX options INET #InterNETworking options FFS #Berkeley Fast Filesystem options FFS_ROOT #FFS usable as root device [keep this!] options SOFTUPDATES #Enable FFS soft updates support options UFS_DIRHASH #Improve performance on big directories options PROCFS #Process filesystem options COMPAT_43 #Compatible with BSD 4.3 [KEEP THIS!] options SCSI_DELAY=15000 #Delay (in ms) before probing SCSI options KTRACE #ktrace(1) support options SYSVSHM options SHMMAXPGS=199608 options SHMMAX=(SHMMAXPGS*PAGE_SIZE+1) options SYSVSEM options SEMMNI=4096 options SEMMNS=8192 options SYSVMSG #SYSV-style message queues options P1003_1B #Posix P1003_1B real-time extensions options _KPOSIX_PRIORITY_SCHEDULING options ICMP_BANDLIM #Rate limit bad replies options KBD_INSTALL_CDEV # install a CDEV entry in /dev options SMP # Symmetric MultiProcessor Kernel options APIC_IO # Symmetric (APIC) I/O device isa device pci device ahd # AHA39320/29320 and onboard AIC79xx devices options AHD_REG_PRETTY_PRINT # Print register bitfields in debug # output. Adds ~215k to driver. device scbus # SCSI bus (required) device da # Direct Access (disks) device pass # Passthrough device (direct SCSI access) device ses device atkbdc0 at isa? port IO_KBD device atkbd0 at atkbdc? irq 1 flags 0x1 device psm0 at atkbdc? irq 12 device vga0 at isa? pseudo-device splash device sc0 at isa? flags 0x100 device npx0 at nexus? port IO_NPX irq 13 device em # Intel PRO/1000 adapter Gigabit Ethernet Card ( ``Wiseman'') pseudo-device loop # Network loopback pseudo-device ether # Ethernet support pseudo-device pty 256 # Pseudo-ttys (telnet etc) pseudo-device bpf #Berkeley packet filter options DDB options DDB_UNATTENDED options INCLUDE_CONFIG_FILE # Include this file in kernel