Command help?

Rick Stevens ricks at nerd.com
Fri Sep 26 21:16:51 UTC 2008


Aaron Konstam wrote:
> On Fri, 2008-09-26 at 12:56 -0700, Rick Stevens wrote:
>> Bradley wrote:
>>> Patrick O'Callaghan wrote:
>>>> On Thu, 2008-09-25 at 14:24 -0700, Rick Stevens wrote:
>>>>   
>>>>> Whoops!  In my previous comment on this, I neglected to mention you
>>>>> really need to run /etc/rc.d/rc with the desired runlevel to force the
>>>>> /etc/rc.d/rcX.d stuff to go.  In other words, if you do "telinit 3",
>>>>> then you should also do "/etc/rc.d/rc 3" after it.
>>>>>     
>>>> I don't think this is right. AFAIK the change in run level causes the
>>>> script to be run automatically. Note that on F9 the mechanism is
>>>> different from on previous Fedoras as it now uses the new upstart
>>>> system, but a quick look at /etc/event.d/rc3 shows an explicit call to
>>>> "exec /etc/rc.d/rc 3". (The OP doesn't mention which version of Fedora
>>>> he has but the new system is set up to emulate the old behaviour).
>>>>
>>>> poc
>>> Well, for all who are interested, I am running FC8 (haven't had time to
>>> do a full system backup to prepare for FC9) and I have checked all all
>>> of the K** and S** files are where they are suppose to be but telinit
>>> doesn't run them all for some reason.  I have chosen to use run level 4
>>> for the backups and it has all of the K** files but only two S** files
>>> (the way I want it) but when I run telinit 4, it only "kills" two or so
>>> and leaves the others running.
>> After your "telinit 4", have you tried "/etc/rc.d/rc 4"?
>>
>> AFAIK, telinit does NOT fire up the /etc/rc.d stuff by itself and that's
>> how the K* and S* stuff get run.
> As has been pointed out what you say is not true. Changes runlevel
> should cause the correct rc* files to run. Check the man page of
> telinit.

While the man page SAYS it "works closely together with the scripts in
the directories /etc/init.d  and /etc/rc{run-level}.d," in my experience
it really doesn't.

Under the classic scheme (F8 and older), /etc/init.d is a symlink to
/etc/rc.d/init.d, which are the TARGETS of symlinks in /etc/rc.d/rc*.d.
/etc/rc.d/init.d contains no K* or S* files at all, so I see no way for
init to selectively run K* or S* files.  /etc/rc.d/rc is a script that
DOES pick up run level changes and invokes the K* and S* scripts
selectively.

With the new F9 mechanism perhaps it does work.  I'm not running F9
yet except in a domU under Xen because, frankly, I don't trust it yet.

> There must bew something else that is wrong.

Perhaps, but I don't see how it can work "as advertised" with the file
layout as it is.  It wouldn't be the first time a man page was
incorrect.

> Are you running it from a virtual terminal as root?

Yes, of course.

----------------------------------------------------------------------
- Rick Stevens, Systems Engineer                      ricks at nerd.com -
- AIM/Skype: therps2        ICQ: 22643734            Yahoo: origrps2 -
-                                                                    -
-                   "The bogosity meter just pegged."                -
----------------------------------------------------------------------




More information about the fedora-list mailing list