2
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

個人開発 Habitica-外部連携 運用設計 バックアップ・リストア設計

Last updated at Posted at 2025-04-06

バックアップ・リストア設計の目的

システムのデータの損失や破損を防止し、障害発生時にデータを復旧することを目的とする。

インプットとなる資料

概念設計
https://qiita.com/RYA234/items/675442e8a2acc17c0f3e

成果物 バックアップ方針

具体的な製品に依存しないバックアップの方針を決めます

バックアップ対象 

# バックアップ種別 配置場所 バックアップデータ 種別 容量 備考
1 データ DBサーバー DBデータ DB 5GB 特になし

バックアップ間隔

# バックアップ種別 バックアップ間隔 バックアップ完了想定時刻 容量
1 データ 週次 5分 5GB

バックアップ先

# 配置場所 バックアップサーバディスク テープ 遠隔地
1 データ

リストア可能範囲

# バックアップ種別 範囲 リストア想定時間
1 データ 障害直前 5分

詳細設計部分

バックアップコマンド

# bashで実行する

docker-compose exec -it  postgre_task  bash -c  "pg_dump -Fc  postgres > /src/backup/`date +%Y%m%d`.dump"

リストアコマンド

# bashで実行する
docker-compose exec -it  postgre_task  bash -c "pg_restore -d postgres -Fc /src/backup/20250406.dump"

スケジュールコマンド

本項目ではまだ記述しません。

参考書籍:

・設計運用の教科書 4.4バックアップ/リストア
・システム設計の謎を解く 5.3設計の側面 3.2バックアップ/リストア p225
・内部構造から学ぶPostgreSQL 設計・運用計画の鉄則 第八章バックアップ計画

2
2
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
2
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?