Ultrix loses time on reboot (with fix)

Dave Steffens das at earvax.UUCP
Tue Aug 12 05:05:21 AEST 1986


Index:   /etc/rc   Ultrix   FIX

Description:
	Recently I have been doing device driver development under
	Ultrix 1.1 on my uVAX.  This requires frequent rebooting
	in order to debug the driver code.  I have noticed that
	the system I am working on loses a **significant** amount
	of time with respect to another uVAX to which it is networked.
	Time is never lost over the weekend when I'm not working.

	To make a long story short, the time loss seems to be caused
	by some fooling around in /etc/rc to establish the time zone.  
	Some stuff has been added to date(1) but the code in /etc/rc
	does not make good use of it -- the seconds read from the TOY
	clock at boot time are thrown away by the code in /etc/rc.

Repeat-by:
	Reboot your Ultrix 1.1 (1.2?) system 10 times.
	Watch it lose an average of 30 seconds each time.
	After 10 trys, it will be about 5 minutes slow.

Fix:
	Make the following changes.  I have shortened "PERCENT" to "PCT"
	so that the format string for date fits on an 80 char line.
	Before you ask -- No, I don't know why they didn't just use "%".

2c2
< PERCENT=%
---
> PCT=%
7c7
< dt=`date -u "+${PERCENT}y${PERCENT}m${PERCENT}d${PERCENT}H${PERCENT}M"`
---
> dt=`date -u "+${PCT}y${PCT}m${PCT}d${PCT}H${PCT}M.${PCT}S"`

-- 
{harvard,mit-eddie,think}!eplunix!earvax!das	David Allan Steffens
243 Charles St., Boston, MA 02114		Eaton-Peabody Laboratory
(617) 523-7900 x2748				Mass. Eye & Ear Infirmary



More information about the Comp.bugs.4bsd.ucb-fixes mailing list