Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Cannot seem to shut down properly
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
Hikaru79
Tux's lil' helper
Tux's lil' helper


Joined: 07 Apr 2005
Posts: 120
Location: Windsor, Ontario (Canada)

PostPosted: Sat Apr 09, 2005 4:44 am    Post subject: Cannot seem to shut down properly Reply with quote

Shutting down seems to be a huge problem for my Gentoo (brand new). As root, if I do 'shutdown now', it begins the shutdown process, but always stays stuck indefinetly at "Saving Random Seed [ok]" and never goes past that point. As for trying to shut down from XFce, it's not even an option -- it's greyed out.

Any ideas? =/ I'm having to force-shut it every single time.
Back to top
View user's profile Send private message
ONEEYEMAN
Advocate
Advocate


Joined: 01 Mar 2005
Posts: 3674

PostPosted: Sat Apr 09, 2005 5:06 am    Post subject: Reply with quote

What's gonna hapeen, when you pressw the power button after it freezes, on shutdown now command? Does it give you an error in this case?

Thank you.
Back to top
View user's profile Send private message
RinkyDinks_RJ
n00b
n00b


Joined: 12 Aug 2003
Posts: 42

PostPosted: Sat Apr 09, 2005 5:17 am    Post subject: Reply with quote

Quote:
As for trying to shut down from XFce, it's not even an option -- it's greyed out.


Are you running a dm? (xdm, gdm, kdm). If you're not then running one should fix that.

Try using acpid or apmd, it fixes this problem on some computers.
Back to top
View user's profile Send private message
Hikaru79
Tux's lil' helper
Tux's lil' helper


Joined: 07 Apr 2005
Posts: 120
Location: Windsor, Ontario (Canada)

PostPosted: Sat Apr 09, 2005 5:25 am    Post subject: Reply with quote

ONEEYEMAN wrote:
What's gonna hapeen, when you pressw the power button after it freezes, on shutdown now command? Does it give you an error in this case?

Thank you.

I'm not sure what you mean. If I press the power button after it freezes, it just... turns off. It doesn't give an error message when it turns back on , at any rate.

And Rinky, thanks =) I'll give a dm a try.
Back to top
View user's profile Send private message
Hikaru79
Tux's lil' helper
Tux's lil' helper


Joined: 07 Apr 2005
Posts: 120
Location: Windsor, Ontario (Canada)

PostPosted: Sat Apr 09, 2005 3:50 pm    Post subject: Reply with quote

