LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices

Reply
 
LinkBack Search this Thread
Old 01-14-2004, 11:15 AM   #1
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,358

Rep: Reputation: 50
Shutdown could not power off


Hi folks,

Debian (testing / unstable)

# shutdown -h now
will not power-off. I have to manually switch off the PC

# dmesg | grep acpi
No printout

# modprobe acpi
modprobe: Can't locate module acpi
# modprobe apm
No printout

# apmd
It appears that an instance of apmd is already running as process 580.
If in reality no instance of apmd is running, remove /var/run/apmd.pid.
lo

Kindly advise how to fix this problem

TIA

B.R.
satimis
 
Old 01-15-2004, 02:12 PM   #2
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,513

Rep: Reputation: 62
Re: Shutdown could not power off

Quote:
Originally posted by satimis
Hi folks,

Debian (testing / unstable)

# shutdown -h now
will not power-off. I have to manually switch off the PC

# dmesg | grep acpi
No printout

# modprobe acpi
modprobe: Can't locate module acpi
# modprobe apm
No printout

# apmd
It appears that an instance of apmd is already running as process 580.
If in reality no instance of apmd is running, remove /var/run/apmd.pid.
lo

Kindly advise how to fix this problem

TIA

B.R.
satimis
It looks like the module loads fine what do you have for your settings in the /etc/lilo.conf? In mine in the append line I had to put apm=on and run /sbin/lilo to write the changes to the disk.
Code:
append="hdc=ide-scsi apm=on"
In my /etc/modutils/apm I had to make a change then run update-modules to update the /etc/modules.conf and use MAKEDEV apm in the /etc/misc/ directory for the apm_bios device that was missing.
Code:
>$ cat /etc/modutils/apm
alias char-major-10-134 apm
alias /dev/apm_bios             /dev/misc/apm_bios
alias /dev/misc/apm_bios        apm
#alias /dev/apm_bios            apm
# Added by me for real mode power off

options apm power_off=1
You might also want to check in your BIOS and make sure that the machine is actually set to power down instead of suspend as well.
 
Old 01-15-2004, 11:25 PM   #3
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,358

Original Poster
Rep: Reputation: 50
Re: Re: Shutdown could not power off

Quote:
Originally posted by HappyTux
It looks like the module loads fine what do you have for your settings in the /etc/lilo.conf? In mine in the append line I had to put apm=on and run /sbin/lilo to write the changes to the disk.
Code:
append="hdc=ide-scsi apm=on"
In my /etc/modutils/apm I had to make a change then run update-modules to update the /etc/modules.conf and use MAKEDEV apm in the /etc/misc/ directory for the apm_bios device that was missing.
Code:
>$ cat /etc/modutils/apm
alias char-major-10-134 apm
alias /dev/apm_bios             /dev/misc/apm_bios
alias /dev/misc/apm_bios        apm
#alias /dev/apm_bios            apm
# Added by me for real mode power off

options apm power_off=1
You might also want to check in your BIOS and make sure that the machine is actually set to power down instead of suspend as well.
Hi,

Thanks for your advice.

# cat /etc/lilo.conf (original)
boot=/dev/hda
root=/dev/hda1
install=/boot/boot.b
map=/boot/map
image=/vmlinuz
label=Linux
initrd=/initrd.img

# cat /etc/lilo.conf (change made)
boot=/dev/hda
root=/dev/hda1
install=/boot/boot.b
map=/boot/map
image=/vmlinuz
label=Linux
initrd=/initrd.img
append="spm=on"

# /sbin/lilo
Warning: '/proc/partitions' does not match '/dev' directory structure.
Name change: '/dev/ide/host0/bus0/target0/lun0/disc' -> '/dev/hda'
Added Linux *

# cat /etc/modutils/apm (original)
alias char-major-10-134 apm
alias /dev/apm_bios /dev/misc/apm_bios
alias /dev/misc/apm_bios apm

# cat /etc/modutils/apm (change made)
alias char-major-10-134 apm
alias /dev/apm_bios /dev/misc/apm_bios
alias /dev/misc/apm_bios apm
options apm power_off=1

# update-modules /etc/modules.conf

# ls -al /etc/misc/
ls: al: No such file or directory
ls: /etc/misc/: No such file or directory

