Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
TetraWiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Linux 101 hacks
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Special pages
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=='''Hack 70. Create a new user'''== '''Add a new user β Basic method''' Specify only the user name. <nowiki># </nowiki>useradd jsmith '''Add a new user with additional Parameter''' You can also specify the following parameter to the useradd o -c : Description about the user. # ## -e : expiry date of the user in mm/dd/yy format # '''adduser -c "John Smith - Oracle Developer" -e 12/31/09 jsmith ''' Verify that the user got added successfully. <nowiki># grep jsmith /etc/passwd jsmith:x:510:510:John Smith - Oracle Developer:/home/jsmith:/bin/bash</nowiki> '''Change the user password.''' <nowiki># </nowiki>'''passwd jsmith''' Changing password for user jsmith. New UNIX password: BAD PASSWORD: it is based on a dictionary word Retype new UNIX password: passwd: all authentication tokens updated successfully. '''Note: '''Make sure to follow''' '''[http://www.thegeekstuff.com/2008/06/the-ultimate-guide-for-creating-strong-passwords/ ][http://www.thegeekstuff.com/2008/06/the-ultimate-guide-for-creating-strong-passwords/ these best practices][http://www.thegeekstuff.com/2008/06/the-ultimate-guide-for-creating-strong-passwords/ ]to''' '''create a strong password''' '''for the user. '''How to identify the default values used by useradd?''' Following are the default values that will be used when an user is created. <nowiki># </nowiki>'''useradd βD''' GROUP=100 HOME=/home INACTIVE=-1 EXPIRE= SHELL=/bin/bash SKEL=/etc/skel
Summary:
Please note that all contributions to TetraWiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
TetraWiki:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)