SlideShare a Scribd company logo
1 of 19
Download to read offline
© 2015 EnterpriseDB Corporation. All rights reserved. 1
How to get your data back in Postgres – Point-in-Time
Recovery (PITR) explained
For more information on Postgres PITR please email sales@enterprisedb.com or visit www.enterprisedb.com
© 2015 EnterpriseDB Corporation. All rights reserved. 2
Agenda
•  Introduction
•  Business Impact vs Cost
•  Downtime Scenarios
•  Backup Methods
•  Point-In-Time Recovery
•  Summary
© 2015 EnterpriseDB Corporation. All rights reserved. 3
•  Disaster recovery strategies are key to the reliable operation of any
business-critical environment.
•  Backup and recovery plans must consider various failure scenarios and
compliance requirements, including device failure, operator error, and data
corruption.
Introduction
© 2015 EnterpriseDB Corporation. All rights reserved. 4
Business Impact vs Cost
•  How long will recovery take?
•  How long do we need to store backup data?
•  How much will data storage cost?
•  Will an outage effect our brand?
•  Can any part of the database remain operational whilst
I recover elsewhere?
•  Do I know when the problem I am recovering from
started?
© 2015 EnterpriseDB Corporation. All rights reserved. 5
Downtime Scenarios
© 2015 EnterpriseDB Corporation. All rights reserved. 6
•  As with any database, a Postgres database should be backed up regularly.
•  There are three fundamentally different approaches to backing up
Postgres data:
−  SQL dump
−  File system level backup
−  Continuous archiving
Backup Methods
© 2015 EnterpriseDB Corporation. All rights reserved. 7
•  Generate a text file with SQL commands
•  Postgres provides the utility program pg_dump for this purpose.
•  pg_dump does not block readers nor writers.
•  Dumps created by pg_dump are internally consistent, that is, the dump
represents a snapshot of the database as of the time pg_dump begins
running.
•  Syntax:
pg_dump [options] [dbname]
Backup – SQL Dump
© 2015 EnterpriseDB Corporation. All rights reserved. 8
Backup – Entire Cluster – SQL Dump
•  pg_dumpall is used to dump an entire database cluster in plain-text SQL
format
•  pg_dumpall dumps global objects: users, groups, and associated
permissions
•  Use PSQL to restore
•  Syntax:
pg_dumpall [options] > filename.backup
© 2015 EnterpriseDB Corporation. All rights reserved. 9
•  Copy Postgres files from the file system.
•  You can use whatever method you prefer for doing usual file system
backups, for example:
tar -cvf backup.tar /usr/local/pgsql/data
•  The database server must be shut down in order to get a usable backup.
•  File system backups only work for complete backups and recovery of an
entire database cluster.
Backup – Cold Backup
© 2015 EnterpriseDB Corporation. All rights reserved. 10
•  Database can stay operational during backup.
•  Postgres maintains WAL logs for all transactions in the pg_xlog directory.
•  When full, Postgres automatically switches WAL logs.
•  Continuous archiving can be setup to keep a copy of switched WAL logs
which can later be used for recovery.
•  Enables online file system backup of a database cluster.
•  Requirements:
wal_level = archive

archive_mode = on

