[solved] issues with migration tool

Discussion in 'Plugins/Modules/Addons' started by harkman, Jul 11, 2019.

  1. harkman

    harkman Member HowtoForge Supporter

    Hello.
    I try to move my server to a new instance.
    Source is debian 7 / PHP 5.4.45
    Target ubuntu 18.04 / PHP 7.2.19
    ISPConfig is 3.1.14p1 on both systems
    the migration seems to run, but I get sporadic NO ACCESS DENIED errors:
    Code:
    2019-07-11 09:05:01 - [INFO] Config file not present.
    2019-07-11 09:05:01 - [INFO] Migration tool version 2.0.13 started.
    2019-07-11 09:07:20 - [ERROR] JSON API ERROR in API call (get_function_list): NO ACCESS
    2019-07-11 09:07:20 - [INFO] Trying again (get_function_list)
    2019-07-11 09:07:24 - [INFO] Target ISPConfig version is 3.1.14p1
    2019-07-11 09:07:40 - [ERROR] JSON API ERROR in API call (server_get_all): NO ACCESS
    2019-07-11 09:07:40 - [INFO] Trying again (server_get_all)
    2019-07-11 09:07:59 - [ERROR] JSON API ERROR in API call (server_get): NO ACCESS
    2019-07-11 09:07:59 - [INFO] Trying again (server_get)
    2019-07-11 09:08:29 - [INFO] Source is multiserver? no
    2019-07-11 09:08:29 - [INFO] Target is multiserver? no
    2019-07-11 09:09:38 - [INFO] Config file saved.
    2019-07-11 09:09:38 - [INFO] Found 1 Reseller entries.
    2019-07-11 09:09:38 - [INFO] Found 43 Client entries.
    2019-07-11 09:09:38 - [INFO] Found 71 Domain entries.
    2019-07-11 09:09:38 - [INFO] Found 45 WebDomain entries.
    2019-07-11 09:09:38 - [INFO] Found 11 VHost SubDomain entries.
    2019-07-11 09:09:38 - [INFO] Found 0 VHost AliasDomain entries.
    2019-07-11 09:09:38 - [INFO] Found 14 AliasDomain entries.
    2019-07-11 09:09:38 - [INFO] Found 4 SubDomain entries.
    2019-07-11 09:09:38 - [INFO] Found 46 MailDomain entries.
    2019-07-11 09:09:38 - [INFO] Found 11 MailAliasDomain entries.
    2019-07-11 09:09:38 - [INFO] Found 39 MailUser entries.
    2019-07-11 09:09:38 - [INFO] Found 5 MailForward entries.
    2019-07-11 09:09:38 - [INFO] Found 41 MailAlias entries.
    2019-07-11 09:09:38 - [INFO] Found 1 MailCatchAll entries.
    2019-07-11 09:09:38 - [INFO] Found 0 MailFilter entries.
    2019-07-11 09:09:38 - [INFO] Found 1 MailTransport entries.
    ...
    2019-07-11 10:16:16 - [ERROR] JSON API ERROR in API call (mail_domain_get): NO ACCESS
    2019-07-11 10:16:16 - [ERROR] API call to mail_domain_get failed.
    2019-07-11 10:16:16 - [ERROR] JSON API ERROR. Arguments sent were: array (
      'primary_id' =>
      array (
        'domain' => 'abc.com',
      ),
      'session_id' => 'f212ced39d76dc143036a45e9e82eaeb',
    )
    2019-07-11 10:16:33 - [ERROR] JSON API ERROR in API call (mail_domain_get): NO ACCESS
    2019-07-11 10:16:33 - [INFO] Trying again (mail_domain_get)
    2019-07-11 10:16:52 - [ERROR] JSON API ERROR in API call (mail_domain_get): NO ACCESS
    2019-07-11 10:16:52 - [INFO] Trying again (mail_domain_get)
    2019-07-11 10:17:11 - [ERROR] JSON API ERROR in API call (mail_aliasdomain_get): NO ACCESS
    2019-07-11 10:17:11 - [INFO] Trying again (mail_aliasdomain_get)
    2019-07-11 10:17:32 - [ERROR] JSON API ERROR in API call (mail_aliasdomain_get): NO ACCESS
    2019-07-11 10:17:32 - [INFO] Trying again (mail_aliasdomain_get)
    2019-07-11 10:17:52 - [ERROR] JSON API ERROR in API call (mail_aliasdomain_get): NO ACCESS
    2019-07-11 10:17:52 - [INFO] Trying again (mail_aliasdomain_get)
    2019-07-11 10:18:15 - [ERROR] JSON API ERROR in API call (mail_aliasdomain_get): NO ACCESS
    2019-07-11 10:18:15 - [INFO] Trying again (mail_aliasdomain_get)
    2019-07-11 10:18:35 - [ERROR] JSON API ERROR in API call (mail_aliasdomain_get): NO ACCESS
    2019-07-11 10:18:35 - [INFO] Trying again (mail_aliasdomain_get)
    2019-07-11 10:18:54 - [ERROR] JSON API ERROR in API call (mail_user_get): NO ACCESS
    2019-07-11 10:18:54 - [INFO] Trying again (mail_user_get)
    2019-07-11 10:19:13 - [ERROR] JSON API ERROR in API call (mail_user_get): NO ACCESS
    2019-07-11 10:19:13 - [INFO] Trying again (mail_user_get)
    
    Any Idea what might go wrong here?
     
  2. Jesse Norell

    Jesse Norell Well-Known Member

    My first guess is your remote api user doesn't have all the permissions see which it needs.
     
  3. till

    till Super Moderator Staff Member ISPConfig Developer

    If the errors are just sporadic, check that you don't use a system that blocks when to many requests arrive like mod_evasive as the tool does a lot of requests to the ISPConfig remote API in a short time and if you have any sftware in place on the new server to prevent dos attacks, then its possible that it kicks in during migration. If you need further help, please contact our support directly here: https://www.ispconfig.org/get-support/?type=migration
     
  4. harkman

    harkman Member HowtoForge Supporter

    @Jesse Norell see this:
    Code:
    2019-07-11 09:07:20 - [ERROR] JSON API ERROR in API call (get_function_list): NO ACCESS
    2019-07-11 09:07:20 - [INFO] Trying again (get_function_list)
    2019-07-11 09:07:24 - [INFO] Target ISPConfig version is 3.1.14p1
    
    The migration script gets an error, tries again and gets a result.
    My remote user has every right checked and remote connection checkbox is checked too. I think this should be ok.

    @till Yes, looks like something is dropping requests. The target is a fresh install of Ubuntu and ISPConfig. I only installed fail2ban and the log is not showing my source IP.
    I opened a ticket. Thanks.
     
  5. florian030

    florian030 ISPConfig Developer ISPConfig Developer

    if you use the same server-name on both servers, you should stop f2b on the target.
     
  6. harkman

    harkman Member HowtoForge Supporter

    Thanks for all help. I found out what was going wrong.
    I previously had the target server configured and set up with ISPConfig on Debian 9.
    Because of the option to get 10 years of support I switched to Ubuntu 18.04.
    I did not notice that Ubuntu reconfigured my network interfaces and the vServer management from my hosting provider auto configured the IP6 address slightly different from the previous Debian 9.
    I ended up with wrong IP6 entries in my nameserver and the source server resolved the target server to wrong IP6 address.
    Then the migration tool tried to do its work. On every request, it first tried to connect over IPv6 when that failed the next request used the IPv4 address which was still correct.
    That was the reason why some requests did work ok and others failed.
    I found this out by sending requests from the source server to the target server with CURL. I saw the timeout on IPv6 and then the automatic switch to IPv4.
     
    Jesse Norell and till like this.

Share This Page