0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

MariaDBのバイナリーログ基礎知識(出力場所や保存期間など)

Last updated at Posted at 2023-12-28

前提

Windows10にインストールしたMariaDBに対する情報となります。

バイナリーログとはなんぞや

主に下記で使われることが多いログです。

  • レプリケーション。
  • 世代バックアップからのロールフォワード。

CREATEやUPDATEなどのデータベースに変更が加わる全てのイベント(SQL)が記録されています。

公式サイト

my.ini

  • バイナリーログを出力するかどうか。
  • バイナリーログのファイル名。
  • バイナリーログの保存期間。

上記のような設定をしたい時はmy.iniに書きます。

my.iniがある場所
C:\Program Files\MariaDB 10.5\data

出力設定

まず前提としてバイナリーログは 出力しないがデフォルト になっています。

my.iniに 設定を書いて初めて出力 され始めます。

そして、例えば設定が下記なら…
image.png

こう出ます。
image.png

ログ保存期間

まず前提として ログ保存期間を設定しないとバイナリーログが溜まり続けます

例えば設定が下記なら 3日間はバイナリーログを保存 になります。
image.png

バージョン

Microsoft Windows [Version 10.0.19045.3803]
MariaDB 10.5.4

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?