ownCloudのバージョンアップに失敗した場合の対処方法

提供: Wikiducca
2019年1月1日 (火) 13:07時点におけるThe Pioneer (ノート | 投稿記録)による版

移動: 案内検索

Wikiduccaは終了しました。今後はゴールドペディアをご利用ください。ownCloud を最新版 (8.0.3) にアップデートしようとした際、途中でエラーになってしまった。 == エラーの内容 == <pre> An exception occurred while executing 'INSERT INTO `oc_oc_appconfig_abcde1234fghi` SELECT * FROM `oc_appconfig`': SQLSTATE[HY000]: General error: 1665 Cannot execute statement: impossible to write to binary log since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-based logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED. </pre> == 対策 == === MySQL の 'binlog_format' を変更する === 'MIXED' にすれば良いらしい。 ==== 現在の設定を確認 ==== <pre> mysql> SHOW GLOBAL VARIABLES LIKE 'binlog_format'; +---------------+-----------+ | Variable_name | Value | +---------------+-----------+ | binlog_format | STATEMENT | +---------------+-----------+ 1 row in set (0.00 sec) </pre> ==== 'MIXED' に変更 ==== <pre> mysql> SET GLOBAL binlog_format = 'MIXED'; Query OK, 0 rows affected (0.00 sec) mysql> SHOW GLOBAL VARIABLES LIKE 'binlog_format'; +---------------+-------+ | Variable_name | Value | +---------------+-------+ | binlog_format | MIXED | +---------------+-------+ 1 row in set (0.00 sec) mysql> mysql> quit Bye </pre> 以上でエラーが出なくなり、アップデートに成功した。 ===== /etc/my.cnf も修正===== なければ追記。 <pre> binlog_format = MIXED </pre> これで再起動後も反映される。 == 参考 == https://github.com/owncloud/core/issues/16131 [[Category:ownCloud]]