/etc/init.d in the default $PATH ?

Thomas M Steenholdt tmus at tmus.dk
Mon Jan 29 08:17:56 UTC 2007


Florin Andrei wrote:
> Jeffrey C. Ollie wrote:
>>
>> One problem is that many of the init scripts have names that conflict
>> with programs on the path.  For example, if you type "sshd", are you
>> running the binary in /usr/sbin or are you running the init script
>> in /etc/init.d?  There are numerous other examples.
> 
> That's a pretty good reason. I agree.
> 

Although I'd hate to go down that path (at least without a few 
divertions first), distros like SUSE creates a symbolic link to a the 
init.d/* scripts in /sbin (or /usr/sbin - I can't remember) called 
rc<scriptname> that can be used for this kind of thing.

But out /sbin/service command creates a locked down environment for the 
init-scripts to run in, which means that :

service sshd start != /etc/init.d/sshd start

If we wanted something like this, i guess we should try to enforce the 
source of a env cleaning script as the first line in all scripts.

Just a thought

/Thomas




More information about the fedora-devel-list mailing list