LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 03-11-2011, 06:31 AM   #1
shree24985
LQ Newbie
 
Registered: Jan 2009
Location: Mumbai
Distribution: slackware
Posts: 15

Rep: Reputation: 0
Adding entries directly in /etc/passwd,/etc/shadow file


Hello,

I am working on building a customized ISO image of a server based on linux.
The thing is after the server is installed and run for the first time, three users have to be created for the various services to run properly. I want this to be automated.

TO achieve this what is was thinking is automatically enter the user entries in the /etc/passwd and /etc/shadow files through init scripts when the server starts for the first time after the installation.

I tried creating user and assigning password in one of my machine, and the /etc/passwd and the /etc/shadow entries of this user i copied it into the other machine and tried login in on the other machine and evertyting worked fine.

Please advise if there is anything wrong in how I am trying to achieve this.

Thanks
 
Old 03-11-2011, 07:22 AM   #2
rafatmb
LQ Newbie
 
Registered: Feb 2011
Posts: 27

Rep: Reputation: 3
Hi,

No problem on that. I have some scripts that does something like this.

[]'s

Rafa
Linux, Linux and Linux! Suporte Linux
 
  


Reply


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
[SOLVED] Deleted root from passwd and shadow file adloaiz Linux - Newbie 1 10-07-2010 01:34 PM
What is the easiest way to replace a hash in a shadow file, not using passwd? abefroman Programming 3 08-05-2010 06:56 AM
Manually adding users and the shadow file... Tim356 Red Hat 3 08-05-2008 06:00 AM
Removing user entries from the shadow file kaplan71 Linux - Security 1 01-17-2008 07:03 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 11:52 PM.

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