I am reinstalling the older Ubuntu machines with the latest RHEL 6.0 in servers.
I have /etc/passwd and /etc/group and /etc/shadow file backed up for the list of user accounts that I need to create after reinstallation of OS.
I have installed RHEL 6.0 in couple of machines and I need to grant access to the users immediately.
I want to use the /etc/passwd and other files into this machine so that the users can start using the server with their user accounts. But, I do not wish to create a /home/user directory for the users for couple of reasons.
- The users will be accessing only the partition
/mountswhich apparently has the project data. -
I am eventually planning to configure
NFSandopenldapat a later stage. So, if I have to providehomedirectory for the users, I need to backup the home directory for the users in all the machines where I gave the local user account for users and put it in theNFSserver which is a redundant step.
Is it possible to give users access without home folder? I have seen machines without /home directory using / as the home directory. But I am not sure if this is a safe step and I want the users to be unaware that their home directories do not exist.
EDIT
I see the users can be added without creating the home directory for them using the below command.
adduser --system --no-create-home USERNAME
But my challenge lies in how can I use the same user account as in /etc/passwd and other files without creating a home directory? I want the users be able to use their same passwords as in /etc/passwd now without a home directory.
/their home directory (and optionally make/home/usera link to/, but be very careful when removing it later!!).-s /bin/falsewill not allow users to log in!useraddcommand. But that is not my main concern. My concern lies in using the same usernames/passwords as in/etc/passwdfile.