I really hate to bump topics like this, but not being able to shut down seems to me like a pretty serious problem, and any guidance would be GREATLY appreciated... :( So, does anyone know why 'shutdown now' hangs on "Saving random seed [ok]" ? :oops:
Back to top
View user's profile Send private message
Timer
n00b
n00b


Joined: 08 Apr 2005
Posts: 2
Location: Pori, Finland

PostPosted: Wed Apr 20, 2005 6:57 pm    Post subject: Reply with quote

I have the same problem too :/ Any help would be appreciated.
Back to top
View user's profile Send private message
Hikaru79
Tux's lil' helper
Tux's lil' helper


Joined: 07 Apr 2005
Posts: 120
Location: Windsor, Ontario (Canada)

PostPosted: Sun Apr 24, 2005 1:51 am    Post subject: Reply with quote

Timer wrote:
I have the same problem too :/ Any help would be appreciated.


This problem was solved for me in the IRC channel. Apparently, its now standard procedure to use
Code:
shutdown -h now
as opposed to
Code:
shutdown now
. Try that.
Back to top
View user's profile Send private message
Lechium
Apprentice
Apprentice


Joined: 04 Apr 2005
Posts: 244

PostPosted: Sun Apr 24, 2005 1:58 am    Post subject: Reply with quote

i use
Code:
halt =p
Back to top
View user's profile Send private message
phsdv
Guru
Guru


Joined: 13 Mar 2005
Posts: 372
Location: Europe

PostPosted: Sun Apr 24, 2005 7:28 am    Post subject: Re: Cannot seem to shut down properly Reply with quote

Hikaru79 wrote:
As for trying to shut down from XFce, it's not even an option -- it's greyed out.

This was solved for me after I installed sudo.
Back to top
View user's profile Send private message
phsdv
Guru
Guru


Joined: 13 Mar 2005
Posts: 372
Location: Europe

PostPosted: Sun Apr 24, 2005 11:03 am    Post subject: Re: Cannot seem to shut down properly Reply with quote

Hikaru79 wrote:
Shutting down seems to be a huge problem for my Gentoo (brand new). As root, if I do 'shutdown now', it begins the shutdown process, but always stays stuck indefinetly at "Saving Random Seed [ok]"

Apperently you go to init level 1 and not 0. Or you init levels are not correct. How does your /etc/inittab file look like?
Back to top
View user's profile Send private message
Hikaru79
Tux's lil' helper
Tux's lil' helper


Joined: 07 Apr 2005
Posts: 120
Location: Windsor, Ontario (Canada)

PostPosted: Sun Apr 24, 2005 2:01 pm    Post subject: Re: Cannot seem to shut down properly Reply with quote

phsdv wrote:
Hikaru79 wrote:
Shutting down seems to be a huge problem for my Gentoo (brand new). As root, if I do 'shutdown now', it begins the shutdown process, but always stays stuck indefinetly at "Saving Random Seed [ok]"

Apperently you go to init level 1 and not 0. Or you init levels are not correct. How does your /etc/inittab file look like?


Here it is:
Code:
#
# /etc/inittab:  This file describes how the INIT process should set up
#                the system in a certain run-level.
#
# Author:  Miquel van Smoorenburg, <miquels@cistron.nl>
# Modified by:  Patrick J. Volkerding, <volkerdi@ftp.cdrom.com>
# Modified by:  Daniel Robbins, <drobbins@gentoo.org>
# Modified by:  Martin Schlemmer, <azarah@gentoo.org>
#
# $Header: /home/cvsroot/gentoo-src/rc-scripts/etc/inittab,v 1.6 2003/01/06 21:32:43 azarah Exp $

#
# Default runlevel.
id:3:initdefault:

# System initialization, mount local filesystems, etc.
si::sysinit:/sbin/rc sysinit

# Further system initialization, brings up the boot runlevel.
rc::bootwait:/sbin/rc boot

l0:0:wait:/sbin/rc shutdown
l1:S1:wait:/sbin/rc single
l2:2:wait:/sbin/rc nonetwork
l3:3:wait:/sbin/rc default
l4:4:wait:/sbin/rc default
l5:5:wait:/sbin/rc default
l6:6:wait:/sbin/rc reboot
#z6:6:respawn:/sbin/sulogin

# TERMINALS
c1:12345:respawn:/sbin/agetty 38400 tty1 linux
c2:12345:respawn:/sbin/agetty 38400 tty2 linux
c3:12345:respawn:/sbin/agetty 38400 tty3 linux
c4:12345:respawn:/sbin/agetty 38400 tty4 linux
c5:12345:respawn:/sbin/agetty 38400 tty5 linux
c6:12345:respawn:/sbin/agetty 38400 tty6 linux

# What to do at the "Three Finger Salute".
ca:12345:ctrlaltdel:/sbin/shutdown -r now

# Used by /etc/init.d/xdm to control DM startup.
# Read the comments in /etc/init.d/xdm for more
# info. Do NOT remove, as this will start nothing
# extra at boot if /etc/init.d/xdm is not added
# to the "default" runlevel.
x:a:once:/etc/X11/startDM.sh

# End of /etc/inittab
Is there anything wrong with it? :oops:
Back to top
View user's profile Send private message
phsdv
Guru
Guru


Joined: 13 Mar 2005
Posts: 372
Location: Europe

PostPosted: Sun Apr 24, 2005 2:22 pm    Post subject: Re: Cannot seem to shut down properly Reply with quote

Hikaru79 wrote:
Is there anything wrong with it?
Nope, nothing... I have the same.

It looks your system going to "init 1" instead of "init 0" for a shutdown, very strange. Does the same thing happen when you do this from a console (without X11)? And after it stops and you press <enter> you still have the prompt? If you have, you are really in init 1.
Back to top
View user's profile Send private message
nizar
Apprentice
Apprentice


Joined: 19 Dec 2003
Posts: 268
Location: localhost

PostPosted: Tue Apr 26, 2005 2:26 pm    Post subject: Re: Cannot seem to shut down properly Reply with quote

phsdv wrote:
Hikaru79 wrote:
Is there anything wrong with it?
Nope, nothing... I have the same.

It looks your system going to "init 1" instead of "init 0" for a shutdown, very strange. Does the same thing happen when you do this from a console (without X11)? And after it stops and you press <enter> you still have the prompt? If you have, you are really in init 1.


Exactly the problem that I have :(
usually shutting kdm fails and nothing happens, I press ENTER and I have the prompt again! Another reboot/shutdown does the reboot/shutdown.

Any ideas

TIA
Back to top
View user's profile Send private message
phsdv
Guru
Guru


Joined: 13 Mar 2005
Posts: 372
Location: Europe

PostPosted: Tue Apr 26, 2005 7:08 pm    Post subject: Reply with quote

I just had a look at the c-code of shutdown.c, it will show to which runlevel it will go:
Code:
  /* Tell users what we're gonna do. */
  switch(down_level[0]) {
   case '0':
      strcpy(newstate, "for system halt");
      break;
   case '6':
      strcpy(newstate, "for reboot");
      break;
   case '1':
      strcpy(newstate, "to maintenance mode");
      break;
   default:
      sprintf(newstate, "to runlevel %s", down_level);
      break;
  }

Do you see eny of those messages?
Also you should really try:
Code:
shutdown -h now
see following code:
Code:
 /* Process the options. */
  while((c = getopt(argc, argv, "acqkrhnfFyt:g:i:")) != EOF) {
     switch(c) {
                ....
        case 'r': /* Automatic reboot */
         down_level[0] = '6';
           break;
        case 'h': /* Halt after shutdown */
         down_level[0] = '0';
           break;
                ....

after that it will call the init process with the runlevel to go to:
Code:
  /* Now execute init to change runlevel. */
  sync();
  execv(INIT, args);

Can you check if
Code:
 init 0
as root will halt your system?
Back to top
View user's profile Send private message
Gentoo-Ed
Guru
Guru


Joined: 21 Apr 2005
Posts: 442
Location: the Netherlands

PostPosted: Fri Apr 29, 2005 6:38 am    Post subject: Reply with quote

sorry for "budging in" like this

I have the same problem too. In when I do init 0 instead of shutdown my system is neetly turned off. Wonder why shutdown doesn't.
Back to top
View user's profile Send private message
phsdv
Guru
Guru


Joined: 13 Mar 2005
Posts: 372
Location: Europe

PostPosted: Fri Apr 29, 2005 7:27 pm    Post subject: Reply with quote

Hoi Ed, We really do not know. Does "shutdown -h" help? What messages do you have when you do a shutdown?
Back to top
View user's profile Send private message
Gentoo-Ed
Guru
Guru


Joined: 21 Apr 2005
Posts: 442
Location: the Netherlands

PostPosted: Fri Apr 29, 2005 8:08 pm    Post subject: Reply with quote

I did the shutdown with " shutdown -h" or " shutdown -h now".
Both don't get any error messages at all.
If wan't I can provide the entire sequence of messages (I'll just hook up the laptop next to the screen and type it over".
Fortunatly it isn't really anoying because I know init 0 does work.
I'll keep toggleing it between installations of other software.

Turn off by button doesn't work
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum