Unix Technical Forum

System hangs during login / runlevel question

This is a discussion on System hangs during login / runlevel question within the Linux Operating System forums, part of the Unix Operating Systems category; --> Hi, yesterday my system crashed when I hit the Magic SysRq key by accident. When I rebooted it didn't ...


Go Back   Unix Technical Forum > Unix Operating Systems > Linux Operating System

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 01-17-2008, 08:36 AM
Helge Preuss
 
Posts: n/a
Default System hangs during login / runlevel question

Hi,
yesterday my system crashed when I hit the Magic SysRq key by accident.
When I rebooted it didn't start up, complaining about not being able to
find /. Some problem with the initrd, which I finally solved.
But now the system boots up to the login prompt, where it gladly accepts
my login name and then goes to sleep for ever after the <RETURN>. In
runlevel 5, it hangs before anything is displayed by the X server (black
screen).
I *can* log in at runlevel 1, start all /etc/rc.d/rc3.d scripts and the
system is almost as usual. But this is not really a solution, is it.
So my questions: Has anybody an idea, what happens and how I can solve
this? And (out of interest): should runlevel 1 with all the appropriate
services started be the same as runlevel 3 or 5, or something different?
My system is RedHat 8.0, kernel 2.4.22 with XFS patch; the only
"unusual" piece of Hardware is an IBM ServeRAID controller.
TIA
Helge

--
hint: my first name is not "spam"!

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 01-17-2008, 08:36 AM
David
 
Posts: n/a
Default Re: System hangs during login / runlevel question

Helge Preuss wrote:
> Hi,
> yesterday my system crashed when I hit the Magic SysRq key by accident.
> When I rebooted it didn't start up, complaining about not being able to
> find /. Some problem with the initrd, which I finally solved.
> But now the system boots up to the login prompt, where it gladly accepts
> my login name and then goes to sleep for ever after the <RETURN>. In
> runlevel 5, it hangs before anything is displayed by the X server (black
> screen).
> I *can* log in at runlevel 1, start all /etc/rc.d/rc3.d scripts and the
> system is almost as usual. But this is not really a solution, is it.
> So my questions: Has anybody an idea, what happens and how I can solve
> this? And (out of interest): should runlevel 1 with all the appropriate
> services started be the same as runlevel 3 or 5, or something different?
> My system is RedHat 8.0, kernel 2.4.22 with XFS patch; the only
> "unusual" piece of Hardware is an IBM ServeRAID controller.


Runlevel 1 shouldn't have any services running. It is basically
just enough to get the system up so you can fix it from the
command line. So no it isn't and shouldn't be setup the same as
runlevel 3,4 or 5.

Since the system will boot all the way to a login prompt at
runlevel 5 I would try this. Boot to runlevel 3 login as root and
delete everything in /tmp. Then logout and login back in as a
normal user and see if you can "startx" as a user. If that works
then you should be able to either switch to runlevel 5 using
"telinit 5" as root or reboot the system, though a reboot isn't
really needed to switch runlevels.

--
Confucius: He who play in root, eventually kill tree.
Registered with The Linux Counter. http://counter.li.org/
Slackware 9.1.0 Kernel 2.4.22 SMP i686 (GCC) 3.3.2
Uptime: 17 days, 21:22, 2 users, load average: 0.11, 0.10, 0.0

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 01-17-2008, 08:36 AM
Helge Preuss
 
Posts: n/a
Default Re: System hangs during login / runlevel question

>> Hi,
>> yesterday my system crashed when I hit the Magic SysRq key by
>> accident. When I rebooted it didn't start up, complaining about not
>> being able to find /. Some problem with the initrd, which I finally
>> solved.
>> But now the system boots up to the login prompt, where it gladly
>> accepts my login name and then goes to sleep for ever after the
>> <RETURN>. In runlevel 5, it hangs before anything is displayed by the
>> X server (black screen).
>> I *can* log in at runlevel 1, start all /etc/rc.d/rc3.d scripts and
>> the system is almost as usual. But this is not really a solution, is it.
>> So my questions: Has anybody an idea, what happens and how I can solve
>> this? And (out of interest): should runlevel 1 with all the
>> appropriate services started be the same as runlevel 3 or 5, or
>> something different?
>> My system is RedHat 8.0, kernel 2.4.22 with XFS patch; the only
>> "unusual" piece of Hardware is an IBM ServeRAID controller.

