Articles in this section

Unable to start migration using 'root' user and its password in Plesk Migrator: Failed to connect to the source domain by SSH: Bad authentication type

Plesk for Linux kb: technical ext: migrator

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

  1. Connect to the source server via SSH.
  2. Open /etc/ssh/sshd_config file in a text editor. In this example, we are using vi editor:

    # vi /etc/ssh/sshd_config

  3. Set PasswordAuthentication and PermitRootLogin directives to 'yes' and remove '#' at the beginning of each line as shown below:

    CONFIG_TEXT: PermitRootLogin yes
    PasswordAuthentication yes

  4. Save the changes and close the file.
  5. Verify that these directives are defined in /etc/ssh/sshd_config only: not defined in other .conf files 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 yes

    Note: If these directives are defined in other .conf files inside /etc/ssh, remove them form these files.

  6. Restart SSH service:

    # service sshd restart

  7. Restart migration.

 

Additional Information

To migrate with a non-root user, see:

Was this article helpful?

Comments

0 comments

Please sign in to leave a comment.