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 type in my password at a sudo command line prompt, I would like to see a "*" for each keystroke. How do I do this?

share|improve this question
up vote 5 down vote accepted

On some UNIX-based systems, sudo can show an asterisk (*) when you type a letter.

In the terminal, enter...

sudo visudo;

Type your root password in (you won't see any visual feedback yet) and hit Enter.

Now, find the line that reads:

Defaults env_reset

And replace it with:

Defaults env_reset,pwfeedback

Finally save and exit the file. Assuming you are using vi, that command is:

:wq!

and then press Enter.

sudo should now be set up correctly. To test, open up a new terminal and type this to reset the sudo timeout.

sudo -k;

Now try it out.

sudo ls;

Source: http://whyareyoureadingthisurl.wordpress.com/2010/05/16/sudo-and-password-feedback/

share|improve this answer
    
Thanks for providing possible intermediate steps. :) – iglvzx May 5 '12 at 1:47

You can enable visual feedback when typing passwords by editing your /etc/sudoers file and changing the Defaults line to read:

Defaults    env_reset,pwfeedback

Example:

screenshot

share|improve this answer

You must log in to answer this question.

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