I want to run sudo service lightdm restart command on virtual console, so i pressed Ctrl+Alt+F1 after that VC login prompt appears,


I logged into the vc with my login credentials.If i run sudo service lightdm restart command on that prompt, it again asked for sudo password.

~$ sudo service lightdm restart
[sudo] password for avinash:

Why there is a two step verfication proces?

  • You could ask the same question when login to your account through Unity, Ctrl+Alt+T and run any command with sudo. It prompts for password. The same behavior is being observed in tty1. Mar 12, 2014 at 8:27

1 Answer 1


The first time you entered your password was to log into your account. The second time it prompted you for your password was because you entered a command starting with 'sudo'.

When you use 'sudo' you are telling the system to run the next command as if you are the root (admin) account. When this occurs it asks for your password again as a security feature in case you decide you don't want to run the command or if it might be an unauthorized person (say you forgot to log out and another person attempted this).

You must log in to answer this question.

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