nextcloud.yml
...
services:
  db:
    image: mariadb:10.10.2
...


docker-compose -f nextcloud.yml ps
docker-compose -f nextcloud.yml down ;
docker-compose -f nextcloud.yml up -d --build --force-recreate;
docker-compose -f nextcloud.yml ps
docker-compose -f nextcloud.yml logs --follow

Got errors

db_1   | 2022-11-20  1:19:04 38 [ERROR] Incorrect definition of table mysql.column_stats: expected column 'hist_type' at position 9 to have type enum('SINGLE_PREC_HB','DOUBLE_PREC_HB','JSON_HB'), found type enum('SINGLE_PREC_HB','DOUBLE_PREC_HB').
db_1   | 2022-11-20  1:19:04 38 [ERROR] Incorrect definition of table mysql.column_stats: expected column 'histogram' at position 10 to have type longblob, found type varbinary(255).
db_1   | 2022-11-20  1:19:04 38 [ERROR] Incorrect definition of table mysql.column_stats: expected column 'hist_type' at position 9 to have type enum('SINGLE_PREC_HB','DOUBLE_PREC_HB','JSON_HB'), found type enum('SINGLE_PREC_HB','DOUBLE_PREC_HB').
db_1   | 2022-11-20  1:19:04 38 [ERROR] Incorrect definition of table mysql.column_stats: expected column 'histogram' at position 10 to have type longblob, found type varbinary(255).
docker exec -it root_db_1 bash
mysql_upgrade --user=root --password=dbpassword
Phase 1/7: Checking and upgrading mysql database
Processing databases
mysql
mysql.column_stats                                 OK
...
mysql.transaction_registry                         OK

Phase 2/7: Installing used storage engines... Skipped

Phase 3/7: Fixing views

mysql.user                                         OK
sys.host_summary                                   OK
...
sys.x$waits_global_by_latency                      OK

Phase 4/7: Running 'mysql_fix_privilege_tables'

Phase 5/7: Fixing table and database names

Phase 6/7: Checking and upgrading tables

Processing databases
information_schema
nextcloud
nextcloud.oc_accounts                              OK
...
nextcloud.oc_whats_new                             OK
performance_schema
sys
sys.sys_config                                     OK

Phase 7/7: Running 'FLUSH PRIVILEGES'

OK


  • No labels