0

I lost my Ubuntu root password and now , i just want to get it by doing changes on sudoers file but before this I would like to get backup of my working Ubuntu user-profile due to safety purpose of data and software's .

Does anybody know how to do it , if so please share the information .

3 Answers 3

1

Backups are always good to have. That is probably why there is a simple backup utility in the settings window, under "system". Tell it to back up a folder, and select you home directory, tell it where to backup, and it's done.

But why compound you original error by making more errors? You might be able to get it to work, but it would be better to understand what you did, and the proper way to fix it.

I don't believe you when you say you lost your ubuntu root password; first of all, if you knew enough to actually create a usable root password, you would already know how to create a new one the same way. But you don't need a root password, which is why Ubuntu does not provide one by default.

I suspect what you may have done is somehow either deleted the admin group, or removed yourself from it. Doing this will take away your ability to use sudo. If this guess is correct, the solution is not to edit the sudoers file, but to add yourself back to the admin group.

If you edited the sudoers file and messed that up, then you do need to edit the file to restore it back to what it was.

Most of these things are accomplished following these directions. It's mostly standard Unix/Linux commands that are easy to find lots of information.

Then again, perhaps you already do know what to do, in which case... good luck, and feel free to ask for advice before destroying your system rather than after. :)

0

All the files for every user are placed in /home/username directory. Make sure you've turned on hidden files display.

P. S. After backing up you can try this: https://askubuntu.com/a/84697/20275

0

Have a look at our guide on resetting your password using recovery mode, the process has changed in 12.04, and the admin group is now called sudo.

Reset Password Using Recovery Mode

Whilst in recovery mode you could add yourself back to the admin group using:

adduser username sudo

replacing username with your user name ie. adduser phil sudo

You must log in to answer this question.

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