Page 1 of 1

Puppy 4.3 APM won't power off [solved]

Posted: Wed 23 Sep 2009, 22:51
by noabody
Racked my brains on this one. Finally found the key to the answer here: http://www.rigacci.org/docs/biblio/onli ... Power.html

Essentially some older APM based machines won't power off if they don't have the apm=power-off kernel option. As that web page states, the kernel option on the boot line is only applicable if apm was built into the kernel. That is clearly not the case with the 2.6.30.5 in Puppy 4.3.

grep apm /etc/rc.d/rc.*

revealed that /etc/rc.d/rc.sysinit has a modprobe apm line.
As per the instructions on the noted website, I altered this line to read as modprobe apm power_off=1.

For me this was line 247 and it originally looked like:
[ ! -d /proc/acpi ] && modprobe apm #v406
changed to
[ ! -d /proc/acpi ] && modprobe apm power_off=1 #v406

So don't waste your time with kernel boot options for loaded modules when you need an apm power down workaround.

Hope this helps somebody, I figured the change had to occur on the first instance of modprobe apm so I don't think there is any other solution to this problem.

Posted: Thu 24 Sep 2009, 03:01
by Gunny
You could edit your GRUB configuration file '/boot/grub/menu.lst' by adding acpi=force

kernel /boot/vmlinuz root=/dev/sda1 ro vga=normal acpi=force

Posted: Thu 24 Sep 2009, 23:10
by noabody
Sorry but I was quite vague on my initial post. It is accurate if you have a problem computer that only supports APM. For me this was an Inspiron 7000 laptop. Dell simply did not release an ACPI bios for it. I tried almost every conceivable ACPI and APM option on the kernel boot line of /boot/grub/menu.lst and none of them worked.

For me I get errors when I try to modprobe acpi. I have /proc/apm, dmesg indicates that APM is loaded - pretty much everything indicates that I have an APM machine so no ACPI option will have any effect on it.

That's why I made this forum post. There are certain things that just work for 99% of everybody out there. Every forum search I made said use acpi=force but it didn't do a thing for me. My computer would shut down right to the point where it said "system halted" and just remain on. I knew linux could power the computer off because I had it working in Puppy 4.2 but I think apm was built into that kernel so the command line option apm=power-off worked. I do remember that it took quite some time to get it working in Puppy 4.2 so maybe the solution was the same but I never bothered to post what I did and then I forgot about it - until I decided to do a fresh install of 4.3.

So for the poor folks out there stuck with an ancient APM based computer that needs that magical power-off workaround. Hopefully you'll find this post regardless of what linux distribution you are using. And hopefully I'll find it again the next time I forget what I did to fix it.

Posted: Fri 25 Sep 2009, 00:02
by davids45
G'day noabody,

Thanks for finding this line 247 fix for computers that only half turn-off with 4.3 (in my case, Pups 4.24 and 4.25).
My non-ancient Medion 8818 desktop would not shut down with 4.3 betas (and a few other newer kernel Pups) whereas my older Medion 8383 desktop was fine.
With these Pups, I have to boot the 8818 using acpi=off and I assumed this incomplete shut down was a consequence of this start-up necessity.

Thank you for your great sleuthing, even for some newish computers!

David S.

Posted: Tue 27 Oct 2009, 05:39
by James186282
I'm using a Compaq Armada M700 laptop and it won't shut down unless I do a control alt backspace to dump the screen.

I've tried all the suggestions on this link but??? This did work in previous versions of puppy. I'm using 4.30 now and its really annoying me.

Thanks for any ideas.

Posted: Tue 27 Oct 2009, 07:28
by rjbrewer
My laptop powers off fine, but pc says "system halted".

A quick push on the power button turns the pc off safely.

Posted: Tue 27 Oct 2009, 14:51
by James186282
I found the solution after searching other threads. It seems that the screen needed to sleep for a second then kill X in a different way. Happily it works perfectly as this was very "widowesc" having had a number of machines that would not shut down. VERY annoying. I rather wish our OS was able to just shut off in an instant but I have to admit waiting 5 or 6 seconds is a HUGE improvement over the minutes of grinding that the Windows os seems to need to do to get ready for its next 10 minute start up. SIGH...

Anyhow, consider this SOLVED.

Posted: Sat 14 Nov 2009, 15:35
by olsonm3915
noabody wrote:Sorry but I was quite vague on my initial post. It is accurate if you have a problem computer that only supports APM. For me this was an Inspiron 7000 laptop. Dell simply did not release an ACPI bios for it. I tried almost every conceivable ACPI and APM option on the kernel boot line of /boot/grub/menu.lst and none of them worked.
[snip]

So for the poor folks out there stuck with an ancient APM based computer that needs that magical power-off workaround. Hopefully you'll find this post regardless of what linux distribution you are using. And hopefully I'll find it again the next time I forget what I did to fix it.
I'm typing this on a Dell Inspiron 7000 laptop with a 300MHz Pentium II processor. Your information was exactly what I needed to get my old yet still useful system to automatically power off. Thank you!

Posted: Sat 14 Nov 2009, 15:37
by olsonm3915
noabody wrote:Sorry but I was quite vague on my initial post. It is accurate if you have a problem computer that only supports APM. For me this was an Inspiron 7000 laptop. Dell simply did not release an ACPI bios for it. I tried almost every conceivable ACPI and APM option on the kernel boot line of /boot/grub/menu.lst and none of them worked.
[snip]

