Gentoo-laptop hangs when exits root shell

Posted on 2004-04-06
Last Modified: 2013-12-16
I've got a recent installed Dell C600 laptop with updated Gentoo Linux. Kernel version is 2.6.3-gentoo-r2. The problem exist even if I switch to a 2.4 kernel.

Ok... Here we go.

When I login to the CLI or X and opens a terminal with the root user, I'm not able to type 'exit' to logout. The entire system hangs. No ssh, no ping, no numlock flashing. I can exit from a user shell without problems. I've tried to update/reinstall pam without success.

I tried at first Gentoo forums, but didn't get any answers.

It's kinda irritating to reboot the computer every time I forget the problem.

The system log isn't saying anything at all.
Question by:Pellas
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
LVL 44

Expert Comment

by:Karl Heinz Kremer
ID: 10771175
I've never seen anything like this, so this may take some time to debug. Which shell are you using? What is really strange that the same also hangs when you exit out of a X terminal.
Have you tried to use a different default shell for the root user?
LVL 17

Expert Comment

ID: 10772727
You dont have anything unusual in .bash_logout in the /root/ directory?

Expert Comment

ID: 10773079
You can launch one of these shells, and, in another one :

strace -o ~/log -f -p <your_shells_process_id>

Then, exit it.

With lots of luck, it will write to the output file before freezing the system. You should be able to see what happens.
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

LVL 44

Expert Comment

by:Karl Heinz Kremer
ID: 10773151
Do you have a second machine that you can use to log in over the network? If so, is the network connection still active once the shell hangs?

Author Comment

ID: 10776800
I've now tested what you all adviced.

I'm using bash shells on all users and I don't have a .bash_logout file in /root.

The strace thing did only write "ERRNO_0", /*
before exit.

The login over ssh don't work cause the entire machine just locks. No ping respone either.

That's all for now. Hope you've got some dirty ones up your sleeves. ;)

Author Comment

ID: 10778042
I tried to change shell to csh and that worked.

Seems like somthing in the bash thing just don't work.

I tried to re-emerge bash but that didn't work...

If someone know what would causing this in bash, I'd be glad to know.
LVL 44

Expert Comment

by:Karl Heinz Kremer
ID: 10778635
When you say "re-emerge bash", do you mean you reinstalled the package? (I'm not familiar with the Gentoo lingo)
LVL 44

Expert Comment

by:Karl Heinz Kremer
ID: 10778736
Do you have a file /etc/bash_logout ?
LVL 44

Expert Comment

by:Karl Heinz Kremer
ID: 10778766
Screwed up the file name: Do you have a file /etc/bash.bash_logout ?
LVL 44

Expert Comment

by:Karl Heinz Kremer
ID: 10778789
One more thing: Bash writes out the .bash_history file when it exits. Can you please find out if the timestamp on this file gets updated before the system crashes. Does this file contain valid data (command lines you've entered)?

Expert Comment

ID: 10791485
khkremer: "emerge" is the command to install/uninstall software in Gentoo (e.g.  "emerge bash" would install bash).

Pellas: What environment variables do you have set in bash ?
 > env

If you ssh into the system and type exit or ctrl-d, does it do the same thing as a tty login?


Expert Comment

ID: 16044686
No comment has been added to this question in more than 21 days, so it is now classified as abandoned.
I will leave the following recommendation for this question in the Cleanup topic area:
PAQ - No Refund

Any objections should be posted here in the next 4 days. After that time, the question will be closed.

Sam [slow1000]
EE Cleanup Volunteer

Accepted Solution

DarthMod earned 0 total points
ID: 16088954
PAQed with no points refunded (of 500)

Community Support Moderator

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Unix process listing into CSV format 3 87
CentOS 7 Linux for HP DL380 G4 32Bits 7 105
check the file dates in unix 14 77
Issue when using 'yum update' 4 25
Introduction We as admins face situation where we need to redirect websites to another. This may be required as a part of an upgrade keeping the old URL but website should be served from new URL. This document would brief you on different ways ca…
Google Drive is extremely cheap offsite storage, and it's even possible to get extra storage for free for two years.  You can use the free account 15GB, and if you have an Android device..when you install Google Drive for the first time it will give…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question