Unix Technical Forum

Manually adding accounts to shadow password file?

This is a discussion on Manually adding accounts to shadow password file? within the Linux Operating System forums, part of the Unix Operating Systems category; --> Hi, I'm currently in the process of creating a back-up server for our primary linux system. My last sticking ...


Go Back   Unix Technical Forum > Unix Operating Systems > Linux Operating System

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 01-17-2008, 05:51 PM
lee jackson
 
Posts: n/a
Default Manually adding accounts to shadow password file?

Hi,
I'm currently in the process of creating a back-up server for our
primary linux system.

My last sticking point is how best to migrate/copy user accounts.
We're using shadow passwords and what I am wondering is if I can
literally copy and paste entries from the shadow password on the
primary system, into the shadow password file on the back-up system?
My primary aim from this is to enable existing users to log into the
back-up system without having to change their passwords.

Will this even work and what potential issues should I be aware of? Is
there any other way to achieve this "mirroring" of user details?

Many thanks

Lee Jackson
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 01-17-2008, 05:51 PM
Mauriat
 
Posts: n/a
Default Re: Manually adding accounts to shadow password file?

lee jackson wrote:

> Hi,
> I'm currently in the process of creating a back-up server for our
> primary linux system.
>
> My last sticking point is how best to migrate/copy user accounts.
> We're using shadow passwords and what I am wondering is if I can
> literally copy and paste entries from the shadow password on the
> primary system, into the shadow password file on the back-up system?
> My primary aim from this is to enable existing users to log into the
> back-up system without having to change their passwords.
>
> Will this even work and what potential issues should I be aware of? Is
> there any other way to achieve this "mirroring" of user details?
>
> Many thanks
>
> Lee Jackson


(My opinion) Technically a better way to do this is by having a separate
NIS (also known as YP) server that maintains all passwords, and telling
all machines (incluing the backup server) to authenticate via NIS from
the main NIS server.

However back to what you asked. I have done this before. The only key
changes I did was to copy all RELEVANT data from:
/etc/shadow
/etc/passwd
/etc/group

Since passwd contains both /home location and shell information, that
information MUST match. ex:
user1:x:500:500:Full Name:/home/user1:/bin/myshell
Directory /home/user1 and /bin/myshell must exist on the new machine.

This is just a starting point. Other files in /etc/ are needed for
important system functionality, but these are the minimum I needed to
allow access. I hope this helps.

--

Mauriat (www.mjmwired.net)
----------------------------
Remove 'NOSPAM' to email me.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 04:35 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com