Open NeroNekro opened 1 year ago
cc @susnux
Looks like the form errors with sqlite and schema comments. OnlyOfffice had column comments in the past (https://github.com/ONLYOFFICE/onlyoffice-nextcloud/commit/da5343fb24ed463ddab1287a88b9637dd65708f0).
The generated query here looks weird ;)
CREATE TABLE oc_onlyoffice_filekey (id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, file_id BIGINT DEFAULT -1 --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier --internal file identifier, \"key\" VARCHAR(128) NOT NULL COLLATE BINARY, lock INTEGER DEFAULT 0 NOT NULL, fs INTEGER DEFAULT 0 NOT NULL)
@NeroNekro
Mind to edit https://github.com/nextcloud/server/blob/stable25/lib/private/DB/SQLiteMigrator.php on your local installation (e.g., with a ftp client)
Change the function like below
protected function getDiff(Schema $targetSchema, \Doctrine\DBAL\Connection $connection) {
$platform = $connection->getDatabasePlatform();
$platform->registerDoctrineTypeMapping('tinyint unsigned', 'integer');
$platform->registerDoctrineTypeMapping('smallint unsigned', 'integer');
$platform->registerDoctrineTypeMapping('varchar ', 'string');
foreach ($targetSchema->getTables() as $table) {
$table->setComment(null);
foreach ($table->getColumns() as $column) {
// column comments are not supported on SQLite
$column->setComment(null);
// with sqlite autoincrement columns is of type integer
if ($column->getType() instanceof BigIntType && $column->getAutoincrement()) {
$column->setType(Type::getType('integer'));
}
}
}
return parent::getDiff($targetSchema, $connection);
}
Try the upgrade again?
I´m having the exact same issue on the exact same hoster (netcup!) - I try to update from 24.0.12. to 25.0.12.
I also tried to edit SQLiteMigrator.php with the upper code. It ended in the exact same error.
Anyone has a solution on this ?
`Exception: Database error when running migration 25000Date20220602190540 for app core An exception occurred while executing a query: SQLSTATE[HY000]: General error: 1 incomplete input
Detaillierte Protokollmeldungen Update vorbereiten
Log-Level auf "debug" gesetzt
Wartungsmodus eingeschaltet
Reparaturschritt: Repair MySQL collation
Reparaturinformation: Not a mysql database -> nothing to do
Reparaturschritt: Repair SQLite autoincrement
Reparaturschritt: Copy data from accounts table when migrating from ownCloud
Reparaturschritt: Drop account terms table when migrating from ownCloud
Das Datenbankschema wird aktualisiert
Exception: Database error when running migration 25000Date20220602190540 for app core An exception occurred while executing a query: SQLSTATE[HY000]: General error: 1 incomplete input`
@NeroNekro could you solve your problem ? If yes, could you please let me know. It seems it somehow belongs to netcup, or ?
I solved the problem with switching to MySQL xD
Thanks
@NeroNekro Could you give me some hint how I can manage this ? Is there a Solution / Doc to do this on the fly ? Is it safe to change DB / CONFIG before leaving maintenence mode ?
@EkkiBrue Yes, there's an entire chapter of the manual dedicated to the topic: https://docs.nextcloud.com/server/latest/admin_manual/configuration_database/db_conversion.html
⚠️ This issue respects the following points: ⚠️
Bug description
Update vorbereiten
Log-Level auf "debug" gesetzt
Reparaturschritt: Repair MySQL collation
Reparaturinformation: Not a mysql database -> nothing to do
Reparaturschritt: Repair SQLite autoincrement
Reparaturschritt: Copy data from accounts table when migrating from ownCloud
Reparaturschritt: Drop account terms table when migrating from ownCloud
Das Datenbankschema wird aktualisiert
Exception: Database error when running migration 27000Date20220613163520 for app core An exception occurred while executing a query: SQLSTATE[HY000]: General error: 1 incomplete input
Steps to reproduce
1.Upload 25.0.8 Files to Host
Expected behavior
No error
Installation method
Archive
Nextcloud Server version
25
Operating system
None
PHP engine version
8.0
Web server
None
Database engine version
SQLite
Is this bug present after an update or on a fresh install?
Update
Are you using the Nextcloud Server Encryption module?
No
What user-backends are you using?
Configuration report
No response
List of activated Apps
No response
Nextcloud Signing status
Nextcloud Logs
Additional info
No response