# [SOLVED] Problem with shutdown

## iMexus

Hello, gentoo users!)

I installed the gentoo system two or three days ago (everything according to amd64 handbook)

```
# uname -a

Linux gent1 2.6.29-gentoo-r1 #9 SMP Wed Apr 22 23:15:39 MSD 2009 x86_64 Intel(R) Core(TM)2 CPU 6400 @ 2.13GHz GenuineIntel GNU/Linux
```

and now I have a problem: when system goes down, the computer doesn't power off! Exactly, all services are going down, and I see message "INIT: No more processess left in this runlevel", and that's all.. so I have to switch off computer manually (by pressing the power button for some time). This happens when I use commands like poweroff, reboot, shutdown and so on. But when I execute "echo b > /proc/sysrq-trigger" the computer hangs up immediately, and "echo o > /proc/sysrq-trigger" reboot my computer (like hard reset). This methods are inapropriate because of great possibility of loosing data.. so I wonder, where the problem can be?

Here are some details:

```
# acpid -v

acpid-1.0.6
```

```
# less /etc/acpi/events/default

...

event=button[ /]power.*

action=/sbin/init 0

... 
```

```
# lsmod

Module Size Used by

nvidia 8110184 26 
```

```
$ ps uax | grep acpi

root 198 0.0 0.0 0 0 ? S< 13:03 0:00 [kacpid]

root 199 0.0 0.0 0 0 ? S< 13:03 0:00 [kacpi_notify]

root 3234 0.0 0.0 3804 552 ? Ss 13:04 0:00 /usr/sbin/acpid

103 3363 0.0 0.0 19580 980 ? S 13:04 0:00 hald-addon-acpi: listening on acpid socket /var/run/acpid.socket
```

```
CFLAGS="-O2 -march=k8 -pipe"

CXXFLAGS="-O2 -march=k8 -pipe"

CHOST="x86_64-pc-linux-gnu"

USE="mmx sse sse2 gtk xfce -qt -qt3 -qt4 -kde -gnome alsa mp3 ogg jpg jpeg png hal dbus unicode X acpi xcomposite"

LINGUAS="ru"

VIDEO_CARDS="nvidia"

ACCEPT_KEYWORDS="~amd64"

INPUT_DEVICES="keyboard mouse evdev"

MAKEOPTS="-j3"

GENTOO_MIRRORS=....

```

The kernel options (with Y marks, not modules): Power Managment support, ACPI, "Deprecated /proc/acpi files", "Deprecated power /proc/acpi directories", "Future power /sys interface", "Deprecated /proc/acpi/event support", "Button". Option "cpu processor scaling" is turned off.

I tried some different kernel configurations but all goes the same way. I must notice that minimal CD works perfect (at least at this point of view), and so was my previous system (gentoo too, but with stable kernel).

I don't know what else can I do.. please help! ))

P.S.

If I forgot to post some data, please ask me and I'll post it)Last edited by iMexus on Sat Apr 25, 2009 10:17 am; edited 1 time in total

----------

## doctork

I have a similar problem -- the shutdown gets to the point of:

```
Unloading ALSA modules ...
```

and then hangs.  This appeared with gentoo-sources-2.6.29 and occurs on both my Lenovo laptop and my Phenom-based desktop.

EDIT:  My problem went away when I changed /etc/conf.d/alsasound so that it doesn't unload the modules when going down.

--

doc

----------

## entity

At least gentoo-sources-2.6.28-r5 seems to work properly with same .config.

----------

## iMexus

Well.. maybe somebody can tell me how to insert those commands into the "end" of init script? ("echo b > /proc/sysrq-trigger" and "echo o > /proc/sysrq-trigger") It is more preferable if computer will respond to poweroff and reboot commands correctly (if it is possible to do so via init scripts)

----------

## iMexus

The problem is solved.. it was int /etc/inittab.. it was old)) for some reasons it haven't updated with sysvinit update. I renamed it and reemedged sysvinit, and now it works perfect!  :Smile: 

----------

## grooveman

IMexus...

did you notice that you said:

 *Quote:*   

> I installed the gentoo system two or three days ago (everything according to amd64 handbook) 

 

But according to your uname, you are using an Intel system!

However...

I am having the same problem -- system hangs on unloading the alsa modules.  I tried your inittab idea, but it didn't help  :Sad: 

----------

## iMexus

 *grooveman wrote:*   

> IMexus...
> 
> But according to your uname, you are using an Intel system!
> 
> 

 

By system I've meant operation system and "GenuineIntel" is a hardware platform, but not linux itself. Consider uname --help:

uname -a = uname -s -n -r -v -m -p -i -o

And now about your problem. Have you tried to unload alsa modules by hands? Or even compile them into the kernel (not like modules)? Tell us more about your system's configuration.. I don't know about others, but as for me, I don't have such powerful telepathic abilities.

And my "inittab idea", which is actually not mine, works only when system has already unloaded all it could and only then hangs.

----------

## grooveman

Hi Imex,

I am experiencing so many strange things with the new kernel.  Since you had marked this thread as solved, I posted here.

I did not want to work around the unload problem with the alsa modules, they should unload on their own... I see it symptomatic of something bigger.  If I get no responses on my thread soon, then I will try going to 2.6.30...  In fact, I noticed more strangeness this morning at boot time...

I just mentioned the amd/intel thing in case it was relevant to your issue cuz you said you installed using the amd64 manual, not the ia64 manual.  I don't use ia64, so I don't know if or how a gentoo install differs, but I figure they must or they wouldn't have two separate manuals.

 *Quote:*   

> I installed the gentoo system two or three days ago (everything according to amd64 handbook)
> 
> Code:
> 
> # uname -a
> ...

 

----------

## MaximeG

What's up with the ia64 thingy ?

amd64 is for intel and amd's x86_64 platforms, like Core 2 Duo, Phenom and stuff.

amd64 is a confusing name because back in the days, only amd provided a fake/extended 64 bits processor instructions. Later Intel bought the licence and produced also this feature.

So amd64 refers to both amd's amd64 architecture and Intel's ia32-EM64T (everyday pc's) architecture.

In the other hand, ia64 is for the Intel Itanium's architecture only.

Best Regards,

Maxime

----------

## grooveman

Ooooh....

----------

