When can time(2) return 0?!

When can time(2) return 0?!

Post by Thor Lancelot Sim » Wed, 23 Oct 1996 04:00:00



I have been using truss to examine a particularly recalcitrant intallation of
Oracle 7.3.2.  Some rather unusual facts have turned up, the most surprising
of which is that either as the cause of or coincidentally with the Oracle log
writer dying, time() system calls by any of the Oracle processes begin to
return 0, even though calls to times() by the same processes seem to return
sane values.

A snippet of some truss output from the Oracle log writer process:

| setitimer(ITIMER_REAL, 0x08046DA0, 0x00000000)        = 0
| time()                                                = 846038141
| write(15, "05\0\0\0F0\0\0\0AD !E010".., 2048)       = 2048
| time()                                                = 846038141
| write(15, "05\0\0\0F1\0\0\0AD !E010".., 2048)       = 2048
| semctl(720896, 6, 8, 1)                               = 0
| time()                                                = 846038141
| write(15, "05\0\0\0F2\0\0\0AD !E010".., 8192)       = 8192
| semctl(720896, 6, 8, 1)                               = 0
| time()                                                = 0
| time()                                                = 0
| semctl(720896, 2, 8, 1)                               = 0
| semctl(720896, 3, 8, 1)                               = 0
| semctl(720896, 4, 8, 1)                               = 0
| semctl(720896, 5, 8, 1)                               = 0
| semctl(720896, 6, 8, 1)                               = 0
| times(0x08046A04)                             = 35357161
|       utim=25     stim=134    cutim=0      cstim=0      (HZ=100)

What the hell is going on here?

This is _not_ a bug in truss; when it exits, the log writer prints out the
current time as the beginning of the epoch.

Is this some kind of severe bug in Solaris/x86 2.5.1?  This never happened to
us under 2.5...

--

  There's nothing like rancid bear fat to keep you happy.       -Perry Metzger