Applicable to:
- Plesk for Linux
Symptoms
When starting migration using 'root' user and its password in Plesk Migrator, the initialization fails with one of the following error messages:
PLESK_ERROR: Failed to check SSH connection to the source server 'source' (203.0.113.2): Unable to connect to '203.0.113.2' by SSH: Bad authentication type; allowed types: ['publickey'].
Ensure that the server is up and there are no firewall rules that may block SSH connections to the server,
then restart migration.
PLESK_ERROR: Failed to perform action: Fetch data from source cPanel
Cause: Failed to connect to the the source server 'cpanel' (203.0.113.2) at '203.0.113.2' by SSH as 'root': ('Bad authentication type', [u'publickey', u'gssapi-keyex', u'gssapi-with-mic']) (allowed_types=[u'publickey', u'gssapi-keyex', u'gssapi-with-mic'])
That is a critical error, migration was stopped.
Cause
Password authentication (and/or root authentication) is disabled on the source server.
Resolution
- Connect to the source server via SSH.
-
Open
/etc/ssh/sshd_configfile in a text editor. In this example, we are using vi editor:# vi /etc/ssh/sshd_config
-
Set
PasswordAuthenticationandPermitRootLogindirectives to 'yes' and remove '#' at the beginning of each line as shown below:CONFIG_TEXT: PermitRootLogin yes
PasswordAuthentication yes - Save the changes and close the file.
-
Verify that these directives are defined in
/etc/ssh/sshd_configonly: not defined in other.conffiles inside/etc/ssh:# grep -ir PasswordAuthentication /etc/ssh | grep -v '#'
/etc/ssh/sshd_config:PasswordAuthentication yes# grep -ir PermitRootLogin /etc/ssh | grep -v '#'
/etc/ssh/sshd_config:PermitRootLogin yesNote: If these directives are defined in other
.conffiles inside/etc/ssh, remove them form these files. -
Restart SSH service:
# service sshd restart
- Restart migration.
Additional Information
To migrate with a non-root user, see:
Comments
Please sign in to leave a comment.