Building a High-Availability PostgreSQL Cluster



Similar documents
OpenLDAP in High Availability Environments

High-Availability Using Open Source Software

High Availability with Postgres Plus Advanced Server. An EnterpriseDB White Paper

Overview: Clustering MySQL with DRBD & Pacemaker

Pacemaker. A Scalable Cluster Resource Manager for Highly Available Services. Owen Le Blanc. I T Services University of Manchester

Cluster Configuration Manual Cluster configuration on Database Servers

High Availability Storage

Open Source High Availability Writing Resource Agents for your own services. Lars Marowsky-Brée Team Lead SUSE Labs

Snapt Redundancy Manual

Linux Cluster. Administration

Highly Available NFS Storage with DRBD and Pacemaker

Stretching A Wolfpack Cluster Of Servers For Disaster Tolerance. Dick Wilkins Program Manager Hewlett-Packard Co. Redmond, WA dick_wilkins@hp.

High Availability Database Solutions. for PostgreSQL & Postgres Plus

Red Hat Enterprise Linux 7 High Availability Add-On Overview

High Availability with PostgreSQL and Pacemaker

Pacemaker Remote. Scaling High Availablity Clusters. David Vossel

SAP HANA System Replication on SUSE Linux Enterprise Server for SAP Applications

Red Hat Enterprise Linux 7 High Availability Add-On Overview

Red Hat Cluster Suite

Implementing the SUSE Linux Enterprise High Availability Extension on System z

PRM and DRBD tutorial. Yves Trudeau October 2012

Implementing and Managing Windows Server 2008 Clustering

Database Replication with MySQL and PostgreSQL

The elephant called PostgreSQL

High Availability and Disaster Recovery for SAP HANA with SUSE Linux Enterprise Server for SAP Applications

SAP HANA System Replication on SLES for SAP Applications. 11 SP3

Enterprise Linux Business Continuity Solutions for Critical Applications

High Availability and Backup Strategies for the Lustre MDS Server

Introduction to Highly Available NFS Server on scale out storage systems based on GlusterFS

PVFS High Availability Clustering using Heartbeat 2.0

MySQL High Availability Solutions. Lenz Grimmer OpenSQL Camp St. Augustin Germany

Novell PlateSpin Orchestrate

High Availability Solutions for MySQL. Lenz Grimmer DrupalCon 2008, Szeged, Hungary

HAOSCAR 2.0: an open source HA-enabling framework for mission critical systems


Secure Web Gateway Version 11.7 High Availability

Administration Guide. SUSE Linux Enterprise High Availability Extension 12 SP1

short introduction to linux high availability description of problem and solution possibilities linux tools

Ingres High Availability Option

High-Availability in the Cloud Architectural Best Practices

Parallels Virtuozzo Containers 4.7 for Linux

Cluster Guide. Version: 9.0 Released: March Companion Guides:

How to choose High Availability solutions for MySQL MySQL UC 2010 Yves Trudeau Read by Peter Zaitsev. Percona Inc MySQLPerformanceBlog.

Top 10 Reasons why MySQL Experts Switch to SchoonerSQL - Solving the common problems users face with MySQL

Owner of the content within this article is Written by Marc Grote

Cluster Guide. Released: February Companion Guides:

Linux High Availability

NFS Ganesha and Clustered NAS on Distributed Storage System, GlusterFS. Soumya Koduri Meghana Madhusudhan Red Hat

Based on Geo Clustering for SUSE Linux Enterprise Server High Availability Extension

PostgreSQL Clustering with Red Hat Cluster Suite

How To Use Suse Linux High Availability Extension 11 Sp (Suse Linux)

Agenda Zabawę 2 czas zacząć Co to jest corosync? Co to jest pacemaker? Zastosowania Podsumowanie

High Availability Solutions for the MariaDB and MySQL Database

Real-time Protection for Hyper-V

ZCP trunk (build 50384) Zarafa Collaboration Platform. Zarafa HA Manual

Red Hat Enterprise Linux 7 High Availability Add-On Administration. Configuring and Managing the High Availability Add-On

Comparing MySQL and Postgres 9.0 Replication

Oracle Exam 1z0-102 Oracle Weblogic Server 11g: System Administration I Version: 9.0 [ Total Questions: 111 ]

INUVIKA TECHNICAL GUIDE

Implementing the SUSE Linux Enterprise High Availability Extension on System z Mike Friesenegger

Special Edition for Loadbalancer.org GmbH

A new Cluster Resource Manager for heartbeat

Panorama High Availability

Investor Newsletter. Storage Made Easy Cloud Appliance High Availability Options WHAT IS THE CLOUD APPLIANCE?

Open-Xchange Server High Availability

Load Balancing and Clustering in EPiServer

Comparison of the High Availability and Grid Options

Clustering ExtremeZ-IP 4.1

SUSE Linux Enterprise High Availability Extension. Piotr Szewczuk konsultant

HighlyavailableiSCSIstoragewith DRBDandPacemaker

Red Hat Enterprise Linux 6 Cluster Suite Overview. Overview of the High Availability Add- On for Red Hat Enterprise Linux 6

Products for the registry databases and preparation for the disaster recovery

High Availability Guide for Distributed Systems

High Availability for Informatica Data Replication in a Cluster Environment

Database Replication: A Survey of Open Source and Commercial Tools

An Efficient Failover Enabling Mechanism in OpenStack

Mirror File System for Cloud Computing

TUT8155 Best Practices: Linux High Availability with VMware Virtual Machines

VERITAS Cluster Server v2.0 Technical Overview

Harmonizing policy management with Murphy in GENIVI, AGL and TIZEN IVI

