Visit Jeremy's Blog.
Go Back > Forums > Other *NIX Forums > Solaris / OpenSolaris
User Name
Solaris / OpenSolaris This forum is for the discussion of Solaris and OpenSolaris.
General Sun, SunOS and Sparc related questions also go here.


  Search this Thread
Old 06-16-2010, 05:13 AM   #1
Registered: Nov 2003
Location: Bangladesh
Distribution: Solaris 10, FreeBSD 5.4
Posts: 101

Rep: Reputation: 15
migrate /etc/shadow from Solaris 10 to other Unix/Linux OS Versions

Dear All,

I need to setup a server in Unix/Linux platform where i need to setup 300+ user accounts with no change in the user password from the primary server.

The primary server runs on Solaris 10.

Any idea how to migrate the /etc/shadow file. I have been googling for quite some time with 0 luck.

Thanks in advance
Old 06-16-2010, 06:22 AM   #2
Senior Member
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,822

Rep: Reputation: 610Reputation: 610Reputation: 610Reputation: 610Reputation: 610Reputation: 610
Just copy it over?

You'll need to copy passwd and group as well. And as always, make backups of these files.
Old 06-16-2010, 09:05 AM   #3
Registered: Nov 2003
Location: Bangladesh
Distribution: Solaris 10, FreeBSD 5.4
Posts: 101

Original Poster
Rep: Reputation: 15
Thanks but Tried copying entries & it didn't work out!

Please let me know if I missed anything! It works fine if i copy from One Solaris system to another Solaris - OS version doesn't cause any problem.

I was actually trying to copy it from a Solaris system to a Redhat system and later on will try it on a FreeBSD system.

so far no luck!
Old 06-21-2010, 10:55 AM   #4
Registered: Jul 2003
Location: Clinging to my guns and religion.
Posts: 683

Rep: Reputation: 63
As you have found you can copy within environments, solaris to solaris and linux to linux, but not linux to solaris.

Each environment encrypts the password differently so you cannot just copy the password hash across. (The Linux hash is about twice the length of the solaris one). You will probably wind up requesting users set up their password on a linux server and a solaris then copying those as needed or setting them to a defined password.
Old 06-21-2010, 04:31 PM   #5
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.3, Oracle Linux, Mint
Posts: 9,690

Rep: Reputation: 405Reputation: 405Reputation: 405Reputation: 405Reputation: 405
Passwords are not really crypted on Unix systems but hashed, i.e. they cannot be decrypted.

The hashing algorithm can be configured on Solaris from the traditional crypt_unix one to one compatible with Linux by modifying the CRYPT_DEFAULT parameter in the policy.conf file. For an example, see:

Of course, modifying this setting will only affect new passwords so you'll need to wait for all your users to have renewed their password to have a compatible /etc/shadow file. This might be never depending on your expiration policy.

This file is also telling what algorithms will be accepted while processing password. I don't know if such a configuration file exist in the Linux distribution you use but that would be another way to solve your problem.

Usually, this kind of heterogeneous authentication issues are better handled by separating the user's operating systems from the authentication service, usually NIS or LDAP.


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
Account name length in various versions of linux/unix? davidstvz Linux - Newbie 2 08-22-2008 12:44 PM
LXer: Unisys Tools Migrate WebLogic/Unix Stack to JBoss/Linux LXer Syndicated Linux News 0 06-14-2006 01:33 PM
migrate from shadow to vmail password freelinuxcpp Linux - Networking 0 10-03-2004 06:13 AM
how i migrate unix to linux or any appli to linux vandarakalpesh Linux - General 1 06-26-2004 05:52 AM
Migrate from older passwd/shadow to NIS JesteR Linux - General 0 11-28-2001 06:03 AM

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

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