[Bug 911] New: Configuring the setclock Script: "hwclock --show" always shows localtime

bugzilla at linuxfromscratch.org bugzilla at linuxfromscratch.org
Mon Sep 27 18:18:33 PDT 2004


http://bugs.linuxfromscratch.org/show_bug.cgi?id=911

           Summary: Configuring the setclock Script: "hwclock --show" always
                    shows localtime
           Product: Linux From Scratch
           Version: TESTING
          Platform: Other
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: P5
         Component: Book
        AssignedTo: lfs-book at linuxfromscratch.org
        ReportedBy: lizardo at linuxfromscratch.org
         QAContact: lfs-book at linuxfromscratch.org


Chapter 7, "Configuring the setclock Script", says the following: 
 
"If you cannot remember whether or not the hardware clock is set to UTC time, 
find out by running the hwclock --show command. This will tell what the current 
time is according to the hardware clock. If this time matches whatever your 
watch says, then the hardware clock is set to local time. If the output from 
hwclock is not local time, chances are it is set to UTC time. [...]" 
 
According to hwclock's man page, with the --show option, "The time shown is 
always in local time, even if you keep your Hardware Clock in Coordinated 
Universal Time" 
 
This way, the "hwclock --show" command will always show local time and does not  
help finding whether hardware clock is set to UTC or localtime. The command 
that does exactly what the LFS book intends to say is "hwclock --localtime 
--show", which shows the localtime if hw clock is set to localtime, or UTC 
otherwise. This works because, I suppose, "--localtime" means "show the 'raw' 
clock (as seen on the BIOS setup)".



------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
You are the QA contact for the bug, or are watching the QA contact.



More information about the lfs-book mailing list