Can I change the user id of a user on one Linux server to match another server in /etc/passwd?

Posted by user76177 on Server Fault See other posts from Server Fault or by user76177
Published on 2012-10-05T19:20:27Z Indexed on 2012/10/07 3:41 UTC
Read the original article Hit count: 558

Filed under:
|

I have a Rails application that is on a virtual machine (RHEL 6) and it's database is on dedicated hardware (also RHEL 6).

The app server has an NFS directory from the db server mounted and accessible. It needs to write images to that server that are uploaded via the app.

Background processes on the db server need to read and write to the same directory, as they perform resizing operations on the uploaded files.

Right now none of this is working, because the user ids are different between the two systems. I only need this to work for this one application, so it is way too much overhead to put an LDAP system in place.

Can I simply change the user id of this one user in one of the systems, or will that cause mass chaos?

UPDATE:

The fix worked, at least on local devices. Unfortunately the device I have mounted to the main db server still thinks my user id is 502 instead of 506. Do I need to remount that device, or is there an NFS daemon I can stop and restart to refresh it?

© Server Fault or respective owner

Related posts about linux

Related posts about users