Q:

How to lock user to directory?

I created new user
adduser david

Now I have problem. When I login with this user via WinSCP FTP manager, default login directory is /home/david/. I need change for this user default direcory to /var/www/web/css/ and lock him into this folder.
How?

A:

You can edit this in
/etc/passwd
The fields in /etc/passwd are separated by :
The last but on field is the user's home directory.
Just make sure you do not introduce any extra spaces.