# shutdown -h now
# halt -p
# halt
all can't switch off

BIOS (default)
Power Management Setup
ACPI (Enabled)

Tired changing "ACPI (Disabled)

Still same result - can't poweroff

B.R.
satimis
 
Old 01-15-2004, 11:59 PM   #4
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,513

Rep: Reputation: 62
Re: Re: Re: Shutdown could not power off

Quote:
Originally posted by satimis

# update-modules /etc/modules.conf
This should be just update-modules ran after having made the changes in the /etc/modutils/apm.
Quote:
# ls -al /etc/misc/
ls: al: No such file or directory
ls: /etc/misc/: No such file or directory
Sorry damn typo I should have checked the post more carefully. You should be looking in the /dev/misc/ directory for the apm_bios device.
Code:
HappyTux:/home/stephen# ll /dev/misc/apm_bios
crw-rw----    1 root     root      10, 134 2003-08-30 19:09 /dev/misc/apm_bios
If it is not there then you need to use the MAKEDEV apm command in the /dev/misc/ directory.
Code:
HappyTux:/dev/misc# MAKEDEV -n apm
create apm_bios c 10 134 root:root 0660
Remove the -n in the line to have the device actually created.

Quote:
# shutdown -h now
# halt -p
# halt
all can't switch off

BIOS (default)
Power Management Setup
ACPI (Enabled)

Tired changing "ACPI (Disabled)

Still same result - can't poweroff

B.R.
satimis [/B]
Try it with the ACPI set to disabled although I think it would be better if you could find a power down instead of suspend like is in my BIOS. Also when you boot can you see in the messages the apmd daemon starting up. And in the append line in your lilo.conf you posted above now that I looked at it again you have a typo there it has a "S" (spm=on) instead of an "A" (apm=on).
 
Old 01-16-2004, 06:52 AM   #5
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,358

Original Poster
Rep: Reputation: 50
Re: Shutdown could not power off

Hi HappyTux,

Thanks for your advice.

I ran
# update-modules /etc/modules.conf
after editing /etc/modutils/apm

Quote:
You should be looking in the /dev/misc/ directory for the apm_bios device.
# ls -al /dev/apm_bios
crw-rw---- 1 root root 10, 134 Dec 23 17:23 /dev/apm_bios

There is no '/misc/' existing.

Quote:
code:HappyTux:/dev/misc# MAKEDEV -n apm
create apm_bios c 10 134 root:root 0660

Remove the -n in the line to have the device actually created.
How to remove '-n' from /dev/apm_bios ?

Quote:
Also when you boot can you see in the messages the apmd daemon starting up.
Very strange I could not discover the boot.log of today

# ls /var/log/
boot
boot.0
boot.1.gz
boot.2.gz
boot.3.gz
boot.4.gz

# cat /var/log/boot
Fri Jan 9 15:04:55 2004: Starting advanced power management daemon: apmd.

# cat /var/log/daemon.log
.....
Jan 16 19:20:14 debian apmd[578]: apmd 3.2.0 interfacing with apm driver 1.16 and APM BIOS 1.2
.....

Quote:
And in the append line in your lilo.conf you posted above now that I looked at it again you have a typo there it has a "S" (spm=on) instead of an "A" (apm=on).
Sorry, it was a typing mistake on my previous posting.

Quote:
Try it with the ACPI set to disabled
Yes, I re-checked all and then tried 'shutdown -h now' again with the same result. Can't power off

B.R.
satimis
 
Old 01-16-2004, 08:39 AM   #6
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,358

Original Poster
Rep: Reputation: 50
Re: Re: Re: Re: Shutdown could not power off

Quote:
Originally posted by HappyTux
This should be just update-modules ran after having made the changes in the /etc/modutils/apm.

Sorry damn typo I should have checked the post more carefully. You should be looking in the /dev/misc/ directory for the apm_bios device.
Code:
HappyTux:/home/stephen# ll /dev/misc/apm_bios
crw-rw----    1 root     root      10, 134 2003-08-30 19:09 /dev/misc/apm_bios
If it is not there then you need to use the MAKEDEV apm command in the /dev/misc/ directory.
Code:
HappyTux:/dev/misc# MAKEDEV -n apm
create apm_bios c 10 134 root:root 0660
Remove the -n in the line to have the device actually created.



Try it with the ACPI set to disabled although I think it would be better if you could find a power down instead of suspend like is in my BIOS. Also when you boot can you see in the messages the apmd daemon starting up. And in the append line in your lilo.conf you posted above now that I looked at it again you have a typo there it has a "S" (spm=on) instead of an "A" (apm=on).
Hi HappyTux

Further to my last posting

At booting, on the running screen I saw;

Starting Advance Power Management : apmd

B.R.
satimis
 
Old 01-16-2004, 01:46 PM   #7
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,513

Rep: Reputation: 62
Re: Re: Re: Re: Re: Shutdown could not power off

Quote:
Originally posted by satimis
Hi HappyTux

Further to my last posting

At booting, on the running screen I saw;

Starting Advance Power Management : apmd

B.R.
satimis
Ok so the daemon gets started then is it in use:
Code:
>$ lsmod
Module                  Size  Used by    Tainted: P
snd-pcm-oss            36708   0 (autoclean)
snd-mixer-oss          11408   1 (autoclean) [snd-pcm-oss]
nvidia               1628672  11 (autoclean)
sg                     24700   0 (autoclean)
apm                     9256   2 (autoclean)
snd-emu10k1            60692   6
snd-pcm                55776   3 [snd-pcm-oss snd-emu10k1]
[snip..]
You should see the module in use. If you have the ACPI compiled as a module in the kernel it may still be getting used or interfering with the use of the APM so you may have to try acpi=off when you boot at the lilo screen eg. just type Linux acpi=off change the Linux for whatever name appears in the menu selection for the kernel you are booting. Just to be sure here you have made the missing device and the changes that I have suggested to you here right?
 
Old 01-16-2004, 09:01 PM   #8
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,358

Original Poster
Rep: Reputation: 50
Re: Re: Re: Re: Re: Re: Shutdown could not power off

Quote:
Originally posted by HappyTux
Ok so the daemon gets started then is it in use:
Code:
>$ lsmod
Module                  Size  Used by    Tainted: P
snd-pcm-oss            36708   0 (autoclean)
snd-mixer-oss          11408   1 (autoclean) [snd-pcm-oss]
nvidia               1628672  11 (autoclean)
sg                     24700   0 (autoclean)
apm                     9256   2 (autoclean)
snd-emu10k1            60692   6
snd-pcm                55776   3 [snd-pcm-oss snd-emu10k1]
[snip..]
You should see the module in use. If you have the ACPI compiled as a module in the kernel it may still be getting used or interfering with the use of the APM so you may have to try acpi=off when you boot at the lilo screen eg. just type Linux acpi=off change the Linux for whatever name appears in the menu selection for the kernel you are booting. Just to be sure here you have made the missing device and the changes that I have suggested to you here right?
Hi,

Sorry 'acpi' was not there

$ lsmod | grep acpi
$ lsmod | grep ACPI
$ lsmod | grep apm
apm 8492 2 (autoclean)

B.R.
satimis
 
Old 01-20-2004, 02:34 PM   #9
fatcat
LQ Newbie
 
Registered: Jan 2004
Posts: 10

Rep: Reputation: 1
Thumbs up

I had the exact same problem after upgrading kernel from 2.4 to 2.6.
I managed to fix it by linking apm into kernel instead of using it as a module.
Don't really know if that is a bug or a feature ?
 
Old 01-20-2004, 11:41 PM   #10
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,358

Original Poster
Rep: Reputation: 50
Quote:
Originally posted by fatcat
I had the exact same problem after upgrading kernel from 2.4 to 2.6.
I managed to fix it by linking apm into kernel instead of using it as a module.
Don't really know if that is a bug or a feature ?
Hi,

Could you please advise in more detail how to link apm to kernel.

TIA

B.R.
satimis
 
Old 01-22-2004, 12:26 AM   #11
fatcat
LQ Newbie
 
Registered: Jan 2004
Posts: 10

