[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [Pkg-sysvinit-devel] Bug#339955: sysv-rc: /etc/init.d/*.sh should be sourced in runlevel S



On Sat, 19 Nov 2005, Petter Reinholdtsen wrote:
> What a strange thing for policy to specify.  :)

On the contrary.

> This will make it impossible to speed up the rcS.d boot by running
> scripts in parallel.  It does not sound sensible to me.

rc.S scripts have always had the capability of setting environment
variables.  We have to be *very* careful here before such a change is
made.  This means auditing *ALL* rcS scripts in Debian to know which ones
need this capability, and what it is used for.

We will get enough of a speedup by runining runlevel 2 in parallel, even if
parts of rcS have to be serialized.

> Well, I would be surprised if any of the scripts used in rcS.d uses
> exit, as this would break the boot.

They don't, AFAIK.  And it is a critical bug to do so, anyway.

> > Note: I believe that "return" should work to exit from a script both
> > when sourced and when executed but perhaps someone with a copy of
> > POSIX could confirm.
> 
> As far as I know, return will exit the script if used in the 'outer'
> scope.

AFAIK, that's correct.

-- 
  "One disk to rule them all, One disk to find them. One disk to bring
  them all and in the darkness grind them. In the Land of Redmond
  where the shadows lie." -- The Silicon Valley Tarot
  Henrique Holschuh



Reply to: