-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Database conversion: hangs forever #173
Comments
Is there anything in the log file? |
Nope |
The postgres log has something interesting:
It might be related to owncloud/core#24065. The converter crashes in the referenced issue. It hangs forever in my case. |
I deleted problematic rows (those had large contact photos) and now the converter hits this entry:
The good thing is: the converter now crashes and does no longer hang. |
Crashes means it throws an exception? |
@nickvergessen Yes |
I just tested the migration from sqlite to postgresql on Nextcloud 10.0.1 and it has the same issues as described above. Is there anything else I can provide? |
I'm getting the same error when converting oc_cards from sqlite to pgsql. It looks like row type information is not being preserved in ConvertType.php in copyTable() where rows are being read from one database and written to the other. setParameter() can optionally take a 3rd argument, the type, but it's not being set. But that's all I know, deducted this from stack traces, I know nothing about Doctrine or nextCloud code base and internet searches weren't helpful in figuring out how to retrieve the type information from source database. So no patch from me. Having type information for binary columns would allow the database abstraction layer to properly escape the values before inserting them. Stack trace: https://gist.github.com/gjedeer/603f9f882e272ac7ae9eb0d614a33fcb |
@icewind1991 could you have a look? |
I triggered the same behaviour while migrating from maria to postgres. |
I identified the problem, it's rather arbitrary that it happens with contacts. |
@nickvergessen thank you a lot! Hopefully I'll now be able to move to Postgres. |
Steps to reproduce
./occ db:convert-type --password <password> --all-apps --clear-schema pgsql <username> <hostname> <database>
Expected behaviour
A working database conversion.
Actual behaviour
The conversion hangs forever at
oc_cards
:Server configuration
Operating system: Arch Linux
Web server: Nginx
Database: SQLite
PHP version: 7.0.7
Nextcloud version: 9.0.50
Updated from an older Nextcloud/ownCloud or fresh install: Updated, starting from ownCloud 3.0
Where did you install Nextcloud from: archive
Signing status (Nextcloud 9.0 and above):
List of activated apps:
Are you using encryption: no
The text was updated successfully, but these errors were encountered: