LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-29-2006, 09:36 AM   #1
pilot11
Member
 
Registered: Sep 2006
Location: Surrey, UK
Distribution: CentOs version 4 X86_64 Dell PowerEdge 2900 2 gig Ram. Raid array 5
Posts: 33

Rep: Reputation: 15
This has got be a daft question.. how do I log in???


I have loaded my spanking new Centos X86_64 and am looking at the log in screen for the graphical interface... but I didn't set a user password. The root pasword takes me to the command line where I am lost.

Help... thanks in advance
 
Old 09-29-2006, 09:43 AM   #2
deroB
Member
 
Registered: Dec 2005
Location: Sydney, Australia
Distribution: Arch Linux
Posts: 208

Rep: Reputation: 30
Did the install process give you the option to add a user?

If not you will need to add a user. To do this (as root) type:
Code:
useradd -m pilot
-where "pilot" can be any name
-m will create a home directory

see http://webtools.live2support.com/linux/useradd.php for more options
 
Old 09-29-2006, 09:50 AM   #3
pilot11
Member
 
Registered: Sep 2006
Location: Surrey, UK
Distribution: CentOs version 4 X86_64 Dell PowerEdge 2900 2 gig Ram. Raid array 5
Posts: 33

Original Poster
Rep: Reputation: 15
Thanks ! that added a user OK but there is still no password and return log in incorrect ?


I couldn't find an option to add a user in set up. did I miss it?
 
Old 09-29-2006, 09:50 AM   #4
MOS JEFF-INITELY
Member
 
Registered: Sep 2006
Distribution: Windows .. MUAHAHAHA
Posts: 66

Rep: Reputation: 15
if you have created the user and only need the password created you can set it as root with the command 'passwd username'
 
Old 09-29-2006, 09:56 AM   #5
pilot11
Member
 
Registered: Sep 2006
Location: Surrey, UK
Distribution: CentOs version 4 X86_64 Dell PowerEdge 2900 2 gig Ram. Raid array 5
Posts: 33

Original Poster
Rep: Reputation: 15
OK I have the user pilot but when I put in the root password I still get an incorrect log in?

sorry but "command 'passwd username' doesn't mean much to me at the moment ?
 
Old 09-29-2006, 09:56 AM   #6
deroB
Member
 
Registered: Dec 2005
Location: Sydney, Australia
Distribution: Arch Linux
Posts: 208

Rep: Reputation: 30
Quote:
Originally Posted by MOS JEFF-INITELY
if you have created the user and only need the password created you can set it as root with the command 'passwd username'
yep... that would have been handy if I added that
 
Old 09-29-2006, 09:58 AM   #7
deroB
Member
 
Registered: Dec 2005
Location: Sydney, Australia
Distribution: Arch Linux
Posts: 208

Rep: Reputation: 30
since you have pilot as a user

Code:
passwd pilot
as root
 
Old 09-29-2006, 10:07 AM   #8
MOS JEFF-INITELY
Member
 
Registered: Sep 2006
Distribution: Windows .. MUAHAHAHA
Posts: 66

Rep: Reputation: 15
ok .. let me clarify.
There are binary files (executables) which are commands in the command line. You can find these commands in several folders in / such as /usr/bin or /sbin (there are more). One of the commands passwd can change user passwords. Since root is the administrator he/she can change any users password.

to change the root password root would use the command:
passwd

to change the user mosjeff's password root would only need to use the command:
passwd mosjeff

root also has the power to become any user without a password:
su username

for root to become mosjeff they would use the command:
su mosjeff

you can also create a password while adding a user with useradd by specifying the parameter -p passwordhere
 
Old 09-29-2006, 10:13 AM   #9
pilot11
Member
 
Registered: Sep 2006
Location: Surrey, UK
Distribution: CentOs version 4 X86_64 Dell PowerEdge 2900 2 gig Ram. Raid array 5
Posts: 33

Original Poster
Rep: Reputation: 15
start form scratch as this is not having it

log in to root.

Set a new user as

useradd -m pilot passwd newpassword

log out as root and log back in as above and I should be in??


Thanks in advance
 
Old 09-29-2006, 10:24 AM   #10
pilot11
Member
 
Registered: Sep 2006
Location: Surrey, UK
Distribution: CentOs version 4 X86_64 Dell PowerEdge 2900 2 gig Ram. Raid array 5
Posts: 33

Original Poster
Rep: Reputation: 15
I logged in as root OK

useradd -m username -p password

returned to root no errors

log in screen set username and password and have incorrect log in ??

am I wrong ??
 
Old 09-29-2006, 10:25 AM   #11
MOS JEFF-INITELY
Member
 
Registered: Sep 2006
Distribution: Windows .. MUAHAHAHA
Posts: 66

Rep: Reputation: 15
no.
login as root.

in xterm type the following or copy and paste:
useradd -m pilot; passwd pilot

now before you logout ensure the user was created as root type(copy) this:
su pilot

you should now be the user pilot, to check this type:
whoami

it should tell you your pilot, now exit pilot by typing:
exit

this will bring you back to root, to exit root type:
logout

now try to login as pilot with whatever password you created with the passwd command

Last edited by MOS JEFF-INITELY; 09-29-2006 at 10:34 AM.
 
Old 09-29-2006, 10:38 AM   #12
pilot11
Member
 
Registered: Sep 2006
Location: Surrey, UK
Distribution: CentOs version 4 X86_64 Dell PowerEdge 2900 2 gig Ram. Raid array 5
Posts: 33

Original Poster
Rep: Reputation: 15
Logged in as root

root@server root] # useradd -m orange; passwd apple

return

the response was

passd: Unknown username 'apple'

root@server root] #

sorry to try your resolve here ?
 
Old 09-29-2006, 10:41 AM   #13
Nylex
LQ Addict
 
Registered: Jul 2003
Location: London, UK
Distribution: Slackware
Posts: 7,464

Rep: Reputation: Disabled
You need to use the username for the account you want to change the password for, in your last post this was "orange".
 
Old 09-29-2006, 10:44 AM   #14
MOS JEFF-INITELY
Member
 
Registered: Sep 2006
Distribution: Windows .. MUAHAHAHA
Posts: 66

Rep: Reputation: 15
the passwd command takes a username as a parameter not the actual password.

for example if user is orange:
passwd orange

then it will prompt you something like this:
New password:

enter your password. (apple)

then it will prompt you again.. something like this:
Re-enter new password:

re-enter the password you just created. (apple)
 
Old 09-29-2006, 10:47 AM   #15
pilot11
Member
 
Registered: Sep 2006
Location: Surrey, UK
Distribution: CentOs version 4 X86_64 Dell PowerEdge 2900 2 gig Ram. Raid array 5
Posts: 33

Original Poster
Rep: Reputation: 15
That did it !


thank you so much for your help.

Your patience is much appreciated.

Many thanks.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
daft desktop / gnome question gsd750 Linux - Newbie 2 09-10-2004 10:55 AM
Question 1 Firewall Log Question 2 Network Monitor Soulful93 Linux - Networking 4 08-04-2004 11:05 PM
Please answer some basic questions froma daft newbie jmpm Linux - Newbie 7 01-06-2004 06:49 AM
yet another daft floppy problem Bungholio Linux - General 5 07-07-2003 01:34 PM
Another daft newbie question Scamps Linux - Newbie 2 11-24-2001 01:39 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:02 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration