[vox-tech] Redhat 8.0 shutdown does not power off.

Mike Simons vox-tech@lists.lugod.org
Mon, 09 Jun 2003 14:00:22 -0400


--CSNFvL6ilyiKL/Hs
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Fri, Jun 06, 2003 at 05:35:58PM -0700, Jim Angstadt wrote:
> > - the machine never powered itself off (beside the two times above
> >   and the one time I mentioned) since you started this thread?  (yes
> >   or no)
>=20
> Yes.
>=20
> >=20
> > - the machine *did* power itself off the three
> > times mentioned above?
> >   (yes or no)
>=20
> Yes.

okay good.


> The results are mixed:
>=20
> With just 'single' added to boot parms:
>=20
> 1. s-u-o led to off
> 2. s-u-o led to reboot
> 3. s-u-o led to off
> 4. s-u-o led to off
> 5. s-u-o led to off
> 6. s-u-o led to off
>=20
> With 'single apm=3Drealmode_power_off' added:
>=20
> 1. s-u-o led to off
> 2. s-u-o led to off
> 3. s-u-o led to reboot
> 4. s-u-o led to off
> 5. s-u-o led to off
> 6. s-u-o led to off

  This is interesting.  It powers off _most_ of the time regardless of
the realmode_power_off setting.  It _seems_ that something that starts=20
up during a full system boot is causing the kernel to fail to shutdown
correctly... which is strange.


> To satisfy my own curosity, I ran=20
>    grub> halt=20
> six times in a row.  All resulted in a power off.

  I don't think there are enough samples to say for sure... it only
failed to shutdown 2 out of 18 tries, for all three methods.


  Also I've looked into the grub and Linux kernel source, they seem to
be calling the exact same APM function, although GRUB works in realmode
and the kernel works in either realmode or 32bit mode, depending on the
setup... it is possible there is a kernel bug, but in the apm.c there have=
=20
been only two minor changes from the 2.4.18 you are running to the
current 2.5.70 so if it is no one else is complaining about it.

  From what I can tell the two patches don't seem to apply to power off,
one deals with bioses that skew the clock without reporting it and
the other is to allow APM to be enabled on SMP machines (which has
been disabled for ages).

  Since grub and the kernel call seem to do very similar things I think=20
that if you try halt a dozen times in grub it would fail sometimes
too... if grub fails to halt it would hint strongly that your machine=20
BIOS or hardware is acting flaky (like the power supply which Rob Rogers)=
=20
suggested in this thread a long time back.
  If you try grub a bunch and it always turns off power it doesn't
really help narrow down the problem to kernel software, BIOS, or
hardware bug (since the kernel could still be doing something correct
but the BIOS might not like it).  Someone more familiar with how APM
works and what the kernel is doing would have to comment...


If you really want to get it fixed I would suggest:
- Upgrading the kernel to the latest stable version (2.4.20),=20
  verifying it happens there...
- Writing up that halt from grub works 100% and halt sysrq-O from kernel=20
  works frequently but not always when booted into single user mode,=20
  booting into Redhat 8.0 greatly lowers the number of times power off=20
  really happens.  Then sending that to the kernel mailing list or=20
  the APM maintainer:
=3D=3D=3D
APM DRIVER
P:      Stephen Rothwell
M:      sfr@canb.auug.org.au
L:      linux-laptop@vger.kernel.org
W:      http://www.canb.auug.org.au/~sfr/
S:      Supported
=3D=3D=3D

  It looks like it would be possible to copy the code from grub into=20
the kernel so they are doing the *exact* same instructions in realmode=20
poweroff... but I don't really like messing with assembly code so I=20
would be wanting some sort of pay to figure that out and test it here.

  Over list I'd be willing to help with the kernel upgrade to 2.4.20
with and the writeup for the APM people.

    Good Luck,
      Mike Simons

--=20
GPG key: http://simons-clan.com/~msimons/gpg/msimons.asc
Fingerprint: 524D A726 77CB 62C9 4D56  8109 E10C 249F B7FA ACBE

--CSNFvL6ilyiKL/Hs
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE+5Ms14Qwkn7f6rL4RAteXAJ4n5mFlEPd+z1H4iZB9Ou8hK4UgjQCfXTvi
n0HRqj/5pGe3cjnN45OpDp4=
=e5L7
-----END PGP SIGNATURE-----

--CSNFvL6ilyiKL/Hs--