Linux - SecurityThis forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hello
My problem is I seem to lose my root password and can only login as root by a re-boot.
I own the complete RH 7.1 and could easily re-install. For many reasons I do not want to do this! I have upgraded the kernal to 7.3 and added programs and such. Plus re-booting IMHO (and re-installing) is not a grand solution.
I think that this is a problem deeper in the user admin area of the o/s in that some profiles or something 'sees' different passwords?
and rebooting is this newbie's only way to get them 'cleared' back to the newest one.
====the story
This is a stand-alone dualboot machine I am using to teach myself Linux. It is basically a workstation with internet, no security issues, just a "classroom".
One day I was logged in as a user (eddacker) and needed to su and my password failed. I can't login as root, but all my users and their passwords are still good.
I seemed to have lost my 'root' password???
So I use my boot disk, login as root and go to passwd/shadow; wipe out the hash and reboot. I enter a new root password and because I am pendantic it is a secure one.
And it works fine, until (sometimes) when I am logged on as my default (or other) user and need to switch to root and then the password doesn't work?? sometimes. If I reboot it always works. I can login as root and switch to a user and back to su and a user and then -- it fails -- login incorrect, as if I have entered a bad password. argghhhh
======the question
What I am asking is complicated so I have no idea how to ask it other than "what is going on?" Why does my root passwd work on re-boot, but fails when switching users?
TIA
eddacker
ahh, ha!
no I did not. And I am such a newbie I did not know I could [cntrl] X and boot: single
so I have learned. I will try the delete everything in /etc/passwd and /etc/shadow and see how that goes )
but this is a great journey, thank you for your reply.
eddacker
Hey! **grins**
this is a stand-alone machine, I am root and all the users.
or is there some other danger in deleting everything in passwd and shadow?
and is that why I am getting such inconsistant results, with my root password working on reboot and then not?
If you take a look at /etc/passwd, you will notice many users such as xfs, halt, mail, etc.
These system users are required by the various Linux daemons (programs).
Deleting them will causes problems.
Try resetting the passwords for root and the normal users (the ones you created) using the passwd command.
Using Mandrake 9.1 and trying to change the root password (because I cannot remember it) I have used the CD1 and at the root@rescue prompt I find that there is not a passwd command. Please help a Newbie!
I also forgotten my password, but could not understand how do you set a new one(I don't know any linux commands so bear with me please). Will it be better if I just reinstall linux? I would rather not. Please help and remember I know nothing about linux (Iam a windows user)
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.