Managing SAS Web Infrastructure Platform Data Server High-Availability Clusters

HIGH AVAILABILITY LINUX ARCHITECTURE FOR MISSION CRITICAL WORKLOADS

High Availability Using MySQL in the Cloud:

SQL Server Mirroring. Introduction. Setting up the databases for Mirroring

Bricks Cluster Technical Whitepaper

OES2 CLUSTERS. This recommendation assumes adherence to the following guidelines in order to achieve OES2 cluster protection:

Red Hat Cluster Suite Overview. Red Hat Cluster Suite for Red Hat Enterprise Linux 5

CHAPTER 2 BACKGROUND AND OBJECTIVE OF PRESENT WORK

AUTOMATED DISASTER RECOVERY SOLUTION USING AZURE SITE RECOVERY FOR FILE SHARES HOSTED ON STORSIMPLE

DNS ROUND ROBIN HIGH-AVAILABILITY LOAD SHARING

Corporate I.T. Services Limited Updating your Network Infrastructure Technology Skills to Windows Server 2008 (Beta 3)

Design for Failure High Availability Architectures using AWS

Veritas Cluster Server

Achieving High Availability on Linux for System z with Linux-HA Release 2

Managing Live Migrations

SUSE Linux Enterprise Server

Understanding Neo4j Scalability

DATA RECOVERY SOLUTIONS EXPERT DATA RECOVERY SOLUTIONS FOR ALL DATA LOSS SCENARIOS.

Red Hat Cluster Suite for Red Hat Enterprise Linux 5.2

Scalable Linux Clusters with LVS

Transcription:

Building a High-Availability PostgreSQL Cluster Presenter: Devon Mizelle System Administrator Co-Author: Steven Bambling System Administrator ARIN critical internet infrastructure

2 What is ARIN? Regional internet registry for North America and parts of the Caribbean. Distributes IPv4 & IPv6 addresses and Autonomous System Numbers (Internet number resources) in the region Provides authoritative WHOIS services for number resources in the region

3 ARIN s Internal Data! Inside of our database exists all of the v4 and v6 networks that we manage, the organizations that they belong to, and the contacts at those organizations. This means that data integrity and how we store said data is extremely important.

4 Requirements Multi- member Automatic Failover Prevent a tainted master from coming online Needs to be ACID- Compliant

5 Why Not Slony or pgpool-ii? Slony replaces pgsql s replication Why do this? Why not let pgsql handle it? Pgpool is not ACID-Compliant Doesn t confirm writes to multiple nodes

6 Our solution CMAN / Corosync Red Hat + Open-source solution for crossnode communication Pacemaker Red Hat and Novell s solution for service management and fencing Both under active development by Clusterlabs Interested in using it due to active development by Clusterlab

7 CMAN/ Corosync Provides a messaging framework between nodes Handles a heartbeat between nodes Are you up and available? Does not provide status of service, Pacemaker does Pacemaker uses Corosync to send messages between nodes CMAN has the ability to do more - but we just use it as a messaging framework

8 CMAN / Corosync Builds a cluster ring using a configuration file Used by Pacemaker in order to pass status messages between the nodes Simply a framework for communication no heavy lifting in our implementation

9 About Pacemaker Developed / maintained by Red Hat and Novell Scalable Anywhere from a two-node to a 16node setup Scriptable Resource scripts can be written in any language Monitoring Watches out for service state changes Fencing Disables a box and switches roles when failures occur Shareable database between nodes about status of services / nodes

10 Pacemaker Master? Sync An XML database (known as a CIB - cluster information base) is generated with the status of each resource and passed between nodes The state of pgsql is controlled by Pacemaker itself Pacemaker uses a resource script to interact with pgsql Can determine the state of the service (Master / Sync / Async) Async

11 Other Pacemaker Resources Fencing Pacemaker also handles the following resources besides PGSQL: * Fencing of resources * IP Address colocation IP Addresses

From the bottom up How does it all tie together? 12

13 Pacemaker Master Replication vip Sync All slaves in the cluster point to a replication vip This interface moves to whichever node is the master - this is called a colocation constraint Another vip for our application servers to connect to follows the master as well Client vip Async App

14 Event Scenario Master Sync Master Async? In the event that a node becomes unavailable, cman notifies pacemaker to fence or shut off communication to the node via SNMP to the switch The SYNC slave becomes the Master The ASYNC slave becomes the SYNC slave Upon manual recovery, the old Master becomes the async slave If any resources inside of Pacemaker on the master fail their monitoring check, fencing occurs as well These resources include: Both replication and client vips X X Async Sync

15 PostgreSQL Still in charge of replicating data The state of the service and how it starts is controlled by Pacemaker

16 Layout cman Slave Client cman Master cman Slave

Introspection Using Tools to Look Deeper 17

# crm_mon -i 1 -Arf 18 We disable quorum within the pacemaker HA cluster to allow for failure down to a single node cluster in the event multiple nodes fail 8 Resources configured ofce::heartbeat::ipaddr2 is the resource used to create the vip can be shell, ruby, etc. Primitive vs multistate Primitive only runs on one of the nodes in the cluster (vips, fencing) Multi- state resource runs on multiple nodes (pgsql) The vips are colocated. If anything happens to either of them, the entire node fails and moves to the next master There is a specific check interval for each resource stonith for fencing

# crm_mon i 1 -Arf (cont) 19 * All of the status comes from the pgsql pacemaker resource script receiver- status is error because the resource is written to monitor and check for cascading. We don t use cascading, haven t invested cycles Master- postgresql is the weight. Uses the weight to determine whom should be promoted next in line, which is why async has INFINITY STREAMING

Questions? 20 Devon Mizelle