Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
From: Matthew X Economou <econommx@rose-hulman.edu>
Subject: rc.sysinit problem: (for ARC time) clock invocation is wrong?
Date: 04 Jan 1997 01:06:58 -0500	[thread overview]
Message-ID: <44b471389eb4b12a892d10e5eb4e40ae.axp-list@archive.invalid> (raw)

-----BEGIN PGP SIGNED MESSAGE-----

The equipment:

Multia (VX40) running Linux 2.0.27 and RedHat 4.0.
This system uses ARC console time.

The problem:

I've just upgraded initscripts (as per the Errata), and the clock
command for ARC console time is /etc/rc.d/rc.sysinit is wrong.  If my
system executes the script as it was originally "clock -A -a -u", the
reported time and year will be off by some magnitude (like the year
will be 2017).  Changing the clock command to "clock -A -a" fixes
it...the reported time (with the date command, or on the FVWM95 task
bar) is correct, anyway.

Here's the (relevant part of the) original rc.sysinit script:

if [ -f /etc/sysconfig/clock ]; then
    . /etc/sysconfig/clock
    if [ ${CLOCKMODE} = "GMT" ]; then
            clock -u -a
    else
        if [ ${CLOCKMODE} = "ARC" ]; then
            clock -A -a -u
        else
            clock -a
        fi
    fi
else
    clock -a
fi

Changing it to the following fixed it right up:

if [ -f /etc/sysconfig/clock ]; then
    . /etc/sysconfig/clock
    if [ ${CLOCKMODE} = "GMT" ]; then
            clock -u -a
    else
        if [ ${CLOCKMODE} = "ARC" ]; then
            clock -A -a # originally -A -a -u
        else
            clock -a
        fi
    fi
else
    clock -a
fi

Did I find a bug, or am I being dense?  (P.S. I had to fix this in the
original rc.sysinit, too, but I hadn't heard anyone complain about the
date not working.)

-----BEGIN PGP SIGNATURE-----
Version: 2.6.2
Comment: Processed by Mailcrypt 3.4, an Emacs/PGP interface

iQCVAwUBMs3zZCjh7SVEyfhxAQFhswQAl1tdoRZeft0tbxwp2gjpjxOFR1GN9GzX
VG+bw0oQrhs6BZpBVcPJCQ8v48u5smG2dbSRgGnxargT3Q/jWcgnxvi+SaxNIRqV
VO9jlvYfiVOUkbXP9KNNfJGYW7gM2RJDx9oQRLyYb/57e4yKI3V7NwRkpHhocshI
gGqwiZtQWUY=
=kw3C
-----END PGP SIGNATURE-----

-- 
Matthew X. Economou - Finger/WWW for public key. - Geek of Computer Science(!)
econommx@rose-hulman.edu - http://www.rose-hulman.edu/~econommx - Random quote:
"Hours of frustration punctuated by moments of sheer terror" - a.s.r.

--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com

                 reply	other threads:[~1997-01-04  6:06 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox