I have Ubuntu 12.04 LTS.
When I try su command, it asks password..
But when I type password, It says authentication failure..
Why does that happen??
I enter correct password every time.

did you make sure caps lock isn't on or you have administrator privileges?

Further to zeroliken, was caps lock on when you entered the admin password when you initally installed Ubuntu?

The password may be different to the one you log in with./ For security purposes it should be.

Your user password is not the same as the root password, at least, not by default. The install will give your user account administrative rights (like doing sudo commands, and installing software), but it doesn't make your user account the "root" account. The root account is issued a randomly generated password, that is to ensure that a hacker cannot easily login remotely to the root account by cracking an easy password.

In order to do a su command, you need to first issue a sudo, in other words, write this in the terminal:

$ sudo su

and enter your user password.

yeah!
I checked everything.
My password doesn't contain caps letters.
Is there any default user name n password for ubuntu???

Is there any default user name n password for ubuntu???

Read my answer above. Short answer, write sudo su in the terminal, and enter your user password, then you can reset the root password using the passwd command.

commented: Thanks, Mike... +0
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.