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

Re: Possible ITP: Rescue Package

On Mon, Jul 26, 1999 at 05:40:51PM -0400, Dale Scheetz wrote:
> Well, actually I was hoping not to use either ;-)
> > > but I don't
> > > think this is a good idea, because in a normal system you don't want
> > > little tools running around with big memory footprints.
> > 
> > This is the only way for "init", because you can only change it at the
> > bootprompt which defeats the idea (think of newbies, or remote
> > administration).
> I hadn't thought about init, but I guess I _do_ need to include it,
> possibly as the only true replacement. There is only one copy of init
> running isn't there? So it's a one time penalty? To get the benefit of
> recovery, you have to install it, and yes, I guess the only way to make it
> work right would be diversion, but I'd really prefer something better.
 Except when you are changing runlevels via [tel]init <runlevel>, but that's
 momentary, and telinit can be dynamicly linked.  (If you're recovering, you
 should be plently happy that a c-a-d works.)

If you wanted to be really good, have init try to run a dynamicly linked
program ('int main(){return 0;}' will do fine), and exec a dynamicly linked
version of itself if it works.  That may be more work then it's worth, but
it would allow a static init with no penalty during normal use.

> You implied that there was a way to point the kernel at an alternate init.
> Is this something that could be done in a lilo entry, so that a "rescue"
> image and init could be isolated in this fashion?
image = /boot/kernels/rescue
 append = init=/bin/s_ash

(Or whatever init you want to use.)(This assumes, however, that you are
using LILO.  If you aren't, use a friggin rescue floppy.  <G>)  Note that
this implies that you were planning on supplying a rescue kernel image,
which is another load of problems that you probably don't want to think
about... so you probably didn't mean to imply it.

> Can the
> static versions of the programs be bound to a "non-standard" rescue port
Better, use a wrapper.  Change the inetd entry try to run the normal one,
and if that fails, log it and try the static version.  (That way, you don't
have to remember what the weird recovery port for telnet is the one time you
really need it.)  (And if you could read the docs, you wouldn't need to be
running the recovery version.)

Still better is to have your static inetd do a s|sbin/|sbin/s_| on the names
of the (psudo-)daemons.

Or just forget about remote admin unless you do it with serial terminal,
which is how you should do it, because you needed it to change init and/or
boot the LILO "rescue" image anyway.

	-=- James Mastros
Aren't corner cases fun!

Reply to: