Symptoms
FTP users are not able to connect with the following error:
Connected to example.com (203.0.113.2).
220 Microsoft FTP Service
Name (example.com): user
331 Password required
Password:
530 User cannot log in, home directory inaccessible.
Login failed.
Remote system type is Windows_NT.Status: Insecure server, it does not support FTP over TLS.
Command: USER johndoe
Response: 331 Password required
Command: PASS ********
Response: 530 User cannot log in, home directory inaccessible.
Error: Critical error: Could not connect to serverFTP user is absent in the IIS > Sites > 203.0.113.2 > localuser or there is no such FTP site at all.
Cause
Misconfiguration of the FTP websites and FTP users.
Resolution
Log into the server via RDP.
Execute the following command via the command line:
plesk repair ftp -y
Note: There is a probability, that the issue is resolved completely by this command. Check FTP access once again. In case the issue will persist, proceed further with the resolution.
Execute the following command via the command line in order to re-create the FTP site and users in IIS:
For one domain
"%plesk_cli%repair.exe" --reconfigure-ftp-site -webspace-name example.com
"%plesk_cli%repair.exe" --repair-webspace-system-users -webspace-name example.com
For all domains
- Reconfigure an FTP service for all domains in PowerShell using these two commands:
PS plesk bin subscription -l | % { if ($) { plesk bin repair --reconfigure-ftp-site -webspace-name $ } }
PS plesk bin subscription -l | % { if ($) { plesk bin repair --repair-webspace-system-users -webspace-name $ } }