>
>
> Runlevel 1 shouldn't have any services running. It is basically just
> enough to get the system up so you can fix it from the command line. So
> no it isn't and shouldn't be setup the same as runlevel 3,4 or 5.
>
> Since the system will boot all the way to a login prompt at runlevel 5 I
> would try this. Boot to runlevel 3 login as root and delete everything
> in /tmp. Then logout and login back in as a normal user and see if you
> can "startx" as a user. If that works then you should be able to either
> switch to runlevel 5 using "telinit 5" as root or reboot the system,
> though a reboot isn't really needed to switch runlevels.


I don't seem to have made myself clear: I can't log in at runlevel *3*,
I get the prompt and send the system to sleep there, when I enter my
user name. With level 5, I don't even see a prompt, because the screen
goes blank on me beforehand.
I checked /tmp though, and there's nothing in it which might prevent
logging in.
Runlevel 1 doesn't start any services, I did it manually (for i in
/etc/rc.d/rc3.d/S*; do $i; done). Having done that, I have not found any
difference to runlevel 3. Is it supposed to be like this?

Helge

--
hint: my first name is not "spam"!

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 01-17-2008, 08:37 AM
Bill Unruh
 
Posts: n/a
Default Re: System hangs during login / runlevel question

Helge Preuss <spam.preuss@fhi-berlin.mpg.de> writes:

]>> Hi,
]>> yesterday my system crashed when I hit the Magic SysRq key by
]>> accident. When I rebooted it didn't start up, complaining about not
]>> being able to find /. Some problem with the initrd, which I finally
]>> solved.
]>> But now the system boots up to the login prompt, where it gladly
]>> accepts my login name and then goes to sleep for ever after the
]>> <RETURN>. In runlevel 5, it hangs before anything is displayed by the
]>> X server (black screen).
]>> I *can* log in at runlevel 1, start all /etc/rc.d/rc3.d scripts and
]>> the system is almost as usual. But this is not really a solution, is it.
]>> So my questions: Has anybody an idea, what happens and how I can solve
]>> this? And (out of interest): should runlevel 1 with all the
]>> appropriate services started be the same as runlevel 3 or 5, or
]>> something different?
]>> My system is RedHat 8.0, kernel 2.4.22 with XFS patch; the only
]>> "unusual" piece of Hardware is an IBM ServeRAID controller.
]>
]>
]> Runlevel 1 shouldn't have any services running. It is basically just
]> enough to get the system up so you can fix it from the command line. So
]> no it isn't and shouldn't be setup the same as runlevel 3,4 or 5.
]>
]> Since the system will boot all the way to a login prompt at runlevel 5 I
]> would try this. Boot to runlevel 3 login as root and delete everything
]> in /tmp. Then logout and login back in as a normal user and see if you
]> can "startx" as a user. If that works then you should be able to either
]> switch to runlevel 5 using "telinit 5" as root or reboot the system,
]> though a reboot isn't really needed to switch runlevels.

]I don't seem to have made myself clear: I can't log in at runlevel *3*,
]I get the prompt and send the system to sleep there, when I enter my
]user name. With level 5, I don't even see a prompt, because the screen
]goes blank on me beforehand.
]I checked /tmp though, and there's nothing in it which might prevent
]logging in.
]Runlevel 1 doesn't start any services, I did it manually (for i in
]/etc/rc.d/rc3.d/S*; do $i; done). Having done that, I have not found any
]difference to runlevel 3. Is it supposed to be like this?

OK.The first thing is to get it working at runlevel 3.
a) Can root log in at runlevel 3? (ie is it a permissions problem?)
b) Does the long pause come afer you type in your name or after you type
in the password? (login/pam problem)?
c) In its long pause in runlevel 3, can you change consoles
(alt-ctrl-F2) and try again?
d)You could put in a special command into run level 3 and have top dump
to a file constatly to see what is attempting to run at that level
(Make a special S20top file in /etc/rc3.d which starts top and redirects
the output into a file and make sure it runs in the background.

Ie, make sure you can log in in level 3 first and then tackle X.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 02:55 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com