Hi,
I have a problem with the Moodle database migration tool.
I need to move the data from a MySQL 8.0 database that is on the same server as the Moodle to a Postgres 12.4 database which is on a different server. Moodle version is 3.93, the web server used is Apache 2.4.
The migration starts, creates some tables and then hangs, after a few minutes. It recognizes that it has failed as it goes on to remove the /dataroot/climaintenance.html file that puts the server in maintenance mode and writes a message on a log: 'tool_dbtransfer: Interrupted database migration detected, switching off CLI maintenance mode.' There are no error messages on the screen, just that no more tables are listed as created. Switching on debugging does not produce more messages.
There is no sign of error in the Postgres end. Tables got created. If I try to restart migration with the same settings, it recognizes the tables created with the same prefix and refuses to go on.
The migration worked just fine in the test environment. Basically identical, just a lot smaller.
The obvious thing might be some value defined in php.ini, but I've tried adjusting them upwards and it has no effect on the point at which the migration stops (judging by the tables created), it stays the same. The last tabler id always user_enrolments, for some reason.
There's nothing to suggest that this is something caused by the data in the database (there was an extra, custom column in one table that I had to drop, but the same issue occurred in the test environment and there the migration worked fine). Still, production database is bigger than the test, has existed since at least Moodle 1.4 and has contained occasional surprises before, when some earlier upgrade hasn't upgraded all the database fields.
I'd greatly appreciate any suggestions on how to fix this.
Best Regards,
Petteri Itäkannas