How to provide SFTP access to FTP normal usersIt is possible to provide SFTP access to domain users in Plesk from Plesk control panel itself. But it is not possible to provide SFTP access for normal FTP users.
In order to provide SFTP access for domain user just follow the steps below.
1) Login to Plesk
2) Click the "Websites & Domains" tab.
3) Click "FTP Access".
4) Click the FTP account to which you want to grant SFTP access.
5) Change the "Access to the server over SSH" drop-down menu to any value other than "Forbidden". The most secure choice is "/bin/bash (chrooted)" which will allow SFTP and very little else.
In the case of normal users, there won't have such option.
You won;t be able to access your server via SFTP using that user.
w8:~$ sftp normalusr@domainname.com
Connecting to domainname.com...
normalusr@domainname.com's password:
Connection closed
In order to provide this access, check the shell of the domain user to which you have just provided shell access.
root:~# cat /etc/passwd | grep mhtest*
mhtest:x:10011:115::/var/www/vhosts/mhtest.com:/opt/psa/bin/chrootsh
We could see that it is '/opt/psa/bin/chrootsh' . Assign this shell to your other user.
root:~#chsh normalusr
Changing the login shell for normalusr
Enter the new value, or press ENTER for the default
Login Shell [/bin/false]: /opt/psa/bin/chrootsh
Now try to access your server vuia SFTP using this user.
w8:~$ sftp normalusr@domainname.com
Connecting to domainname.com...
normalusr@domainname.com's password:
sftp> pwd
Remote working directory: /
Enjoy.......