Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

When I login server as root through ssh, I only see following message printed, but the prompt string is missing:

Last login: Wed Dec 21 08:12:26 2011 from

I can type, but all command doesn't work. Only after I press ctrl-c, the prompt string shows up:


Moreover, sftp does not work also for root. All other user on the system do not have such problem: no need ctrl-c to login, and sftp works well. Reboot doesn't solve the problem.

Anyone knows why?

share|improve this question

migrated from Dec 21 '11 at 16:21

This question came from our site for professional and enthusiast programmers.

What is root's shell defined as in /etc/passwd? – Garrett Dec 21 '11 at 16:29
up vote 2 down vote accepted

Check root's .login or .profile file and look to see whether it starts a program (perhaps accidentally).

For example, if root's .profile contains (note the typo)

cat $filkname > /tmp/foo

this would cause the symptoms you describe

share|improve this answer
You are right. Something unexpected is in bashrc. Thanks – user607722 Dec 23 '11 at 18:30

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .