Symptoms
-
Unable connect to the Plesk server via SFTP, the error below is shown:
subsystem request failed on channel 0
Couldn't read packet: Connection reset by peer -
The following errors can be found in
/var/log/syslog
or/var/log/messages
log file:www sshd[16588]: error: subsystem: cannot stat /usr/libexec/sftp: No such file or directory
www sshd[16588]: subsystem request for sftp failed, subsystem not found
Cause
The incorrect path to SFTP is set in the sshd configuration.
Resolution
- Log into the server via SSH.
- Verify that the
/usr/libexec/openssh/sftp-server
file is presented on the server:# ls -l /usr/libexec/openssh/sftp-server
-rwxr-xr-x 1 root root 100784 Aug 9 2019 /usr/libexec/openssh/sftp-server -
Using the vi text editor open the
/etc/ssh/sshd_config
file and specify value forSubsystem
directive as shown below:Subsystem sftp /usr/libexec/openssh/sftp-server
- Restart the sshd service:
# service sshd restart