[K12OSN] hard drive upgrade

Liam Marshall lsrpm at mts.net
Sat Dec 11 18:06:25 UTC 2004

am am setting up to upgrade my harddrives.  I have been unable to find an 
elegent way to copy all the old partitions over to the new raided SATA 
drives, so I have decided to do a clean install, and transfer over home 
directories and users instead.  I did some research and came up with this 
how to off the net.  I would appreciate it if someone would look it over 
and let me know if this is going to work.  Otherwise I would have to go on 
faith.  I have almost 600 users so I don;t want to recreate all of them

Beginning of How To*************
the files you need to be concerned about to move users and passwords over are:


BUT it isn't as easy as just copying the old files to the new server ... 
you will need to edit the new files (on the new server) and add any users 
that are not already in the new files ... but don't change or add users 
that exist already in the new files.

SO ... copy the old passwd and shadow files over to the new server ... name 
them passwd.old and shadow.old

open /etc/passwd on the new server and passwd.old from the old server ...

the user john is in old ... but not new ... so copy the whole line for john 
from the old to the new file (add it at the bottom of the file) ... do that 
for all users not currently in new.

Now keep passwd (from the new server) open ... open shadow new and shadow 
old ... copy the entries for shadow old into shadow new (put them in using 
the same order that they are in on the new passwd file).

Now for /etc/group ... add all the groups not currently in new from old....

save the three new files /etc/passwd, /etc/shadow, /etc/groups
next, copy all the users directories from the old server to the new server 
(everything in /home old to /home new)

if the mail gets delivered to the home directories, you are done ... if it 
goes somewhere else, you need to copy those directories over as well...

End of How To***********

also, while I am at it I thought I would upgrade from K12LTSP 4.0 to either 
4.1 or 4.2.  Would it be ok to do that and still copy over the 
users/passwords/groups/ and their home directories as per the above 

More information about the K12OSN mailing list