Table is read only

I’ve had what appears to be a hardware crash and its broken my nextcloud install with access to the NC webpage reporting Internal Server Error.
the nextcloud.log is reporting:

…An exception occurred while executing a query: SQLSTATE[HY000]: General error: 1036 Table ‘oc_preferences’ is read only…

occ maintenance:repair has been ran but no fix, also mysqlcheck has been ran on the db without any issues reported. other DB’s on the sql server appear to be ok.

I am running this in docker but dont beleive this has a bearing on a fix.
is there a way out of this by making the table RW or am i destined to revert to my non-existent backups and start on a fresh DB?

I just faced the same issue. Has anyone found a solution?

i’m not sure on the ins and outs but i also found out there were also some issues with the lastest mariadb & nextcloud versions.

since i used docker i used the broken state as an opportune time to upgrade the container images so i was likely facing issues there too.
i’m currently running the previous versions of both mariadb and nextcloud; rather than ‘:latest’, i’m using mariadb:10.5 and nextcloud:21.0.

i did get into a mess while trying to figure things out so ended up with a fresh db so not sure if downgrading to 21 on possibly 22 upgraded data is possible, but at least i’m back online.
I’m using it for home personal use so only me affected and not a big problem clean-slating it.

Just reverted from mariadb 10.6.3 to 10.5.11 on manjaro linux. After the mariadb service was restarted, nextcloud was back online.

Update here, somebody found a way to fix this while still using the latest (as of now) version of mariadb:

Just add innodb_read_only_compressed=0 to mariadb settings, either through custom config file or as a flag when starting mysqld. If you run mariadb in docker, see here how to do it.