archive_command = …
Backup – Hot Backup
© 2015 EnterpriseDB Corporation. All rights reserved. 11
1.  Connect using psql and issue SELECT pg_start_backup(‘any
useful label’);
2.  Use a standard file system backup utility to back up the data directory.
3.  Connect using psql and issue SELECT pg_stop_backup();
4.  Ensure to continuously archive WAL logs.
Online Base Backup
© 2015 EnterpriseDB Corporation. All rights reserved. 12
•  pg_basebackup takes a base backup of a Postgres cluster.
•  Backup can be used to setup a standby with streaming replication and a
Point-In-Time Recovery (PITR).
•  pg_basebackup takes a binary copy of the database cluster files.
•  pg_basebackup puts the database in and out of backup mode.
Online Base Backup using pg_basebackup
© 2015 EnterpriseDB Corporation. All rights reserved. 13
•  Point-in-time recovery (PITR) is the ability to restore a database cluster up
to the present or to a specified point of time in the past.
•  Uses a full database cluster backup and applies the WAL logs.
•  Must be configured before it is needed. WAL log archiving must be
enabled.
•  Must have information of when you want to recover to.
Point-in-Time Recovery
© 2015 EnterpriseDB Corporation. All rights reserved. 14
Point-in-Time Recovery Demo
© 2015 EnterpriseDB Corporation. All rights reserved. 15
•  pause_at_recovery_target = true
•  hot_standby = on (if using pause_at_recovery_target)
•  SELECT pg_is_xlog_replay_paused();
•  SELECT pg_xlog_replay_resume();
•  SELECT pg_catalog.pg_current_xlog_location();
•  SELECT pg_xlogfile_name(’output from above command');
•  SELECT pg_create_restore_point('webinar_restore');
Point-In-Time Recovery Help
© 2015 EnterpriseDB Corporation. All rights reserved. 16
Summary
•  Introduction
•  Business Impact vs Cost
•  Backup and Recovery Methods
−  SQL Dump
−  Cold Backup (offline Backup)
−  Hot Backup (online Backup)
−  Continuous Archiving
•  Point-In Time Recovery
•  Demo
© 2015 EnterpriseDB Corporation. All rights reserved. 17
•  EDB Postgres Advanced Server 9.5 Download
http://www.enterprisedb.com/downloads/postgres-postgresql-downloads
•  Continuous Archiving and Point-in-Time Recovery (PITR)
http://www.postgresql.org/docs/current/static/continuous-archiving.html
•  pg_dump
http://www.postgresql.org/docs/9.5/static/app-pgdump.html
•  pg_dumpall
http://www.postgresql.org/docs/current/static/app-pg-dumpall.html
•  pg_basebackup
http://www.postgresql.org/docs/current/static/app-pgbasebackup.html
Contact sales@enterprisedb.com for more information on Postgres PITR
Resources
© 2015 EnterpriseDB Corporation. All rights reserved. 18
•  Take advantage of the most convenient training that best fits your learning style and get
Postgres certified!
−  EDB offers Classroom & on-site training globally
−  Live virtual training courses can be taken from any location and maintains live communication
with the instructor to guide you and answer questions quickly.
•  EDB’s eSubscriptions
−  This annual subscription provides access to the entire EDB library of on-demand training
courses for convenient access and training any time.
•  Postgres Training Credits (PTC)
−  Training credits provide the flexibility to pre-purchase blocks of training credits that can be spent
on any combination of our training delivery methods. It is a convenient way to receive training
with a built-in price discount.
•  Earn an Associate-level or Professional-level Postgres Certification
To learn more about EDB’s training schedule, Certification, eSubscriptions and Training Credits email
training@enterprisedb.com
Sharpen your skills with Training and Certification
© 2015 EnterpriseDB Corporation. All rights reserved. 19

More Related Content

What's hot

Business Continuity Considerations for a More Reliable Postgres Environment
Business Continuity Considerations for a More Reliable Postgres EnvironmentBusiness Continuity Considerations for a More Reliable Postgres Environment
Business Continuity Considerations for a More Reliable Postgres EnvironmentEDB
 
Optimizing Your Postgres ROI Through Best Practices
Optimizing Your Postgres ROI Through Best PracticesOptimizing Your Postgres ROI Through Best Practices
Optimizing Your Postgres ROI Through Best PracticesEDB
 
5 Tips to Simplify the Management of Your Postgres Database
5 Tips to Simplify the Management of Your Postgres Database5 Tips to Simplify the Management of Your Postgres Database
5 Tips to Simplify the Management of Your Postgres DatabaseEDB
 
Top 10 Tips for an Effective Postgres Deployment
Top 10 Tips for an Effective Postgres DeploymentTop 10 Tips for an Effective Postgres Deployment
Top 10 Tips for an Effective Postgres DeploymentEDB
 
Making the Most of Your Postgres Rollout
Making the Most of Your Postgres RolloutMaking the Most of Your Postgres Rollout
Making the Most of Your Postgres RolloutEDB
 
DevOps Culture & Enablement with Postgres Plus Cloud Database
DevOps Culture & Enablement with Postgres Plus Cloud DatabaseDevOps Culture & Enablement with Postgres Plus Cloud Database
DevOps Culture & Enablement with Postgres Plus Cloud DatabaseEDB
 
Key Methodologies for Migrating from Oracle to Postgres
Key Methodologies for Migrating from Oracle to PostgresKey Methodologies for Migrating from Oracle to Postgres
Key Methodologies for Migrating from Oracle to PostgresEDB
 
Which Postgres is Right for You? Part 3
Which Postgres is Right for You? Part 3Which Postgres is Right for You? Part 3
Which Postgres is Right for You? Part 3EDB
 
EnterpriseDB BackUp and Recovery Tool
EnterpriseDB BackUp and Recovery ToolEnterpriseDB BackUp and Recovery Tool
EnterpriseDB BackUp and Recovery ToolEDB
 
EDB Postgres with Containers
EDB Postgres with ContainersEDB Postgres with Containers
EDB Postgres with ContainersEDB
 
Reducing the Risks of Migrating Off Oracle
Reducing the Risks of Migrating Off OracleReducing the Risks of Migrating Off Oracle
Reducing the Risks of Migrating Off OracleEDB
 
Migrating from Oracle to Postgres
Migrating from Oracle to PostgresMigrating from Oracle to Postgres
Migrating from Oracle to PostgresEDB
 
Best Practices & Lessons Learned from Deployment of PostgreSQL
 Best Practices & Lessons Learned from Deployment of PostgreSQL Best Practices & Lessons Learned from Deployment of PostgreSQL
Best Practices & Lessons Learned from Deployment of PostgreSQLEDB
 
DBaaS with EDB Postgres on AWS
DBaaS with EDB Postgres on AWSDBaaS with EDB Postgres on AWS
DBaaS with EDB Postgres on AWSEDB
 
Database Dumps and Backups
Database Dumps and BackupsDatabase Dumps and Backups
Database Dumps and BackupsEDB
 
Migrations, Health Checks, and Support Experiences - Postgres from the Servic...
Migrations, Health Checks, and Support Experiences - Postgres from the Servic...Migrations, Health Checks, and Support Experiences - Postgres from the Servic...
Migrations, Health Checks, and Support Experiences - Postgres from the Servic...EDB
 
A Peek in the Elephant's Trunk
A Peek in the Elephant's TrunkA Peek in the Elephant's Trunk
A Peek in the Elephant's TrunkEDB
 
Optimize with Open Source
Optimize with Open SourceOptimize with Open Source
Optimize with Open SourceEDB
 
Ashnik EnterpriseDB PostgreSQL - A real alternative to Oracle
Ashnik EnterpriseDB PostgreSQL - A real alternative to Oracle Ashnik EnterpriseDB PostgreSQL - A real alternative to Oracle
Ashnik EnterpriseDB PostgreSQL - A real alternative to Oracle Ashnikbiz
 
The Real Scoop on Migrating from Oracle Databases
The Real Scoop on Migrating from Oracle DatabasesThe Real Scoop on Migrating from Oracle Databases
The Real Scoop on Migrating from Oracle DatabasesEDB
 

What's hot (20)

Business Continuity Considerations for a More Reliable Postgres Environment
Business Continuity Considerations for a More Reliable Postgres EnvironmentBusiness Continuity Considerations for a More Reliable Postgres Environment
Business Continuity Considerations for a More Reliable Postgres Environment
 
Optimizing Your Postgres ROI Through Best Practices
Optimizing Your Postgres ROI Through Best PracticesOptimizing Your Postgres ROI Through Best Practices
Optimizing Your Postgres ROI Through Best Practices
 
5 Tips to Simplify the Management of Your Postgres Database
5 Tips to Simplify the Management of Your Postgres Database5 Tips to Simplify the Management of Your Postgres Database
5 Tips to Simplify the Management of Your Postgres Database
 
Top 10 Tips for an Effective Postgres Deployment
Top 10 Tips for an Effective Postgres DeploymentTop 10 Tips for an Effective Postgres Deployment
Top 10 Tips for an Effective Postgres Deployment
 
Making the Most of Your Postgres Rollout
Making the Most of Your Postgres RolloutMaking the Most of Your Postgres Rollout
Making the Most of Your Postgres Rollout
 
DevOps Culture & Enablement with Postgres Plus Cloud Database
DevOps Culture & Enablement with Postgres Plus Cloud DatabaseDevOps Culture & Enablement with Postgres Plus Cloud Database
DevOps Culture & Enablement with Postgres Plus Cloud Database
 
Key Methodologies for Migrating from Oracle to Postgres
Key Methodologies for Migrating from Oracle to PostgresKey Methodologies for Migrating from Oracle to Postgres
Key Methodologies for Migrating from Oracle to Postgres
 
Which Postgres is Right for You? Part 3
Which Postgres is Right for You? Part 3Which Postgres is Right for You? Part 3
Which Postgres is Right for You? Part 3
 
EnterpriseDB BackUp and Recovery Tool
EnterpriseDB BackUp and Recovery ToolEnterpriseDB BackUp and Recovery Tool
EnterpriseDB BackUp and Recovery Tool
 
EDB Postgres with Containers
EDB Postgres with ContainersEDB Postgres with Containers
EDB Postgres with Containers
 
Reducing the Risks of Migrating Off Oracle
Reducing the Risks of Migrating Off OracleReducing the Risks of Migrating Off Oracle
Reducing the Risks of Migrating Off Oracle
 
Migrating from Oracle to Postgres
Migrating from Oracle to PostgresMigrating from Oracle to Postgres
Migrating from Oracle to Postgres
 
Best Practices & Lessons Learned from Deployment of PostgreSQL
 Best Practices & Lessons Learned from Deployment of PostgreSQL Best Practices & Lessons Learned from Deployment of PostgreSQL
Best Practices & Lessons Learned from Deployment of PostgreSQL
 
DBaaS with EDB Postgres on AWS
DBaaS with EDB Postgres on AWSDBaaS with EDB Postgres on AWS
DBaaS with EDB Postgres on AWS
 
Database Dumps and Backups
Database Dumps and BackupsDatabase Dumps and Backups
Database Dumps and Backups
 
Migrations, Health Checks, and Support Experiences - Postgres from the Servic...
Migrations, Health Checks, and Support Experiences - Postgres from the Servic...Migrations, Health Checks, and Support Experiences - Postgres from the Servic...
Migrations, Health Checks, and Support Experiences - Postgres from the Servic...
 
A Peek in the Elephant's Trunk
A Peek in the Elephant's TrunkA Peek in the Elephant's Trunk
A Peek in the Elephant's Trunk
 
Optimize with Open Source
Optimize with Open SourceOptimize with Open Source
Optimize with Open Source
 
Ashnik EnterpriseDB PostgreSQL - A real alternative to Oracle
Ashnik EnterpriseDB PostgreSQL - A real alternative to Oracle Ashnik EnterpriseDB PostgreSQL - A real alternative to Oracle
Ashnik EnterpriseDB PostgreSQL - A real alternative to Oracle
 
The Real Scoop on Migrating from Oracle Databases
The Real Scoop on Migrating from Oracle DatabasesThe Real Scoop on Migrating from Oracle Databases
The Real Scoop on Migrating from Oracle Databases
 

Viewers also liked

Product Update: EDB Postgres Platform 2017
Product Update: EDB Postgres Platform 2017Product Update: EDB Postgres Platform 2017
Product Update: EDB Postgres Platform 2017EDB
 
5 Postgres DBA Tips
5 Postgres DBA Tips5 Postgres DBA Tips
5 Postgres DBA TipsEDB
 
Introducing EDB Failover Manager
Introducing EDB Failover ManagerIntroducing EDB Failover Manager
Introducing EDB Failover ManagerEDB
 
Non-Relational Postgres
Non-Relational PostgresNon-Relational Postgres
Non-Relational PostgresEDB
 
EDB Postgres DBA Best Practices
EDB Postgres DBA Best PracticesEDB Postgres DBA Best Practices
EDB Postgres DBA Best PracticesEDB
 
What's New in PostgreSQL 9.6
What's New in PostgreSQL 9.6What's New in PostgreSQL 9.6
What's New in PostgreSQL 9.6EDB
 
Postgres Enterprise Manager 4.0 Overview
Postgres Enterprise Manager 4.0 Overview Postgres Enterprise Manager 4.0 Overview
Postgres Enterprise Manager 4.0 Overview EDB
 
Introducing Postgres Enterprise Manager 5.0
Introducing Postgres Enterprise Manager 5.0Introducing Postgres Enterprise Manager 5.0
Introducing Postgres Enterprise Manager 5.0EDB
 
Optimizing Open Source for Greater Database Savings & Control
Optimizing Open Source for Greater Database Savings & ControlOptimizing Open Source for Greater Database Savings & Control
Optimizing Open Source for Greater Database Savings & ControlEDB
 
Postgres Integrates Effectively in the "Enterprise Sandbox"
Postgres Integrates Effectively in the "Enterprise Sandbox"Postgres Integrates Effectively in the "Enterprise Sandbox"
Postgres Integrates Effectively in the "Enterprise Sandbox"EDB
 
Drive DBMS Transformation with EDB Postgres
Drive DBMS Transformation with EDB PostgresDrive DBMS Transformation with EDB Postgres
Drive DBMS Transformation with EDB PostgresEDB
 
Useful PostgreSQL Extensions
Useful PostgreSQL ExtensionsUseful PostgreSQL Extensions
Useful PostgreSQL ExtensionsEDB
 
Architecture for building scalable and highly available Postgres Cluster
Architecture for building scalable and highly available Postgres ClusterArchitecture for building scalable and highly available Postgres Cluster
Architecture for building scalable and highly available Postgres ClusterAshnikbiz
 
Seven Key Elements of a Successful Encryption Strategy
Seven Key Elements of a Successful Encryption StrategySeven Key Elements of a Successful Encryption Strategy
Seven Key Elements of a Successful Encryption StrategySirius
 

Viewers also liked (14)

Product Update: EDB Postgres Platform 2017
Product Update: EDB Postgres Platform 2017Product Update: EDB Postgres Platform 2017
Product Update: EDB Postgres Platform 2017
 
5 Postgres DBA Tips
5 Postgres DBA Tips5 Postgres DBA Tips
5 Postgres DBA Tips
 
Introducing EDB Failover Manager
Introducing EDB Failover ManagerIntroducing EDB Failover Manager
Introducing EDB Failover Manager
 
Non-Relational Postgres
Non-Relational PostgresNon-Relational Postgres
Non-Relational Postgres
 
EDB Postgres DBA Best Practices
EDB Postgres DBA Best PracticesEDB Postgres DBA Best Practices
EDB Postgres DBA Best Practices
 
What's New in PostgreSQL 9.6
What's New in PostgreSQL 9.6What's New in PostgreSQL 9.6
What's New in PostgreSQL 9.6
 
Postgres Enterprise Manager 4.0 Overview
Postgres Enterprise Manager 4.0 Overview Postgres Enterprise Manager 4.0 Overview
Postgres Enterprise Manager 4.0 Overview
 
Introducing Postgres Enterprise Manager 5.0
Introducing Postgres Enterprise Manager 5.0Introducing Postgres Enterprise Manager 5.0
Introducing Postgres Enterprise Manager 5.0
 
Optimizing Open Source for Greater Database Savings & Control
Optimizing Open Source for Greater Database Savings & ControlOptimizing Open Source for Greater Database Savings & Control
Optimizing Open Source for Greater Database Savings & Control
 
Postgres Integrates Effectively in the "Enterprise Sandbox"
Postgres Integrates Effectively in the "Enterprise Sandbox"Postgres Integrates Effectively in the "Enterprise Sandbox"
Postgres Integrates Effectively in the "Enterprise Sandbox"
 
Drive DBMS Transformation with EDB Postgres
Drive DBMS Transformation with EDB PostgresDrive DBMS Transformation with EDB Postgres
Drive DBMS Transformation with EDB Postgres
 
Useful PostgreSQL Extensions
Useful PostgreSQL ExtensionsUseful PostgreSQL Extensions
Useful PostgreSQL Extensions
 
Architecture for building scalable and highly available Postgres Cluster
Architecture for building scalable and highly available Postgres ClusterArchitecture for building scalable and highly available Postgres Cluster
Architecture for building scalable and highly available Postgres Cluster
 
Seven Key Elements of a Successful Encryption Strategy
Seven Key Elements of a Successful Encryption StrategySeven Key Elements of a Successful Encryption Strategy
Seven Key Elements of a Successful Encryption Strategy
 

Similar to Postgres Point-in-Time Recovery

9.6_Course Material-Postgresql_002.pdf
9.6_Course Material-Postgresql_002.pdf9.6_Course Material-Postgresql_002.pdf
9.6_Course Material-Postgresql_002.pdfsreedb2
 
[db tech showcase Tokyo 2016] E34: Oracle SE - RAC, HA and Standby are Still ...
[db tech showcase Tokyo 2016] E34: Oracle SE - RAC, HA and Standby are Still ...[db tech showcase Tokyo 2016] E34: Oracle SE - RAC, HA and Standby are Still ...
[db tech showcase Tokyo 2016] E34: Oracle SE - RAC, HA and Standby are Still ...Insight Technology, Inc.
 
Why oracle data guard new features in oracle 18c, 19c
Why oracle data guard new features in oracle 18c, 19cWhy oracle data guard new features in oracle 18c, 19c
Why oracle data guard new features in oracle 18c, 19cSatishbabu Gunukula
 
An overview of reference architectures for Postgres
An overview of reference architectures for PostgresAn overview of reference architectures for Postgres
An overview of reference architectures for PostgresEDB
 
Think_your_Postgres_backups_and_recovery_are_safe_lets_talk.pptx
Think_your_Postgres_backups_and_recovery_are_safe_lets_talk.pptxThink_your_Postgres_backups_and_recovery_are_safe_lets_talk.pptx
Think_your_Postgres_backups_and_recovery_are_safe_lets_talk.pptxPayal Singh
 
Best Practices for Becoming an Exceptional Postgres DBA
Best Practices for Becoming an Exceptional Postgres DBA Best Practices for Becoming an Exceptional Postgres DBA
Best Practices for Becoming an Exceptional Postgres DBA EDB
 
Webinar slides: Backup Management for MySQL, MariaDB, PostgreSQL & MongoDB wi...
Webinar slides: Backup Management for MySQL, MariaDB, PostgreSQL & MongoDB wi...Webinar slides: Backup Management for MySQL, MariaDB, PostgreSQL & MongoDB wi...
Webinar slides: Backup Management for MySQL, MariaDB, PostgreSQL & MongoDB wi...Severalnines
 
Postgres in production.2014
Postgres in production.2014Postgres in production.2014
Postgres in production.2014EDB
 
AUSPC 2013 - Business Continuity Management in SharePoint
AUSPC 2013 - Business Continuity Management in SharePointAUSPC 2013 - Business Continuity Management in SharePoint
AUSPC 2013 - Business Continuity Management in SharePointMichael Noel
 
Primavera p6 and the oracle rdbms - Oracle Primavera Collaborate 14
Primavera p6 and the oracle rdbms - Oracle Primavera Collaborate 14Primavera p6 and the oracle rdbms - Oracle Primavera Collaborate 14
Primavera p6 and the oracle rdbms - Oracle Primavera Collaborate 14p6academy
 
An overview of reference architectures for Postgres
An overview of reference architectures for PostgresAn overview of reference architectures for Postgres
An overview of reference architectures for PostgresEDB
 
The Central View of your Data with Postgres
The Central View of your Data with PostgresThe Central View of your Data with Postgres
The Central View of your Data with PostgresEDB
 
Top10 list planningpostgresdeployment.2014
Top10 list planningpostgresdeployment.2014Top10 list planningpostgresdeployment.2014
Top10 list planningpostgresdeployment.2014EDB
 
The Good, The Bad and the Ugly
The Good, The Bad and the UglyThe Good, The Bad and the Ugly
The Good, The Bad and the UglyRoy Salazar
 
Backups And Recovery
Backups And RecoveryBackups And Recovery
Backups And Recoveryasifmalik110
 
Simplify Consolidation with Oracle Database 12c
Simplify Consolidation with Oracle Database 12cSimplify Consolidation with Oracle Database 12c
Simplify Consolidation with Oracle Database 12cMaris Elsins
 
PGEncryption_Tutorial
PGEncryption_TutorialPGEncryption_Tutorial
PGEncryption_TutorialVibhor Kumar
 
Best Practices for a Complete Postgres Enterprise Architecture Setup
Best Practices for a Complete Postgres Enterprise Architecture SetupBest Practices for a Complete Postgres Enterprise Architecture Setup
Best Practices for a Complete Postgres Enterprise Architecture SetupEDB
 
Rohit_vyas_PGDay_Presentation
Rohit_vyas_PGDay_PresentationRohit_vyas_PGDay_Presentation
Rohit_vyas_PGDay_PresentationRohit vyas
 

Similar to Postgres Point-in-Time Recovery (20)

9.6_Course Material-Postgresql_002.pdf
9.6_Course Material-Postgresql_002.pdf9.6_Course Material-Postgresql_002.pdf
9.6_Course Material-Postgresql_002.pdf
 
[db tech showcase Tokyo 2016] E34: Oracle SE - RAC, HA and Standby are Still ...
[db tech showcase Tokyo 2016] E34: Oracle SE - RAC, HA and Standby are Still ...[db tech showcase Tokyo 2016] E34: Oracle SE - RAC, HA and Standby are Still ...
[db tech showcase Tokyo 2016] E34: Oracle SE - RAC, HA and Standby are Still ...
 
Why oracle data guard new features in oracle 18c, 19c
Why oracle data guard new features in oracle 18c, 19cWhy oracle data guard new features in oracle 18c, 19c
Why oracle data guard new features in oracle 18c, 19c
 
An overview of reference architectures for Postgres
An overview of reference architectures for PostgresAn overview of reference architectures for Postgres
An overview of reference architectures for Postgres
 
Think_your_Postgres_backups_and_recovery_are_safe_lets_talk.pptx
Think_your_Postgres_backups_and_recovery_are_safe_lets_talk.pptxThink_your_Postgres_backups_and_recovery_are_safe_lets_talk.pptx
Think_your_Postgres_backups_and_recovery_are_safe_lets_talk.pptx
 
Best Practices for Becoming an Exceptional Postgres DBA
Best Practices for Becoming an Exceptional Postgres DBA Best Practices for Becoming an Exceptional Postgres DBA
Best Practices for Becoming an Exceptional Postgres DBA
 
Webinar slides: Backup Management for MySQL, MariaDB, PostgreSQL & MongoDB wi...
Webinar slides: Backup Management for MySQL, MariaDB, PostgreSQL & MongoDB wi...Webinar slides: Backup Management for MySQL, MariaDB, PostgreSQL & MongoDB wi...
Webinar slides: Backup Management for MySQL, MariaDB, PostgreSQL & MongoDB wi...
 
Postgres in production.2014
Postgres in production.2014Postgres in production.2014
Postgres in production.2014
 
AUSPC 2013 - Business Continuity Management in SharePoint
AUSPC 2013 - Business Continuity Management in SharePointAUSPC 2013 - Business Continuity Management in SharePoint
AUSPC 2013 - Business Continuity Management in SharePoint
 
Primavera p6 and the oracle rdbms - Oracle Primavera Collaborate 14
Primavera p6 and the oracle rdbms - Oracle Primavera Collaborate 14Primavera p6 and the oracle rdbms - Oracle Primavera Collaborate 14
Primavera p6 and the oracle rdbms - Oracle Primavera Collaborate 14
 
An overview of reference architectures for Postgres
An overview of reference architectures for PostgresAn overview of reference architectures for Postgres
An overview of reference architectures for Postgres
 
The Central View of your Data with Postgres
The Central View of your Data with PostgresThe Central View of your Data with Postgres
The Central View of your Data with Postgres
 
Top10 list planningpostgresdeployment.2014
Top10 list planningpostgresdeployment.2014Top10 list planningpostgresdeployment.2014
Top10 list planningpostgresdeployment.2014
 
The Good, The Bad and the Ugly
The Good, The Bad and the UglyThe Good, The Bad and the Ugly
The Good, The Bad and the Ugly
 
Backups And Recovery
Backups And RecoveryBackups And Recovery
Backups And Recovery
 
Simplify Consolidation with Oracle Database 12c
Simplify Consolidation with Oracle Database 12cSimplify Consolidation with Oracle Database 12c
Simplify Consolidation with Oracle Database 12c
 
PGEncryption_Tutorial
PGEncryption_TutorialPGEncryption_Tutorial
PGEncryption_Tutorial
 
Best Practices for a Complete Postgres Enterprise Architecture Setup
Best Practices for a Complete Postgres Enterprise Architecture SetupBest Practices for a Complete Postgres Enterprise Architecture Setup
Best Practices for a Complete Postgres Enterprise Architecture Setup
 
Rohit_vyas_PGDay_Presentation
Rohit_vyas_PGDay_PresentationRohit_vyas_PGDay_Presentation
Rohit_vyas_PGDay_Presentation
 
Case Studies on PostgreSQL
Case Studies on PostgreSQLCase Studies on PostgreSQL
Case Studies on PostgreSQL
 

More from EDB

Cloud Migration Paths: Kubernetes, IaaS, or DBaaS
Cloud Migration Paths: Kubernetes, IaaS, or DBaaSCloud Migration Paths: Kubernetes, IaaS, or DBaaS
Cloud Migration Paths: Kubernetes, IaaS, or DBaaSEDB
 
Die 10 besten PostgreSQL-Replikationsstrategien für Ihr Unternehmen
Die 10 besten PostgreSQL-Replikationsstrategien für Ihr UnternehmenDie 10 besten PostgreSQL-Replikationsstrategien für Ihr Unternehmen
Die 10 besten PostgreSQL-Replikationsstrategien für Ihr UnternehmenEDB
 
Migre sus bases de datos Oracle a la nube
Migre sus bases de datos Oracle a la nube Migre sus bases de datos Oracle a la nube
Migre sus bases de datos Oracle a la nube EDB
 
EFM Office Hours - APJ - July 29, 2021
EFM Office Hours - APJ - July 29, 2021EFM Office Hours - APJ - July 29, 2021
EFM Office Hours - APJ - July 29, 2021EDB
 
Benchmarking Cloud Native PostgreSQL
Benchmarking Cloud Native PostgreSQLBenchmarking Cloud Native PostgreSQL
Benchmarking Cloud Native PostgreSQLEDB
 
Las Variaciones de la Replicación de PostgreSQL
Las Variaciones de la Replicación de PostgreSQLLas Variaciones de la Replicación de PostgreSQL
Las Variaciones de la Replicación de PostgreSQLEDB
 
NoSQL and Spatial Database Capabilities using PostgreSQL
NoSQL and Spatial Database Capabilities using PostgreSQLNoSQL and Spatial Database Capabilities using PostgreSQL
NoSQL and Spatial Database Capabilities using PostgreSQLEDB
 
Is There Anything PgBouncer Can’t Do?
Is There Anything PgBouncer Can’t Do?Is There Anything PgBouncer Can’t Do?
Is There Anything PgBouncer Can’t Do?EDB
 
Data Analysis with TensorFlow in PostgreSQL
Data Analysis with TensorFlow in PostgreSQLData Analysis with TensorFlow in PostgreSQL
Data Analysis with TensorFlow in PostgreSQLEDB
 
Practical Partitioning in Production with Postgres
Practical Partitioning in Production with PostgresPractical Partitioning in Production with Postgres
Practical Partitioning in Production with PostgresEDB
 
A Deeper Dive into EXPLAIN
A Deeper Dive into EXPLAINA Deeper Dive into EXPLAIN
A Deeper Dive into EXPLAINEDB
 
IOT with PostgreSQL
IOT with PostgreSQLIOT with PostgreSQL
IOT with PostgreSQLEDB
 
A Journey from Oracle to PostgreSQL
A Journey from Oracle to PostgreSQLA Journey from Oracle to PostgreSQL
A Journey from Oracle to PostgreSQLEDB
 
Psql is awesome!
Psql is awesome!Psql is awesome!
Psql is awesome!EDB
 
EDB 13 - New Enhancements for Security and Usability - APJ
EDB 13 - New Enhancements for Security and Usability - APJEDB 13 - New Enhancements for Security and Usability - APJ
EDB 13 - New Enhancements for Security and Usability - APJEDB
 
Comment sauvegarder correctement vos données
Comment sauvegarder correctement vos donnéesComment sauvegarder correctement vos données
Comment sauvegarder correctement vos donnéesEDB
 
Cloud Native PostgreSQL - Italiano
Cloud Native PostgreSQL - ItalianoCloud Native PostgreSQL - Italiano
Cloud Native PostgreSQL - ItalianoEDB
 
New enhancements for security and usability in EDB 13
New enhancements for security and usability in EDB 13New enhancements for security and usability in EDB 13
New enhancements for security and usability in EDB 13EDB
 
Best Practices in Security with PostgreSQL
Best Practices in Security with PostgreSQLBest Practices in Security with PostgreSQL
Best Practices in Security with PostgreSQLEDB
 
Cloud Native PostgreSQL - APJ
Cloud Native PostgreSQL - APJCloud Native PostgreSQL - APJ
Cloud Native PostgreSQL - APJEDB
 

More from EDB (20)

Cloud Migration Paths: Kubernetes, IaaS, or DBaaS
Cloud Migration Paths: Kubernetes, IaaS, or DBaaSCloud Migration Paths: Kubernetes, IaaS, or DBaaS
Cloud Migration Paths: Kubernetes, IaaS, or DBaaS
 
Die 10 besten PostgreSQL-Replikationsstrategien für Ihr Unternehmen
Die 10 besten PostgreSQL-Replikationsstrategien für Ihr UnternehmenDie 10 besten PostgreSQL-Replikationsstrategien für Ihr Unternehmen
Die 10 besten PostgreSQL-Replikationsstrategien für Ihr Unternehmen
 
Migre sus bases de datos Oracle a la nube
Migre sus bases de datos Oracle a la nube Migre sus bases de datos Oracle a la nube
Migre sus bases de datos Oracle a la nube
 
EFM Office Hours - APJ - July 29, 2021
EFM Office Hours - APJ - July 29, 2021EFM Office Hours - APJ - July 29, 2021
EFM Office Hours - APJ - July 29, 2021
 
Benchmarking Cloud Native PostgreSQL
Benchmarking Cloud Native PostgreSQLBenchmarking Cloud Native PostgreSQL
Benchmarking Cloud Native PostgreSQL
 
Las Variaciones de la Replicación de PostgreSQL
Las Variaciones de la Replicación de PostgreSQLLas Variaciones de la Replicación de PostgreSQL
Las Variaciones de la Replicación de PostgreSQL
 
NoSQL and Spatial Database Capabilities using PostgreSQL
NoSQL and Spatial Database Capabilities using PostgreSQLNoSQL and Spatial Database Capabilities using PostgreSQL
NoSQL and Spatial Database Capabilities using PostgreSQL
 
Is There Anything PgBouncer Can’t Do?
Is There Anything PgBouncer Can’t Do?Is There Anything PgBouncer Can’t Do?
Is There Anything PgBouncer Can’t Do?
 
Data Analysis with TensorFlow in PostgreSQL
Data Analysis with TensorFlow in PostgreSQLData Analysis with TensorFlow in PostgreSQL
Data Analysis with TensorFlow in PostgreSQL
 
Practical Partitioning in Production with Postgres
Practical Partitioning in Production with PostgresPractical Partitioning in Production with Postgres
Practical Partitioning in Production with Postgres
 
A Deeper Dive into EXPLAIN
A Deeper Dive into EXPLAINA Deeper Dive into EXPLAIN
A Deeper Dive into EXPLAIN
 
IOT with PostgreSQL
IOT with PostgreSQLIOT with PostgreSQL
IOT with PostgreSQL
 
A Journey from Oracle to PostgreSQL
A Journey from Oracle to PostgreSQLA Journey from Oracle to PostgreSQL
A Journey from Oracle to PostgreSQL
 
Psql is awesome!
Psql is awesome!Psql is awesome!
Psql is awesome!
 
EDB 13 - New Enhancements for Security and Usability - APJ
EDB 13 - New Enhancements for Security and Usability - APJEDB 13 - New Enhancements for Security and Usability - APJ
EDB 13 - New Enhancements for Security and Usability - APJ
 
Comment sauvegarder correctement vos données
Comment sauvegarder correctement vos donnéesComment sauvegarder correctement vos données
Comment sauvegarder correctement vos données
 
Cloud Native PostgreSQL - Italiano
Cloud Native PostgreSQL - ItalianoCloud Native PostgreSQL - Italiano
Cloud Native PostgreSQL - Italiano
 
New enhancements for security and usability in EDB 13
New enhancements for security and usability in EDB 13New enhancements for security and usability in EDB 13
New enhancements for security and usability in EDB 13
 
Best Practices in Security with PostgreSQL
Best Practices in Security with PostgreSQLBest Practices in Security with PostgreSQL
Best Practices in Security with PostgreSQL
 
Cloud Native PostgreSQL - APJ
Cloud Native PostgreSQL - APJCloud Native PostgreSQL - APJ
Cloud Native PostgreSQL - APJ
 

Recently uploaded

Salesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantSalesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantAxelRicardoTrocheRiq
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfkalichargn70th171
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVshikhaohhpro
 
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerThousandEyes
 
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️anilsa9823
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...MyIntelliSource, Inc.
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...OnePlan Solutions
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️Delhi Call girls
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providermohitmore19
 
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AISyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AIABDERRAOUF MEHENNI
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Steffen Staab
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsJhone kinadey
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...gurkirankumar98700
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionSolGuruz
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsAndolasoft Inc
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfkalichargn70th171
 
Test Automation Strategy for Frontend and Backend
Test Automation Strategy for Frontend and BackendTest Automation Strategy for Frontend and Backend
Test Automation Strategy for Frontend and BackendArshad QA
 

Recently uploaded (20)

Salesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantSalesforce Certified Field Service Consultant
Salesforce Certified Field Service Consultant
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
 
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AISyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
 
Exploring iOS App Development: Simplifying the Process
Exploring iOS App Development: Simplifying the ProcessExploring iOS App Development: Simplifying the Process
Exploring iOS App Development: Simplifying the Process
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
 
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with Precision
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.js
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 
Test Automation Strategy for Frontend and Backend
Test Automation Strategy for Frontend and BackendTest Automation Strategy for Frontend and Backend
Test Automation Strategy for Frontend and Backend
 
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS LiveVip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
 

Postgres Point-in-Time Recovery

  • 1. © 2015 EnterpriseDB Corporation. All rights reserved. 1 How to get your data back in Postgres – Point-in-Time Recovery (PITR) explained For more information on Postgres PITR please email sales@enterprisedb.com or visit www.enterprisedb.com
  • 2. © 2015 EnterpriseDB Corporation. All rights reserved. 2 Agenda •  Introduction •  Business Impact vs Cost •  Downtime Scenarios •  Backup Methods •  Point-In-Time Recovery •  Summary
  • 3. © 2015 EnterpriseDB Corporation. All rights reserved. 3 •  Disaster recovery strategies are key to the reliable operation of any business-critical environment. •  Backup and recovery plans must consider various failure scenarios and compliance requirements, including device failure, operator error, and data corruption. Introduction
  • 4. © 2015 EnterpriseDB Corporation. All rights reserved. 4 Business Impact vs Cost •  How long will recovery take? •  How long do we need to store backup data? •  How much will data storage cost? •  Will an outage effect our brand? •  Can any part of the database remain operational whilst I recover elsewhere? •  Do I know when the problem I am recovering from started?
  • 5. © 2015 EnterpriseDB Corporation. All rights reserved. 5 Downtime Scenarios
  • 6. © 2015 EnterpriseDB Corporation. All rights reserved. 6 •  As with any database, a Postgres database should be backed up regularly. •  There are three fundamentally different approaches to backing up Postgres data: −  SQL dump −  File system level backup −  Continuous archiving Backup Methods
  • 7. © 2015 EnterpriseDB Corporation. All rights reserved. 7 •  Generate a text file with SQL commands •  Postgres provides the utility program pg_dump for this purpose. •  pg_dump does not block readers nor writers. •  Dumps created by pg_dump are internally consistent, that is, the dump represents a snapshot of the database as of the time pg_dump begins running. •  Syntax: pg_dump [options] [dbname] Backup – SQL Dump
  • 8. © 2015 EnterpriseDB Corporation. All rights reserved. 8 Backup – Entire Cluster – SQL Dump •  pg_dumpall is used to dump an entire database cluster in plain-text SQL format •  pg_dumpall dumps global objects: users, groups, and associated permissions •  Use PSQL to restore •  Syntax: pg_dumpall [options] > filename.backup
  • 9. © 2015 EnterpriseDB Corporation. All rights reserved. 9 •  Copy Postgres files from the file system. •  You can use whatever method you prefer for doing usual file system backups, for example: tar -cvf backup.tar /usr/local/pgsql/data •  The database server must be shut down in order to get a usable backup. •  File system backups only work for complete backups and recovery of an entire database cluster. Backup – Cold Backup
  • 10. © 2015 EnterpriseDB Corporation. All rights reserved. 10 •  Database can stay operational during backup. •  Postgres maintains WAL logs for all transactions in the pg_xlog directory. •  When full, Postgres automatically switches WAL logs. •  Continuous archiving can be setup to keep a copy of switched WAL logs which can later be used for recovery. •  Enables online file system backup of a database cluster. •  Requirements: wal_level = archive
 archive_mode = on
 archive_command = … Backup – Hot Backup
  • 11. © 2015 EnterpriseDB Corporation. All rights reserved. 11 1.  Connect using psql and issue SELECT pg_start_backup(‘any useful label’); 2.  Use a standard file system backup utility to back up the data directory. 3.  Connect using psql and issue SELECT pg_stop_backup(); 4.  Ensure to continuously archive WAL logs. Online Base Backup
  • 12. © 2015 EnterpriseDB Corporation. All rights reserved. 12 •  pg_basebackup takes a base backup of a Postgres cluster. •  Backup can be used to setup a standby with streaming replication and a Point-In-Time Recovery (PITR). •  pg_basebackup takes a binary copy of the database cluster files. •  pg_basebackup puts the database in and out of backup mode. Online Base Backup using pg_basebackup
  • 13. © 2015 EnterpriseDB Corporation. All rights reserved. 13 •  Point-in-time recovery (PITR) is the ability to restore a database cluster up to the present or to a specified point of time in the past. •  Uses a full database cluster backup and applies the WAL logs. •  Must be configured before it is needed. WAL log archiving must be enabled. •  Must have information of when you want to recover to. Point-in-Time Recovery
  • 14. © 2015 EnterpriseDB Corporation. All rights reserved. 14 Point-in-Time Recovery Demo
  • 15. © 2015 EnterpriseDB Corporation. All rights reserved. 15 •  pause_at_recovery_target = true •  hot_standby = on (if using pause_at_recovery_target) •  SELECT pg_is_xlog_replay_paused(); •  SELECT pg_xlog_replay_resume(); •  SELECT pg_catalog.pg_current_xlog_location(); •  SELECT pg_xlogfile_name(’output from above command'); •  SELECT pg_create_restore_point('webinar_restore'); Point-In-Time Recovery Help
  • 16. © 2015 EnterpriseDB Corporation. All rights reserved. 16 Summary •  Introduction •  Business Impact vs Cost •  Backup and Recovery Methods −  SQL Dump −  Cold Backup (offline Backup) −  Hot Backup (online Backup) −  Continuous Archiving •  Point-In Time Recovery •  Demo
  • 17. © 2015 EnterpriseDB Corporation. All rights reserved. 17 •  EDB Postgres Advanced Server 9.5 Download http://www.enterprisedb.com/downloads/postgres-postgresql-downloads •  Continuous Archiving and Point-in-Time Recovery (PITR) http://www.postgresql.org/docs/current/static/continuous-archiving.html •  pg_dump http://www.postgresql.org/docs/9.5/static/app-pgdump.html •  pg_dumpall http://www.postgresql.org/docs/current/static/app-pg-dumpall.html •  pg_basebackup http://www.postgresql.org/docs/current/static/app-pgbasebackup.html Contact sales@enterprisedb.com for more information on Postgres PITR Resources
  • 18. © 2015 EnterpriseDB Corporation. All rights reserved. 18 •  Take advantage of the most convenient training that best fits your learning style and get Postgres certified! −  EDB offers Classroom & on-site training globally −  Live virtual training courses can be taken from any location and maintains live communication with the instructor to guide you and answer questions quickly. •  EDB’s eSubscriptions −  This annual subscription provides access to the entire EDB library of on-demand training courses for convenient access and training any time. •  Postgres Training Credits (PTC) −  Training credits provide the flexibility to pre-purchase blocks of training credits that can be spent on any combination of our training delivery methods. It is a convenient way to receive training with a built-in price discount. •  Earn an Associate-level or Professional-level Postgres Certification To learn more about EDB’s training schedule, Certification, eSubscriptions and Training Credits email training@enterprisedb.com Sharpen your skills with Training and Certification
  • 19. © 2015 EnterpriseDB Corporation. All rights reserved. 19