Rep: Reputation: 1
This is how my .config file looks:
grep APM .config
# Power management options (ACPI, APM)
# APM (Advanced Power Management) BIOS Support
CONFIG_APM=y
# CONFIG_APM_IGNORE_USER_SUSPEND is not set
# CONFIG_APM_DO_ENABLE is not set
CONFIG_APM_CPU_IDLE=y
# CONFIG_APM_DISPLAY_BLANK is not set
CONFIG_APM_RTC_IS_GMT=y
# CONFIG_APM_ALLOW_INTS is not set
# CONFIG_APM_REAL_MODE_POWER_OFF is not set

grep ACPI .config
# Power management options (ACPI, APM)
# ACPI (Advanced Configuration and Power Interface) Support
# CONFIG_ACPI is not set

the meaning full point is
CONFIG_APM=y
instead of
CONFIG_APM=m

I use make gconfig to adjut my kernel, but there are many other methods.
I hope this helps ?
 
Old 01-28-2004, 11:09 AM   #12
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,358

Original Poster
Rep: Reputation: 50
Quote:
Originally posted by fatcat
This is how my .config file looks:
grep APM .config
# Power management options (ACPI, APM)
# APM (Advanced Power Management) BIOS Support
CONFIG_APM=y
# CONFIG_APM_IGNORE_USER_SUSPEND is not set
# CONFIG_APM_DO_ENABLE is not set
CONFIG_APM_CPU_IDLE=y
# CONFIG_APM_DISPLAY_BLANK is not set
CONFIG_APM_RTC_IS_GMT=y
# CONFIG_APM_ALLOW_INTS is not set
# CONFIG_APM_REAL_MODE_POWER_OFF is not set

grep ACPI .config
# Power management options (ACPI, APM)
# ACPI (Advanced Configuration and Power Interface) Support
# CONFIG_ACPI is not set

the meaning full point is
CONFIG_APM=y
instead of
CONFIG_APM=m

I use make gconfig to adjut my kernel, but there are many other methods.
I hope this helps ?
Hi fatcat.

Debian - unstable

# grep APM .config
grep: .config: No such file or directory

# grep APM .conf
grep: .conf: No such file or directory

# grep ACPI .config
grep: .config: No such file or directory

# grep ACPI .conf
grep: .conf: No such file or directory

I have
"libextutils-pkgconfig-perl" and
"libapache-dbilogconfig-perl "
installed but could not get 'gconfig' started

# locate gconfig
/usr/bin/gconfigger

# /usr/bin/gconfigger
no response.

Kindly advise which package I need to install.

OR is it a command line application or a GUI application

TIA

B.R.
satimis
 
Old 02-13-2004, 04:52 PM   #13
White R4bbit
Member
 
Registered: Aug 2003
Location: Italy
Distribution: Debian sid 2.6.1
Posts: 54

Rep: Reputation: 15
I have the same problem with kernel 2.6.x; this is my kernel config section:
Code:
[sly@sid]~/download/cdrdao $grep APM /usr/src/linux/.config
# Power management options (ACPI, APM)
# APM (Advanced Power Management) BIOS Support
CONFIG_APM=y
# CONFIG_APM_IGNORE_USER_SUSPEND is not set
# CONFIG_APM_DO_ENABLE is not set
# CONFIG_APM_CPU_IDLE is not set
# CONFIG_APM_DISPLAY_BLANK is not set
# CONFIG_APM_RTC_IS_GMT is not set
# CONFIG_APM_ALLOW_INTS is not set
CONFIG_APM_REAL_MODE_POWER_OFF=y
I also tried all the tricks displayed in this thread (MAKEDEV, lilo options, ACPI is =n in the kernel), but no results.
 
Old 02-14-2004, 11:05 AM   #14
White R4bbit
Member
 
Registered: Aug 2003
Location: Italy
Distribution: Debian sid 2.6.1
Posts: 54

Rep: Reputation: 15
It works perfectly with ACPI and disabling APM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Power off after shutdown dukeem Slackware 15 11-30-2010 10:08 AM
Shutdown and power off bwtoh Linux - Newbie 4 11-02-2006 02:48 PM
No power down after shutdown (Mandrake) JohnA Linux - Hardware 14 02-24-2005 01:47 AM
Power Button for Shutdown gokul Linux - Hardware 4 01-24-2004 12:40 PM
Shutdown with power button hriosm Linux - Hardware 4 06-06-2003 02:43 PM


All times are GMT -5. The time now is 10:35 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration