[K12OSN] Moving Home files to a new server

Rob Owens rowens at bio-chemvalve.com
Wed Oct 10 14:14:48 UTC 2007


Not that I know of.

The reason you are seeing numbers in the user and group field is that
particular system has no username associated with the number you are
seeing.  Note that the 'find' command I posted below still works if you
specify a UID number in the 'wrongusername' field.

-Rob

Krsnendu dasa wrote:
> Is there a way to nfs mount a drive from another system with the same names
> but different uids and gids. I have just installed Edubuntu after previously
> installing K12ltsp. I used smbldap both times but I chose to make a new
> database the second time. If I copy the files from the old machine to the
> new machine the permissions match (showing names) but if I mount with nfs
> directly from the other machine it only shows numbers (not names) and
> therefore the user and group ownership doesn't match.
> 
> Is there a /etc/exports or /etc/fstab option to get around this?
> 
> Krsnendu dasa
> 
> On 10/10/2007, Rob Owens <rowens at bio-chemvalve.com> wrote:
>> Carl,
>>
>> The system assigns ownership based on UID and GID (numbers) and
>> "translates" that to usernames.  Your user and group ID numbers in
>> /etc/passwd and /etc/group need to be the same on the new system as they
>> were on the old system.
>>
>> Alternatively, you can fix your problems by doing a "find" of files
>> owned by a particular user and change ownership to the proper user.
>> Same thing for groups.  Like this:
>>
>> find /home -user wrongusername -exec chown -R rightusername {} \;
>> find /home -group wronggroup -exec chgrp -R rightgroup {} \;
>>
>> Please test this on a small batch of files before letting it loose on
>> your whole system.  Also note that I specified /home as the path.  You
>> may have other folders to search, for instance /mnt/shared_drive or
>> something.
>>
>> -Rob
>>
>> Carl Keil wrote:
>>> Hi Folks,
>>>
>>> So, the big disaster happened.  My K12LTSP hard drive died.  I've got
>>> everything backed up (thank you BackupPC), so I thought I was golden,
>>> but I'm having a weird problem.
>>>
>>> When I restore files from backup they are showing up "read only" in
>>> people's directories.  When I do a "ls -la /home/username" it is showing
>>> that the files are owned by other users and other groups.  A "chown -R
>>> username:groupname /home/username" doesn't solve the problem.
>>> I tried copying over all the 500+ /etc/passwd and /etc/shadow info from
>>> the most recent backup but after that I couldn't even log in as
>>> different users.  Any suggestions for what I should do?  I'd really like
>>> to just set up new user accounts for everyone and then just copy over
>>> selected files from backup for each user.  This is a family installation
>>> of K12LTSP, so there are only about 10 user accounts.  I used "useradd"
>>> on the new server to create everyone's account and I don't think I did
>>> them in the same order as the original server.  Should I delete everyone
>>> and re-add them in the exact same order?  I could do that based on
>>> /etc/passwd from the backup?
>>>
>>> Thanks a lot,
>>>
>>> ck
>>>
>>> _______________________________________________
>>> K12OSN mailing list
>>> K12OSN at redhat.com
>>> https://www.redhat.com/mailman/listinfo/k12osn
>>> For more info see <http://www.k12os.org>
>> _______________________________________________
>> K12OSN mailing list
>> K12OSN at redhat.com
>> https://www.redhat.com/mailman/listinfo/k12osn
>> For more info see <http://www.k12os.org>
>>
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> K12OSN mailing list
> K12OSN at redhat.com
> https://www.redhat.com/mailman/listinfo/k12osn
> For more info see <http://www.k12os.org>




More information about the K12OSN mailing list