[SOLVED] Randomly generated passwords result in root lockdown and how to fix it.
Tofloor
poster avatar
deepinexperiment
deepin
2016-02-08 03:16
Author
Edited by deepinexperiment at 2016-2-10 04:56

Hi. I set a randomly created (for example, R8hopgF%/?) password for my root account. I could not login to my root account, but was able to change system settings on a normal account (changed my normal account's password). I proceeded to reset my root password from root terminal in grub but got a message that root had been locked out or something along these lines.

This is what helped.

1. When booting up, go down to advanced settings. Press E.
2. You will now see two kernel options. On the first one, press Enter or E, whichever works.
3. Using the arrow key, navigate to the line where it says Linux/Vm something.
In the end of the line it says ro quiet splash. Replace that with rw init=/bin/bash, then press Ctrl X.
4. You are now back at the kernel selecting menu. Now press Enter. If everything went right, you should now be at root terminal.
5. Now type passwd yourusername. You will be asked to re-enter the password. Type sync and press enter, then type reboot -f and press enter.

All done!

Here is a manual from Ubuntu: https://help.ubuntu.com/community/LostPassword
I used a Youtube video which I can't find right now but I will post the link later.


But back to the topic. What do you think caused my password to not work during login? Is it the symbols %&/)?



Reply Favorite View the author
All Replies
tristar
deepin
2016-02-08 03:55
#1
I presume you can't use sudo? Something like that:

sudo passwd
then your password and two times new root password, at least I do this...
Reply View the author
dance707
deepin
2016-02-08 04:12
#2
Edited by dance707 at 2016-2-7 05:52

Almost all special characters are allowed for a root password. To login as root is not advised. Just type su on the command line to access superuser privileges.
Reply View the author
deepinexperiment
deepin
2016-02-08 05:00
#3
https://bbs.deepin.org/post/30701
I presume you can't use sudo? Something like that:

sudo passwd

You mean can I change my root password as a normal user?
I entered the command and it asked for my normal account's password. I entered it and it told me I'm not in the sudoers file. So I should put myself into the sudoers file? I found two tutorials on it:

http://www.glenngillen.com/thoug ... to-the-sudoers-file



Reply View the author
deepinexperiment
deepin
2016-02-08 05:02
#4
https://bbs.deepin.org/post/30701
Almost all special characters are allowed for a root password. To login as root is not advised. Just ...

I typed su and it returned "identification error", should I add myself to the sudoers file? Sorry I'm new at Linux.
Reply View the author
dance707
deepin
2016-02-08 05:10
#5
https://bbs.deepin.org/post/30701
I typed su and it returned "identification error", should I add myself to the sudoers file? Sorry  ...

If your new to Linux using sudo is the best. If you want to use a root password just follow Tristar's instructions to set root password. Then to use the root password type su and enter the password
Reply View the author
dance707
deepin
2016-02-08 05:20
#6
Edited by dance707 at 2016-2-7 06:23
https://bbs.deepin.org/post/30701
I typed su and it returned "identification error", should I add myself to the sudoers file? Sorry  ...

here is a paragraph out of a Debian wiki :

Why sudo?

Using sudo is better (safer) than opening a session as root for a number of reasons, including:

Nobody needs to know the root password (sudo prompts for the current user's password). Extra privileges can be granted to individual users temporarily, and then taken away without the need for a password change.
It's easy to run only the commands that require special privileges via sudo; the rest of the time, you work as an unprivileged user, which reduces the damage that mistakes can cause.
Auditing/logging: when a sudo command is executed, the original username and the command are logged.
For the reasons above, switching to root using sudo -i (or sudo su) is usually deprecated because it cancels the above features.
the full page is here :

https://wiki.debian.org/sudo
Reply View the author
dance707
deepin
2016-02-08 05:32
#7
Edited by dance707 at 2016-2-7 06:41
https://bbs.deepin.org/post/30701
You mean can I change my root password as a normal user?
I entered the command and it asked for my ...

When you first installed Deepin your account was set as administrator account, you can set additional users as normal users in Deepin's control panel If you set additional users as normal user they are not in the sudoers file.
Reply View the author
laoguang
deepin
2016-02-08 06:50
#8
what had just happened? this is weird.
how did you change the password?
how did you generate the password?
how did you key in the password?(terminal through ctrl shift v?)
by right you should be an admin user who is in the shudders file by default
did you use the first user created?
i did not encounter this issue before.
Reply View the author
deepinexperiment
deepin
2016-02-08 09:19
#9
https://bbs.deepin.org/post/30701
what had just happened? this is weird.
how did you change the password?
how did you generate the pas ...

I generated the password using a random password generator website. I set the password in settings panel (not in terminal). I used the first account that was created during the installation of deepin. But yeah, this is weird. But consider this thread closed, this is a waste of time.
Reply View the author
dance707
deepin
2016-02-08 11:03
#10
https://bbs.deepin.org/post/30701
I generated the password using a random password generator website. I set the password in settings ...

If your really trying to use Deepin 15.1 and not just experiment. I would suggest a clean install at this point.
Reply View the author
laoguang
deepin
2016-02-08 23:16
#11
https://bbs.deepin.org/post/30701
I generated the password using a random password generator website. I set the password in settings ...

since when are they offering the option to change root password in the control panel?
or did you change the password of the administrator account?
Reply View the author
deepinexperiment
deepin
2016-02-09 13:18
#12
Edited by deepinexperiment at 2016-2-9 05:21
To login as root is not advised.

Finally I'm starting to understand (I guess?)! So a root account is not enabled by default and an administrator account has the rights to get root acess temporarily by typing sudo/su and a normal account hasn't got the rights to do so?
Reply View the author
dance707
deepin
2016-02-09 13:28
#13
https://bbs.deepin.org/post/30701
Finally I'm starting to understand (I guess?)! So a root account is not enabled by default and an a ...

Yes that is basically correct. When use first install Deepin the initial user account is the administrator. The administrator account can also add other users to the system , additional administrators or normal users accounts. Normal user accounts do not have sudo rights.
Reply View the author
dance707
deepin
2016-02-09 13:32
#14
https://bbs.deepin.org/post/30701
Finally I'm starting to understand (I guess?)! So a root account is not enabled by default and an  ...

The administrator account has sudo rights by typing sudo and there normal password. su is to access root and has explained above from the Debian wiki not normally needed, more for advanced users to Linux.
Reply View the author
New Thread

Popular Events

More
国际排名
WHLUG