Got it this time.
No error is reported, the php scripts complete without a problem.
I am starting to suspect that it could be nginx that is timing out.
Could you try increasing the values of
keepalive_timeout and client_body_timeout
I am thinking that a value of 300, 5minutes, should be enough for the script to complete the migration.
These values might be available in /etc/nginx/nginx.conf between the http { } block.
Make sure to make a backup first before editing that file.
You can safely add them and then reload your webserver.
After the migration is complete, remember to restore nginx.conf to it’s previous state.
I am available to help with any of the steps if you require additional help.
Let me know how it goes.
(We are working on a version that will be fixing the problem when the web server timeouts after a set of time)