Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium


absolute BEGINEERS question

Posted on 2004-11-06
Medium Priority
Last Modified: 2013-12-15
Please bear with me.....this is my first time

I'v just installed Red Hat 9 on my system.

I did it in custom mode coz I wanted all development tools(perl modules to php and everything in between)

The installation went off fine. When I logged in first time, I created a default user as 'user'/'manav'/'manav2' (I tried \3 installations, each time using one of these users, but evrytime, the following problems occur)

Now the problems
1) As root, I did add few users thru
useradd -d /home/manav -n -p mypassword -g 700 manav

the gid 700 I had created before(-n for not creating a new group everytime)

When I log out of root and try to login as manav,it dioesnt accept me in, saying the password is wrong. I am only able to log in as root. I am not even able to login as 'users'/'manav'/'manav2' (the login which I created first tim at bootup.

few points
- /etc/passwd and /etc/group show correct entries for gid etc.
- I even tried removing the enable-md5 for password and the /etc/passwd shows the correct
- i tried to su - as manav from root. It does properly. however, when i do a passwd then, it asks for the passwd and doesnt accept mypassword.
- In gnome(as root), through 'System-setting" -> "users and groups", I tried to change the password for user manav. when I do an ok and reselect properties for manav, it shows 5 asterisks.
- /etc/nologin doesnt exist

It seems to me that maybe somehow my system is configured to login only as root. I've tried the installaiton 3 times and same thing happens.

Please help,

Question by:manav_mathur
  • 2
  • 2
LVL 16

Author Comment

ID: 12513290
>- I even tried removing the enable-md5 for password and the /etc/passwd shows the correct

shoud be
- I even tried removing the enable-md5 for password and the /etc/passwd shows the correct password 'mypassword'

LVL 17

Expert Comment

ID: 12513624
Have you tried to login as root and change the passwd for the user?" passwd manav". If that doesnt work you can try deleting manavs password - login as root and run passwd -d manav.
LVL 40

Assisted Solution

jlevie earned 320 total points
ID: 12513968
Your problem is that you included "-p mypassword" in the user add command. The use of that option required that "mypassword" be the encrypted representation of the password, not the actual password.

The fix is easy. First run authconfig and re-enable MD5 password encryption. Then execute (as root) 'passwd manav', enter the password twice when prompted. You'll then be able to log in a manav
LVL 16

Author Comment

ID: 12522625

thanx for that. I even see it now in the man document. And it says using the crypt function for that.

I am thinking

1) useradd -d /home/manav -n -p crypt(mypassword,ae) -g 700 manav
could do it??

2)in Gnome, why does the password box in 'Users and setting' -> 'Properties' for a particular user always
display 5 asterisk??

does passwd -d manav create a new account with /etc/login.defs standard definitions.

Anyways, I think I'll divide the points 75-70(jlevie:owensleftfoot), thats ok??

Thnx again guys,

LVL 17

Accepted Solution

owensleftfoot earned 180 total points
ID: 12522679
Passwd -d deletes a users password - it enables them to login without any password at all.

Featured Post

Restore individual SQL databases with ease

Veeam Explorer for Microsoft SQL Server delivers an easy-to-use, wizard-driven interface for restoring your databases from a backup. No expert SQL background required. Web interface provides a complete view of all available SQL databases to simplify the recovery of lost database

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
In the first part of this tutorial we will cover the prerequisites for installing SQL Server vNext on Linux.
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Suggested Courses
Course of the Month14 days, 9 hours left to enroll

577 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question