Re: Power Off on Halt - solution

=?ISO-8859-1?Q?Johan_Myr=E9en?= (jem@vistacom.fi)
Wed, 18 Mar 1998 23:23:00 +0200 (EET)


On 18 Mar 1998, Robert Bihlmeyer wrote:

> >> This started happening when I compiled a new init (2.72) with
> >> glibc (2.0.6), so the cause could be either init or glibc. (I
> >> suspect glibc.)
>
> Bernhard> Can't be glibc... I'm having the same problem on a ATX K6
> Bernhard> running sysvinit 2.73 and glibc
> Bernhard> 2.0.7 as well as a Medion Notebook running sysvinit 2.73
> Bernhard> and libc 5.4.44.
>
> You're all sure, that you use UP kernels?

Yes. I have now found out what was wrong. Just a normal case
of not Reading the Friendly Manual...

I tried to invoke /sbin/halt -p or /sbin/poweroff directly
from /etc/inittab:

kb::kbrequest:/sbin/halt -p -i

Silly me. When halt is called when the system is not in
runlevel 0 or 6, shutdown will be called instead, with the
flag -h. The -p flag is ignored. The runlevel 0 script is then
called, and that script ended in a /sbin/halt (without the -p)
on my machine. Adding the -p switch fixed the problem.

Contrary to what some people suggested, no patches to any
program, library or kernel are needed. (This is true at least
for kernel 2.1.x, libc 2.0.x and a relatively recent sysvinit
( >= 2.7.2?))

Hope this helps someone.

Johan Myreen
jem@iki.fi

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu