On 04/28/2011 03:04 PM, bsquared wrote:

>>
>
> Your message reminded me to look into it and here's what I found...
>
> excerpt from "http://www.linuxfromscratch.org/hints/downloads/files/time.txt";
>
> ~   Next are the symlinks. The symlink to run the setclock script is already
> ~ present in /etc/rc.d/rc.sysinit.d, so the only symlinks we have to create 
> are
> ~ the ones to run setclock when the system shuts down:
> ~
> ~     # ln -s ../init.d/setclock /etc/rc.d/rc0.d/K45setclock&&
> ~     # ln -s ../init.d/setclock /etc/rc.d/rc6.d/K45setclock
> ~
> ~   At this point, the boot scripts are correctly set up and the only thing
> ~ that's left to configure is the TZ environment variable.
>
> However, I do not find " /etc/rc.d/rc.sysinit.d".  I do find
> /etc/rc.d/rcsysinit.d, but there is no link to setclock.  What is the
> value/run level for start?  Apparently this script was in LFS at some
> time, I wonder what happened.


The script is no longer symlinked in /etc/rc.d/rcsysinit.d/. It is now 
ran by udevd. There are two rules in /etc/udev/rules.d/55-lfs.rules that 
run the setclock script during the time of 'udevadm settle'.

SUBSYSTEM=="rtc", ACTION=="add", MODE="0644", RUN+="/etc/init.d/setclock 
start"

and

KERNEL=="rtc", ACTION=="add", MODE="0644", RUN+="/etc/init.d/setclock start"

Nothing is ever displayed on the screen as this script is run by udevd, 
which has its own display level, not by init, but be assured that if the 
/dev/rtc file exists, be it a symlink to a device node, or a device node 
itself, the setclock script has already been run (unless the setclock 
script is missing or not executable) during the time of the udev 
script's run in rcsysinit.d. This does not mean that you cannot create 
the symlinks in RL0 and RL6 to run the script at shutdown.

Hope that helps rather than confuses.

-- DJ Lucas

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page

Reply via email to