Bug 26261 - [poweroff] System reboots instead of halt/poweroff
[poweroff] System reboots instead of halt/poweroff
Product: Red Hat Linux
Classification: Retired
Component: kernel (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Arjan van de Ven
David Lawrence
Florence Gold
Depends On:
  Show dependency treegraph
Reported: 2001-02-05 19:15 EST by P. Beltrani
Modified: 2007-04-18 12:31 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-02-14 01:32:05 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description P. Beltrani 2001-02-05 19:15:11 EST
System info from syslog:

 kernel: BIOS Vendor: Award Software, Inc.
 kernel: BIOS Version: ASUS K7V ACPI BIOS Revision 1007
 kernel: BIOS Release: 07/26/2000
 kernel: Board Vendor: ASUSTeK Computer INC..
 kernel: Board Name: <K7V>.
 kernel: Board Version: REV 1.xx.
 kernel: apm: BIOS version 1.2 Flags 0x03 (Driver version 1.14)

 kernel: ACPI: System description tables found
 kernel: ACPI: System description tables loaded
 kernel: ACPI: APM is already active, exiting

All attempts to shutdown the system via the OS result in a reboot not a
halt or power off.

  shutdown -h now
  init 0
  telinit 0
  halt -p
 result in reboot.

Additional info:

 I needed to replace glibc i686 with the i386 version as a work around for
other issues.  This had no impact on the problem.

The above commands work as expected with RH 7.0 on the same hardware.
Comment 1 Bill Nottingham 2001-02-05 19:30:00 EST
This is probably a kernel problem in how it reboots the machine; the associated
code in SysVinit hasn't changed.
Comment 2 Arjan van de Ven 2001-02-06 05:42:31 EST
Might be ACPI related. (However, using an older kernel, my Asus A7V powers 
down nicely).
Comment 3 Jay Berkenbilt 2001-02-06 13:47:48 EST
I think it is a kernel problem but it may also be an init problem or a glibc
problem.  I was about to report a similar bug but found this in my query. 
Here's some additional input.  I have an ASUS P2B-LS motherboard with BIOS
revision 1012.  It is APM and ACPI-compliant.  The kernel reports:

apm: BIOS version 1.2 Flags 0x03 (Driver version 1.14)

/proc/apm looks sensible, apmd works, etc.

halt -p results in loss the kernel printing "Power Down" and in keyboard input
not working anymore, but power does not go off.  I've always been able to power
down this way in previous releases.

If I boot into single user mode and do this:

umount -a -t noproc
mount -o ro,remount /
strace halt -f -p

the strace output ends with the following:

       LINUX_REBOOT_CMD_RESTART|0x88888888) = 0
kill(1, SIGTSTP)

Perhaps the first line explais why the original reporter of this bug gets a
reboot.  I haven't looked at the init code to see what it's actually doing or
whether this code comes from something in glibc.  Looking at the reboot(2)
manual page and doing what it says results in EINVAL from reboot().  Perhaps the
documentation is out of date or I did it wrong.  The manual page shows reboot()
having four arguments, but strace only shows three.  Hopefully this additional
information will provide some more clues.
Comment 4 Glen Foster 2001-02-06 19:19:39 EST
We (Red Hat) should really try to fix this before next release.
Comment 5 Alexei Podtelezhnikov 2001-02-07 04:56:25 EST
Same problem with MSI 6195 (K7Pro) motherboard...
Comment 6 Arjan van de Ven 2001-02-07 05:09:12 EST
 halt -p results in loss the kernel printing "Power Down" and in keyboard input
 not working anymore, but power does not go off.  I've always been able to power
 down this way in previous releases.
Sounds like ACPI to me.
Comment 7 P. Beltrani 2001-02-07 21:26:51 EST
As ACPI was mentioned, I restarted the system with the
kernel parameter "apm=off"

This results in the following on boot:
 kernel: ACPI: System description tables found
 kernel: ACPI: System description tables loaded
 kernel: ACPI: Subsystem enabled
 kernel: ACPI: System firmware supports: C2
 kernel: ACPI: System firmware supports: S0 S1 S3 S4 S5

With this configuration, attempts to power down with "poweroff" etc. result in
the usual power down display ending with:

Power down
ACPI: S5 failed

Then the system is locked and must be reset or powered off manually.
Comment 8 Arjan van de Ven 2001-02-08 04:59:25 EST
"ACPI: S5 failed" says basically "Ehhh your bios is borked."
Now, this can be the Bioses fault, or a bug in the ACPI code.
Comment 9 Michael K. Johnson 2001-02-08 18:29:10 EST
We are no longer building ACPI support into the kernel, so
this should go away in future kernels.
Comment 10 Michael K. Johnson 2001-02-08 19:34:58 EST
*** Bug 26444 has been marked as a duplicate of this bug. ***
Comment 11 P. Beltrani 2001-02-08 22:28:30 EST
Re: this going away when ACPI is no longer built into the kernel

I know those of you working on this have more clue than I do. Would you help me
understand why you think this is an ACPI issue?

As I understand the log file in the original post, ACPI exits because "APM is
already active" It's not until I turned of APM that I received an actual ACPI error.

Also, for what it's worth, I just built a kernel WITHOUT ACPI support. The
problem is still there. If you care to send me a .config with your build
preferences I would be happy to build a kernel and test it on this hardware.

Comment 12 Jay Berkenbilt 2001-02-11 15:15:49 EST
I hope someone will reopen this bug.  I can't since I was not the poster.

I tried poweroff with the rawhide kernel (no ACPI support) and with
2.4.1 (with ACPI).  The behavior is unchanged -- on my ASUS P2B-LS rev 1012, I
still do not get power down -- just the message and locking keyboard.
Comment 13 P. Beltrani 2001-02-12 17:12:36 EST
Somewhere along the line this was flagged as an ACPI issue. The "fix"  then
became the fact that ACPI support will no longer be included in the kernel builds.

Two of us have built kernels without ACPI support yet the problem is still there.

Could we please take another look at this one?

Comment 14 Arjan van de Ven 2001-02-13 05:29:37 EST
Ok. Not an ACPI issue. The difference between the 7.0 kernel and the
fisher kernel is that the 7.0 kernel has "REAL_MODE_POWEROFF" disabled,
while the fisher kernel has it enabled. It would be real helpful if
someone can confirm changing this option fixes this bug for them.
Comment 15 P. Beltrani 2001-02-13 08:38:51 EST
This worked for my system, ASUS K7V ACPI BIOS Revision 1007

1) Built quick/dirty kernel:
  Created .config using the defaults from "make xconfig".
  The only change from the defaults was
  Built a bzImage.  Did NOT build/install modules

2) Booted with test kernel.

3) poweroff and init 0 work as expected.
Comment 16 Arjan van de Ven 2001-02-13 10:05:56 EST
Thanks for testing + confirming this. Newer kernels will have this change.
Comment 17 Jay Berkenbilt 2001-02-13 11:45:00 EST
I'll test this tonight when I'm at home -- testing power off remotely is pretty
hard! :-) I'll report back with the result regardless.
Comment 18 Jay Berkenbilt 2001-02-14 01:32:02 EST
Building a kernel with REAL_MODE_POWEROFF disabled worked for me too.  Thanks. 
Just for kicks, I also disabled ACPI, so both of these being off works in my
Comment 19 Arjan van de Ven 2001-02-14 04:54:47 EST
Ok. That's enough for me. REAL_MODE_POWEROFF is gone for the next build that
will appear in Rawhide.
Comment 20 Elton Woo 2001-03-11 16:39:49 EST
I reported this to the Wolverine list, and am adding a comment here, in the
hopes that it would
be of use to the development team. My system: AOPEN AX59PRO ATX, rev. 2.35. 
Since installing
the latest updates (including the 2.4.2-0.1.19 kernel), I can halt the system,
but not power *off*.
Comment 21 Arjan van de Ven 2001-03-11 16:49:39 EST
What was the last working kernel ?
and could you please try adding
to the lilo.conf file ?
Comment 22 Elton Woo 2001-03-12 16:17:52 EST
The previous working kernel that I had in Wolverine was 2.4.1.-0.1.9  For
the moment, I cannot report on the success or failure WRT the amendment to my
lilo.conf file, which I have edited per your suggestion.
Comment 23 Elton Woo 2001-03-12 17:20:35 EST
My lilo.conf now contains:

	append="scd0=ide-scsi apm=realmode"

Still no luck. A "shutdown" merely terminates all services, but does NOT power
the machine.
Comment 24 Elton Woo 2001-03-14 12:10:46 EST
I've just upgraded to kernel 2.4.2.-0,.1.25. The system now powers off without
the need
to add "apm=realmode" ro my lilo.conf.

Note You need to log in before you can comment on or make changes to this bug.