Change or set your user’s home directory to something other than the default
Last Updated on Saturday, 3 May o 08:26 Written by admin Thursday, 1 May o 10:57
Follow this howto to change the path of the users home directory to a different location.
You will need to edit the /etc/passwd file as root.
sudo nano /etc/passwd
You will find a line similar to the one below:
xxxx:x:1000:1000::/home/xxxx/:/bin/bash
which you can change to, for instance,
xxxx:x:1000:1000::/etc/johndoe/:/bin/bash
to change the user xxxx’s home directory to /etc/johndoe/.
Tags: home directory