PDA

View Full Version : [ubuntu] lost admin account ...



npnutn7
September 11th, 2008, 02:18 AM
I was trying to manage the accounts and now all i have is the root and admin account without sudoers privileges , and i can not change that back,,

what should i do now?

ajmorris
September 11th, 2008, 02:22 AM
I was trying to manage the accounts and now all i have is the root and admin account without sudoers privileges , and i can not change that back,,

what should i do now?

hi there,
run
su in a terminal, then type in visudo, you can then add your user to be able to use sudo again.

AJ

npnutn7
September 11th, 2008, 02:26 AM
thanks for a quick reply,
i tried it but here is what i get


Password:
su: Authentication failure

ajmorris
September 11th, 2008, 02:32 AM
thanks for a quick reply,
i tried it but here is what i get

This means your root account is disabled, and can only be access by sudo. To re-enable sudo for you user, you will have to boot into a live cd, chroot as root into your ubuntu install, and run visudo from there.

AJ

npnutn7
September 11th, 2008, 02:35 AM
ok, i`ll try ,
I think i am gonna install ubuntu again, it`s still a fresh copy
thanks

npnutn7
September 11th, 2008, 07:48 AM
ok, did Google it and here`s what i found and yes i was able to fix it.

1) on login screen choose recovery mode
2) use drop as root , i think the 3rd one
3) use this command to reset root password

passwd root
4) reboot and logged back in with my usual account
5) open terminal and

su
users-admin
6) Vola, edit all your account in root mode
7) you have to restart and disable the root password

and that`s what i want to know how?

npnutn7
September 11th, 2008, 08:05 AM
updates,
used this command


sudo passwd -l root

but now i get this message when "sudo su"

Your account has expired; please contact your system administrator
su: User account has expired
(Ignored)

and then it opens root
What to do?