Problem upgrading from 8.4.4 to 9.4


Attempted an update from 8.4.4 to 9.4 (xwiki repo on Ubuntu 16.04, everything else on the VM is up to date)

looking at the “root causes” I presume that the problem is related to

Migration of database [xwiki] has failed, it could not be safely used! Database is currently in version [73000] while the required version is [93000].

Unable to update schema of wiki [xwiki]

Failed updating schema while executing query [alter table activitystream_events_status add index FKBF7104E8CB8C5002 (ases_eventid), add constraint FKBF7104E8CB8C5002 foreign key (ases_eventid) references activitystream_events (ase_eventid)]

Can’t create table ‘xwiki.#sql-441_b72’ (errno: 150)

The xwiki user has “all” permissions. I’m a little lost as what I’ve done “wrong”.




Make sure that for some reason your MySQL database did not ended up with the wrong filesystem righs. See in /var/lib/mysql and make sure everything is owned by “mysql” user.

I think this can happen when you restore/import a database with root user instead of mysql one.



xwiki is running on a dedicated VM (Ubuntu 16.04)
MySQL is running on a different dedicated VM (Ubuntu 14.04 mysql Ver 14.14 Distrib 5.5.57, for debian-linux-gnu (x86_64) using readline 6.3)
all files under /var/lib/MySQL are owned by the MySQL user

xwiki has been through several upgrades since the database was moved to this server



OK then from what I see in Google another idea would be some tables (or all) using the wrong engine (MyISAM instead of InnoDB). See

If that’s your issue you might want to also make sure the tables using the right encoding and collation. See



other things took priority…

I have run the UTF8 and INNODB scrips, and still have what appears to be the same issue

I’m still rather lost as to what I’ve done wrong.

If I connect to the MySQL host from the xwiki host using the xwiki credentials, I can use the xwiki database and add and drop tables, are there any other tests I could run from the command line to help narrow down the issue ?



I’m wondering if If doing a .xar export and import would be a simpler solution ?

As the export is from 8.4.4, could I go direct to 10.4 and then do the import ?



Hi shouldbeq931

We have the same problem with our xwiki migration process. Did you find some cause or solution?