Take the 2-minute tour ×

How can I put a user in a default directory when the logs in via SSH on Ubuntu? Currently, users are in ~ but I want them in something like /path/to/something. How is this configured? The machine will always have the path.

Many thanks :).

share|improve this question
Do you mean changing the home directory? –  Lucas Kauffman Apr 5 '12 at 10:18

2 Answers 2

up vote 5 down vote accepted

If you want to keep the users home directory but change the dirextory where they login to then you would have to add a cd /path/to/something at the end of the /etc/profile or $HOME/.profile

share|improve this answer

If you want to change the home directory of a user, you can use:

$ sudo usermod -d /path/to/new/home username
share|improve this answer

Your Answer