So for the poor folks out there stuck with an ancient APM based computer that needs that magical power-off workaround. Hopefully you'll find this post regardless of what linux distribution you are using. And hopefully I'll find it again the next time I forget what I did to fix it.
I'm typing this on a Dell Inspiron 7000 laptop with a 300MHz Pentium II processor. Your information was exactly what I needed to get my old, but still useful system to automatically power off. Thank you!

Posted: Fri 27 Nov 2009, 20:12
by rerwin
noabody,
Thanks for posting your solution to the shutdown problem. It works on my ~1997 Aptiva. I have added a comment to Issue 21 ("acpi on/of/force shutdown problems") of the new puppy 4.4CE bug tracking system, suggesting this as a fix that might be made permanent, unless anyone knows why it should not be -- or if some conditions apply.

http://code.google.com/p/puppy-developm ... tail?id=21
Richard

apm power_off=1 worked - two questions

Posted: Wed 16 Dec 2009, 22:52
by Mitchellray
Hello,
'power_off=1 worked' on my desktop.
I had to turn on the APM switch in bios.
Oddly, I had a similar problem when I started using Slackware a while back, and acpi=off added (believe it that I can not remember where I put it) seemed to solve the problem.

Two question:
1. Where is the script command for system shutdown if acpi=off and apm power_off=1 are not present in 4.3.1?
I ask because Puppy could already shutdown my Asus1005HA without adding those commands.

2. Where is that /boot/grub/menu.lst file (4.3.1), because I would like to try that approach to see if it would work (even though you found one solution) since I know my machine has acpi?
Mitchellray

Posted: Wed 23 Dec 2009, 22:43
by bugman
THANK YOU

the computer i am setting up puppy 4.31 on does not really shut off if you push the button [it hibernates], i've been unplugging the damn thing--until now!

Code: Select all

power_off=1
8)

Posted: Mon 01 Mar 2010, 17:01
by yorkiesnorkie
noabody wrote:
Racked my brains on this one. Finally found the key to the answer here: http://www.rigacci.org/docs/biblio/onli ... Power.html

Essentially some older APM based machines won't power off if they don't have the apm=power-off kernel option. As that web page states, the kernel option on the boot line is only applicable if apm was built into the kernel. That is clearly not the case with the 2.6.30.5 in Puppy 4.3.

grep apm /etc/rc.d/rc.*

revealed that /etc/rc.d/rc.sysinit has a modprobe apm line.
As per the instructions on the noted website, I altered this line to read as modprobe apm power_off=1.

For me this was line 247 and it originally looked like:
[ ! -d /proc/acpi ] && modprobe apm #v406
changed to
[ ! -d /proc/acpi ] && modprobe apm power_off=1 #v406

So don't waste your time with kernel boot options for loaded modules when you need an apm power down workaround.

Hope this helps somebody, I figured the change had to occur on the first instance of modprobe apm so I don't think there is any other solution to this problem.
Brilliant!

I have puppy 4.3.0 with the service pack installed. This was the first puppy that wouldn't shut down all the way on its own.

I modified line 249 of /etc/rc.d/rc.sysinit
[ ! -d /proc/acpi ] && modprobe apm #v406
changed to
[ ! -d /proc/acpi ] && modprobe apm power_off=1 #v406
...and then I shut down. Of course it didn't work that time. However, on the next reboot after I was done with my computer and shut down using the menu, it actually shut down my PC, which is an IBM 380 XD with mmx.

So, THANK YOU noabody! This is an awesome bugfix.

Yorkiesnorkie
:-)

Posted: Sun 03 Oct 2010, 19:55
by Bud
Awesome, thank you noabody, this was driving me nuts and substituting that line did the job! Old Vaio shuts down like a clam. :)

Posted: Sat 10 Mar 2012, 22:15
by JesseKnows
This worked for my Dell Latitude CPi (P2 366MHz) with Puppy 4.3.1.

Thanks, OP!

Posted: Sun 15 Apr 2012, 19:10
by Okeh
This did not work on my ancient NEC desktop with AMD K6-2 processor, 256 megs of ram. I checked the bios and found that APM was not enabled. So I enabled that, but still would not fully shut down. Adding apm=on did the trick.

Its running 4.3.1.

This computer came with Windows 98, and when I upgraded it to Windows 2000 the shutdown problem started. Obviously an acpi/apm issue under windows too.

Posted: Mon 16 Apr 2012, 08:25
by Laie
Okeh wrote:... Adding apm=on did the trick ...
Where did you add "apm=on"? In the menu.lst? Which line?
My old Medion MD96067 won't shut down, stops but leaves the screen on with the last line saying "Power down". The BIOS ist very, very simple and has no option to turn apm on or off.

Posted: Mon 16 Apr 2012, 21:22
by Okeh
Where did you add "apm=on"? In the menu.lst? Which line?


I added it in the menu.1st file. Its a startup parameter or switch for "puppy".

I kept the rc.sysnit change as well, because after my last posting, removing it after the other changes caused the computer to hang again. So it seems - for some reason - I need to enable apm in the bios, use apm=on and use [ ! -d /proc/acpi ] && modprobe apm power_off=1 #v406 since none of them worked independently of the other! I'm sure someone more knowledgeable than I will tell me this can't be so!