LinuxQuestions.org
Review your favorite Linux distribution.
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 05-19-2011, 08:54 PM   #1
rramesh1
LQ Newbie
 
Registered: May 2011
Posts: 14

Rep: Reputation: 1
useradd command to create passwd, shadow & other files under different directory


Hello,

I am bulding my own image based on 2.6.32 kernel, I wish to add a guest user:

In a script thats invoked by the makefile, I use 'useradd' command & this updates the shadow, passwd files under /etc on the host, is it possible to tell the command to create the shadow / password under some other folder on the host? may be /tmp?

/Ramesh
 
Old 05-20-2011, 12:52 AM   #2
A.Thyssen
Member
 
Registered: May 2006
Location: Brisbane, Australia
Posts: 119

Rep: Reputation: 32
Typical method is to chroot to the top of the root filesystem you are building and then use the command as normal.
 
1 members found this post helpful.
Old 05-20-2011, 07:26 AM   #3
rramesh1
LQ Newbie
 
Registered: May 2011
Posts: 14

Original Poster
Rep: Reputation: 1
Thank you very much!
 
  


Reply

Tags
passwd, shadow, useradd


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
/etc/passwd & /etc/shadow a7mlinux Linux - General 2 08-02-2009 12:19 PM
create a user who can also run useradd and passwd only kkeith Linux - Newbie 5 06-29-2006 06:43 AM
/etc/passwd & /etc/shadow through php? whysyn Linux - Software 4 11-29-2005 10:29 PM
usermod, beyond passwd & shadow Hans Zilles Linux - General 0 11-26-2005 05:29 PM
Remove? /etc/shadow- & /etc/passwd- lcat Linux - Security 2 08-22-2004 10:26 AM


All times are GMT -5. The time now is 08:14 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration