#author("2026-07-03T08:17:52+00:00","","") #author("2026-07-03T08:24:12+00:00","","") *** MySQL 設定 [#s797ab20] - dbtypedbtype: mysql - mysql: -- host: 127.0.0.1 -- port: 3306 -- user: epgstation -- password: 'iQTqf/mDpx+EI6Foi996McrE/AzuIpte' -- database: epgstation -- charset: utf8mb4 - MySQL バージョンは 8.0.46 です。 *** codex 作業サマリ [#o5cd0c16] MySQL への移行作業は完了しました。 実施内容: - EPGStation を PM2 で停止 - 孤立していた旧 ServiceExecutor / EPGUpdateExecutor も停止 - SQLite から JSON バックアップ作成 - config/mysql-migration-backup-20260703-170344.json - MySQL Server 8.0.46 をインストール - epgstation DB と専用 MySQL ユーザーを作成 - config/config.yml を dbtype: mysql に変更 - MySQL へ restore 実行 - PM2 で EPGStation を再起動 - pm2 save 実行済み 退避ファイル: - config/config.yml.before-mysql-20260703-170344 - 既存 SQLite DB は削除していません 確認結果: - PM2: epgstation は online - MySQL 復元件数: - rule: 72 - reserve: 107 - recorded: 188 - thumbnail: 188 - video_file: 188 - recorded_history: 789 - 起動後に MySQL 側へ EPG データも入り始めています: - channel: 48 - program: 5593 pm2 の error log に見えた SQLITE_BUSY は移行前の古いログで、ファイル更新時刻は 15:48 のままでした。現時点の起動後ログでは予約更新も完了しています。 *** 作業コスト [#r7d4f354] - Token usage: total=547,846 input=526,784 (+ 7,957,376 cached) output=21,062 (reasoning 2,551) - To continue this session, run codex resume 019f26ea-d3ef-74a1-98d4-1ce4b3326bc3 *** 更新後の config.yml [#x26bb5c6] - &ref(config.yml); [KGB2] munakata:~/git/EPGStation$ diff config/config.yml config/config.yml.before-mysql-20260703-170344 12,14c12,14 < dbtype: mysql < #dboption: < # busyTimeout: 5000 # SQLite only --- > dbtype: sqlite > dboption: > busyTimeout: 5000 # ← 5秒間ロック解除を待ってリトライ 20,26c20,27 < mysql: < host: 127.0.0.1 < port: 3306 < user: epgstation < password: 'iQTqf/mDpx+EI6Foi996McrE/AzuIpte' < database: epgstation < charset: utf8mb4 --- > # dbtype: mysql > # mysql: > # host: 192.168.xx.xx > # port: 3306 > # user: epgstation > # password: epgstation > # database: epgstation > # charset: utf8mb4