pgpool talk latest - sra oss, inc. 日本支社 · monitoring back and recovery tool postgres...

21
© 2014 EnterpriseDB Corporation. All rights reserved. 1 EDB & PGPOOL Relationship and PGPOOL II 3.4 Benchmarking results on AWS May, 2015

Upload: others

Post on 06-Jul-2020

3 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !1

EDB & PGPOOL Relationship and PGPOOL II 3.4 Benchmarking results on AWSMay, 2015

Page 2: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !2

!!

• Ahsan Hadi !!

• Senior Director of Product Development with EnterpriseDB !!

• Managing PGPOOL II development from EDB

Page 3: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !3

The Database PostgreSQL / Postgres Plus Advanced Server

Tools xDB Replication

Server

Failover Manager

Management and Monitoring

Back and Recovery Tool Postgres Enterprise

Manager (PEM)

Stack Builder & Update Monitor

Cloud EnablementCloud Database for

Amazon Web Services Open Stack Support*

Core

ORPostgreSQL

Postgres Plus Advanced Server

ExtensionComponents (PostGIS, pgPool, pgBouncer, SQL/

Protect, PL/Perl Python TCL, FDW)

Connectors (.Net, JDBC, ODBC,OCL)

Utilities (EDBLoader, EDBPlus, ECPGPlus)

Migration Tool Kit

* Roadmap

EnterpriseDB Product Overview

APIs to enable the Platform as a Service*

Page 4: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !4

About my

Page 5: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !5

How EDB uses PGPOOL II

Page 6: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !6

PPCD - pgpool-II in the cloud

Page 7: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !7

!• PPCD allows the user to host an instance of PG and/or PPAS in

the cloud. !

• PGPOOL II runs on the master node !

• Client apps connect to PGPOOL. !

• Performs load balancing by sending the write queries to master and read queries across read replicas !

• Performs connection pooling

PPCD/pgpool II…

Page 8: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !8

!• EDB offering support and services for pgpool II !

• Some BIG companies using pgpool II !

• US Based Credit card company • Indian Government Organisations • Healthcare • Telecom • IT solution providers and consultancy services

and More….

Other services

Page 9: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !9

!In order of priority… !• Load Balancing (sql routing) !

• Failover with streaming replication !

• Connection Pooling !

• Watchdog PGPOOL II HA

Most commonly used features

Page 10: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !10

!!!• Parallel Query !!!

• PGPOOL Replication

Features not used

Page 11: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !11

Stand-by

Primary

Stre

amin

g R

eplic

atio

n

read/write

read only

PGPOOL-II 1

PGPOOL-II 2

RH

CS A

ctive/Passive

App

licat

ions

Rep

Mgr

A production customer scenario

Page 12: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !12

Cust

omer

issu

es/Q

uerie

s

015

3045

60YEAR

20132014

2015

2013 2014 2015

Page 13: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !13

!• Overall it has gotten very stable and resilient in last few major

releases. !

• Types of customer issues reported in last two years (most of these issues have been resolved) !

• Handling SSL based authentication • Performance issues with extended query protocol (performance not as good as simple query protocol)

• Issues with failover (not able to connect to stand-by immediately when failover happens)

• Sequence functions don’t work with pgpool • Performance issues with load balancing, the TPS is not very high

• Configuration issues • Memory leaks (memory issues addressed by plugging in PG memory and exception management) !

!!

!

Page 14: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !14

!• Improve performance with extended query protocol !

•Watchdog enhancements (making it more resilient and handle scenarios like split-brain, automatic failover) !

•Being able to install individual features of pgpool…I am only interested in connection pooling… !

•Enhancements with Failover functionality..seamless failover !

•Support more platforms, HPUX, solaris, windows… !

•GUI Installer and GUI monitoring tool !

•Better documentation !

Page 15: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !15

Benchmarking PGPOOL-II 3.4 on AWS - Environment

!• PGPOOL-II version 3.4 !

• PG version 9.3.5 !

• Benchmarking tool pgbench !• Benchmarking done on AWS instances !

• One pgpool-II instance with 5 read replicas !

• Compared with PG running stand-alone !

• PGPOOL-II configures with streaming replication, master/slave mode. !

• Apples-to-Apples Comparison (Same optimal real-world PG configuration changes across standalone PG and pgpool-II nodes)

Page 16: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !16

!

• Horizontal scalability when the database grows out of single server memory !

• With big data, concurrent clients and 5 read replicas the TPS is 2/3 times then community PG !

• After 4 read replica’s the performance bar comes down with the given workload. !

• Bad Performance with extended query protocol

Benchmarking PGPOOL-II 3.4 on AWS - Conclusions

Page 17: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !17

Benchmarking PGPOOL-II 3.4 on AWS - Actual Results

Page 18: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !18

Benchmarking PGPOOL-II 3.4 on AWS - Actual Results

Page 19: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !19

Benchmarking PGPOOL-II 3.4 on AWS - Actual Results

Page 20: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !20

PGPOOL II Future

!

• Very Bright !

• More remaining to be done for performance and failover management. Need to invest in tooling. !

• Will become the middleware product of choice for Load Balancing, Failover and HA for PG. !

• Need more funding and volunteers

Page 21: pgpool talk latest - SRA OSS, Inc. 日本支社 · Monitoring Back and Recovery Tool Postgres Enterprise Manager (PEM) Stack Builder & Update Monitor Cloud Enablement Cloud Database

© 2014 EnterpriseDB Corporation. All rights reserved. !21