SlideShare a Scribd company logo
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.
Zero to Hero
Running Postgres in Kubernetes
Taylor Graham : Field CTO
Twitter: @thecloudslayer
1
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.2
WHO IS RUNNING K8S ON LAPTOP?
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.3
WHO
2019 Container Adoption Survey - Diamanti
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.4
WHAT
2019 Container Adoption Survey - Diamanti
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.5
WHERE
2019 Container Adoption Survey - Diamanti
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.6
WHY
• Business: Kubernetes is a system for deploying applications that
can save money because it takes less IT manpower to manage
and helps more efficiently utilize the infrastructure. It helps
make your apps a more portable, so you can move them more
easily between different clouds and internal environments or
laptop to laptop.
• Tech: Agility in development, deployment, and operations
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.7
BASIC CONCEPTS
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.8
CLUSTER
• Doc: I could not find a
definition.
• Taylor: A Kubernetes
cluster is everything.
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.9
MASTER
• DOC: The Kubernetes Master is a collection of three processes
that run on a single node in your cluster, which is designated as
the master node. Those processes are: kube-apiserver, kube-
controller-manager and kube-scheduler.The Kubernetes master
is responsible for maintaining the desired state for your cluster.
• Taylor: I would call it the
brains / command and control.
I would think of it like vCenter
coming from that world.
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.10
CLUSTER COMMANDS
Kubectl cluster-info
Kubectl version
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.11
NAMESPACE
• Doc: Namespaces are a way to divide
cluster resources between multiple users.
Namespace provide a scope for names.
Names of resources need to be unique
within a namespace, but not across
namespaces. Namespaces can not be
nested inside one another and each
Kubernetes resource can only be in one
namespace.
• Taylor: It’s a good way not to blow
everything up ASAP.
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.12
NAMESPACE COMMANDS
helm install edb-2.4.2.tgz -f myvalues.yaml –namespace anotherfailwhale
Kubectl create namespace anotherfailwhale
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.13
NODES
• Doc: A node is a worker machine in Kubernetes, previously known
as a minion. A node may be a VM or physical machine, depending
on the cluster. Each node contains the services necessary to
run pods and is managed by the master components. The services
on a node include the container runtime, kubelet and kube-proxy
• Taylor: The physical server
or virtual machine running
all the magic.
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.14
NODE COMMANDS
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.14
NODE COMMANDS
Kubectl get nodes
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.15
POD
• Doc: A Pod is the basic execution unit of a Kubernetes
application–the smallest and simplest unit in the
Kubernetes object model that you create or deploy. A Pod
represents processes running on your Cluster.
• Taylor: Because they
share a local host with
all containers in pod I
think of it like docker-
compose on your
laptop.
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.16
POD COMMANDS
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.17
AND MORE POD COMMANDS
kubectl describe pod
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.18
SERVICE
• Doc: a Service is an abstraction which defines a
logical set of Pods and a policy by which to
access them. The set of Pods targeted by a
Service is usually determined by a selector.
• Taylor: what the doc said….
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.19
PV/PVC
• Doc: A PersistentVolume (PV) is a piece of storage in the cluster that
has been provisioned by an administrator or dynamically provisioned
using Storage Classes. A PersistentVolumeClaim (PVC) is a request
for storage by a user. It is similar to a pod. Pods consume node
resources and PVCs consume PV resources.
• Taylor: LUN and VMDK
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.20
PV
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.21
DEPLOYMENT / REPLICASET
• A Deployment controller provides declarative updates
for Pods and ReplicaSets.
• A ReplicaSet’s purpose is to maintain a stable set of replica Pods
running at any given time. As such, it is often used to guarantee the
availability of a specified number of identical Pods.
• Taylor:
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.22
STATEFULSET
• Doc: StatefulSet is the workload API object used to manage
stateful applications. Manages the deployment and scaling
of a set of Pods , and provides guarantees about the
ordering and uniqueness of these Pods.
• Taylor: Where you run a
database.
Stable, unique network identifiers. $(statefulset name)-$(ordinal)
Stable, persistent storage.
Ordered, graceful deployment and scaling.
Ordered, automated rolling updates.
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.23
DESIGN PATTERNS
© Copyright EnterpriseDB Corporation, 2019. All rights reserved.24
SINGLE NODE
Postgres
Data
Application Database
Stand alone Postgres server
basic configuration
Containers
Pods
© Copyright EnterpriseDB Corporation, 2019. All rights reserved.
metrics
25
HA REFERENCE ARCHITECTURE
Postgres
HA
Agent
Proxy
Mon
Agent
Data
Application
EDB-Service
Postgres
HA
Agent
Mon
Agent
Data
Postgres
HA
Agent
DR
Tool
Proxy
Mon
Agent
Data
Admin
Tool
read/write
readread
redundant
streaming
replication
streaming
replication
Shared or Local Storage
Database, Tools, Agents
Containers
Pods
Application Application
Master Standby 2Standby 1
Proxy
Postgres cluster
with application scale-out
Backup
© Copyright EnterpriseDB Corporation, 2019. All rights reserved.
metrics
26
On-Prem In-Memory Compute Nodes
Postgres
HA
Agent
Proxy
Mon
Agent
EDB-Service
Postgres
HA
Agent
Mon
AgentPostgres
HA
Agent
DR
Tool
Proxy
Mon
Agent
Admin
Tool
read/write
readread
redundant
streaming
replication
Database, Tools, Agents
Containers
Pods
Master Standby 2Standby 1
Proxy
NODE POOL DB PREFORMANCE NODE 2 NODE 3
Volume Claim Volume Claim Volume Claim
Data Data DataBackup
Nodes
ApplicationApplication Application
streaming
replication
17k TPS
PgBench
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.27
OK LETS DEPLOY
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.28
KUBECTL
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.29
HELM
• helm install edb-2.4.2.tgz -f myvalues.yaml
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.30
OPENSHIFT
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.31
RANDOM THOUGHTS
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.32
MONITORING THOUGHTS
Old way
Utilization (U): The percentage of time a resource is in use.
Saturation (S): The amount of work the resource must (the “queue” of work).
Errors (E): A count of errors.
RED methodology
Rate (R): The number of requests per second.
Errors (E): The number of failed requests.
Duration (D): The amount of time to process a request.
RED is actually derived from The Four Golden Signals
Latency: The time it takes to service a request.
Traffic: A measure of how much demand on the system.
Errors: The rate of failed requests.
Saturation: A measure of how “full” a service is, often measured by latency.
OOM KILLER
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.33
EVERYTHING ELSE
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.
QUESTIONS & DISCUSSION
34
CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.
THANK YOU
info@enterprisedb.com
www.enterprisedb.com
35

More Related Content

PPTX
Advanced Database Patterns for Kubernetes
 
PPTX
Preview of the EDB Postgres Roadmap
 
PDF
KT/KTDS Case Study: Open Source Database Adoption in Telecom
 
PDF
How to Build On-demand Oracle Compatible Postgres Database in Minutes
 
PDF
Optimizing Performance and Security with Platform Native Packaging
 
PPTX
60000 TPS: How many CPUs?, Enterprise Postgres Day
 
PPTX
Riding the Second Wave: Open Source for Relational Databases, Enterprise Post...
 
PDF
HTAP By Accident: Getting More From PostgreSQL Using Hardware Acceleration
 
Advanced Database Patterns for Kubernetes
 
Preview of the EDB Postgres Roadmap
 
KT/KTDS Case Study: Open Source Database Adoption in Telecom
 
How to Build On-demand Oracle Compatible Postgres Database in Minutes
 
Optimizing Performance and Security with Platform Native Packaging
 
60000 TPS: How many CPUs?, Enterprise Postgres Day
 
Riding the Second Wave: Open Source for Relational Databases, Enterprise Post...
 
HTAP By Accident: Getting More From PostgreSQL Using Hardware Acceleration
 

What's hot (20)

PPTX
Where Should You Deliver Database Services From?
 
PDF
Managing Postgres at Scale With Postgres Enterprise Manager
 
PDF
Best Practices for Monitoring Postgres
 
PPTX
Whats New in Postgres 12
 
PPTX
Running Highly Available Postgres Databases in Containers
 
PPTX
New Enterprise Cloud Database Options for 2019
 
PDF
New Strategies for Database Modernization
 
PPTX
Automating a PostgreSQL High Availability Architecture with Ansible
 
PDF
No Time to Waste: Migrate from Oracle to EDB Postgres in Minutes
 
PDF
Public Sector Virtual Town Hall
 
PPTX
Creating a Multi-Layered Secured Postgres Database
 
PPTX
Not all open source is the same
 
PPTX
Cloud Native PostgreSQL
 
PPTX
New Approaches to Integrating Oracle and Postgres Database Strategies
 
PDF
Discover PostGIS: Add Spatial functions to PostgreSQL
 
PDF
Exploring Postgres with Bruce Momjian
 
PDF
Remote DBA Service: Powering your DBA needs
 
PPTX
Kubernetes with Docker Enterprise for multi and hybrid cloud strategy
PPTX
Automating Postgres Deployments on AWS and VMware, with Terraform and Ansible
 
PPTX
New Integration Options with Postgres Enterprise Manager 8.0
 
Where Should You Deliver Database Services From?
 
Managing Postgres at Scale With Postgres Enterprise Manager
 
Best Practices for Monitoring Postgres
 
Whats New in Postgres 12
 
Running Highly Available Postgres Databases in Containers
 
New Enterprise Cloud Database Options for 2019
 
New Strategies for Database Modernization
 
Automating a PostgreSQL High Availability Architecture with Ansible
 
No Time to Waste: Migrate from Oracle to EDB Postgres in Minutes
 
Public Sector Virtual Town Hall
 
Creating a Multi-Layered Secured Postgres Database
 
Not all open source is the same
 
Cloud Native PostgreSQL
 
New Approaches to Integrating Oracle and Postgres Database Strategies
 
Discover PostGIS: Add Spatial functions to PostgreSQL
 
Exploring Postgres with Bruce Momjian
 
Remote DBA Service: Powering your DBA needs
 
Kubernetes with Docker Enterprise for multi and hybrid cloud strategy
Automating Postgres Deployments on AWS and VMware, with Terraform and Ansible
 
New Integration Options with Postgres Enterprise Manager 8.0
 
Ad

Similar to Zero-to-Hero: Running Postgres in Kubernetes (20)

PPTX
Zero-to-hero: Running Postgres in Kubernetes, Enterprise Postgres Day
 
PPTX
Introduction to Kubernetes
PPTX
Running Stateful Apps on Kubernetes
PDF
01282016 Aerospike-Docker webinar
PDF
prodops.io k8s presentation
PDF
introduction to kubernetes slide deck by Roach
PPTX
Kubernetes for the VI Admin
PPTX
Best practices: running high-performance databases on Kubernetes
PDF
20200113 - IBM Cloud Côte d'Azur - DeepDive Kubernetes
PDF
The ultimate Kubernetes Deployment Checklist - Infra to Microservices
PPTX
20191201 kubernetes managed weblogic revival - part 2
PDF
Overpowered Kubernetes: CI/CD for K8s on Enterprise IaaS
PDF
The Kubernetes WebLogic revival (part 2)
PDF
stackconf 2024 | Orchestrating Resilient Data: Harnessing the Strength of Kub...
PDF
Accelerate Digital Transformation with IBM Cloud Private
PPTX
Operating Kubernetes at Scale (Australia Presentation)
PDF
Federated Kubernetes: As a Platform for Distributed Scientific Computing
PDF
Data-Centric Infrastructure for Agile Development
PPTX
InfluxDB Roadmap: What’s New and What’s Coming
PDF
Kubernetes basics and hands on exercise
Zero-to-hero: Running Postgres in Kubernetes, Enterprise Postgres Day
 
Introduction to Kubernetes
Running Stateful Apps on Kubernetes
01282016 Aerospike-Docker webinar
prodops.io k8s presentation
introduction to kubernetes slide deck by Roach
Kubernetes for the VI Admin
Best practices: running high-performance databases on Kubernetes
20200113 - IBM Cloud Côte d'Azur - DeepDive Kubernetes
The ultimate Kubernetes Deployment Checklist - Infra to Microservices
20191201 kubernetes managed weblogic revival - part 2
Overpowered Kubernetes: CI/CD for K8s on Enterprise IaaS
The Kubernetes WebLogic revival (part 2)
stackconf 2024 | Orchestrating Resilient Data: Harnessing the Strength of Kub...
Accelerate Digital Transformation with IBM Cloud Private
Operating Kubernetes at Scale (Australia Presentation)
Federated Kubernetes: As a Platform for Distributed Scientific Computing
Data-Centric Infrastructure for Agile Development
InfluxDB Roadmap: What’s New and What’s Coming
Kubernetes basics and hands on exercise
Ad

More from EDB (20)

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

Recently uploaded (20)

PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PPTX
Spectroscopy.pptx food analysis technology
PPTX
Cloud computing and distributed systems.
PPTX
Programs and apps: productivity, graphics, security and other tools
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
NewMind AI Weekly Chronicles - August'25-Week II
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PDF
Approach and Philosophy of On baking technology
PPT
Teaching material agriculture food technology
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
Spectral efficient network and resource selection model in 5G networks
PDF
Network Security Unit 5.pdf for BCA BBA.
PPTX
A Presentation on Artificial Intelligence
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PPTX
sap open course for s4hana steps from ECC to s4
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
Reach Out and Touch Someone: Haptics and Empathic Computing
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Spectroscopy.pptx food analysis technology
Cloud computing and distributed systems.
Programs and apps: productivity, graphics, security and other tools
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
NewMind AI Weekly Chronicles - August'25-Week II
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
The Rise and Fall of 3GPP – Time for a Sabbatical?
Approach and Philosophy of On baking technology
Teaching material agriculture food technology
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
20250228 LYD VKU AI Blended-Learning.pptx
Spectral efficient network and resource selection model in 5G networks
Network Security Unit 5.pdf for BCA BBA.
A Presentation on Artificial Intelligence
Mobile App Security Testing_ A Comprehensive Guide.pdf
sap open course for s4hana steps from ECC to s4
Building Integrated photovoltaic BIPV_UPV.pdf

Zero-to-Hero: Running Postgres in Kubernetes

  • 1. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved. Zero to Hero Running Postgres in Kubernetes Taylor Graham : Field CTO Twitter: @thecloudslayer 1
  • 2. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.2 WHO IS RUNNING K8S ON LAPTOP?
  • 3. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.3 WHO 2019 Container Adoption Survey - Diamanti
  • 4. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.4 WHAT 2019 Container Adoption Survey - Diamanti
  • 5. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.5 WHERE 2019 Container Adoption Survey - Diamanti
  • 6. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.6 WHY • Business: Kubernetes is a system for deploying applications that can save money because it takes less IT manpower to manage and helps more efficiently utilize the infrastructure. It helps make your apps a more portable, so you can move them more easily between different clouds and internal environments or laptop to laptop. • Tech: Agility in development, deployment, and operations
  • 7. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.7 BASIC CONCEPTS
  • 8. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.8 CLUSTER • Doc: I could not find a definition. • Taylor: A Kubernetes cluster is everything.
  • 9. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.9 MASTER • DOC: The Kubernetes Master is a collection of three processes that run on a single node in your cluster, which is designated as the master node. Those processes are: kube-apiserver, kube- controller-manager and kube-scheduler.The Kubernetes master is responsible for maintaining the desired state for your cluster. • Taylor: I would call it the brains / command and control. I would think of it like vCenter coming from that world.
  • 10. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.10 CLUSTER COMMANDS Kubectl cluster-info Kubectl version
  • 11. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.11 NAMESPACE • Doc: Namespaces are a way to divide cluster resources between multiple users. Namespace provide a scope for names. Names of resources need to be unique within a namespace, but not across namespaces. Namespaces can not be nested inside one another and each Kubernetes resource can only be in one namespace. • Taylor: It’s a good way not to blow everything up ASAP.
  • 12. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.12 NAMESPACE COMMANDS helm install edb-2.4.2.tgz -f myvalues.yaml –namespace anotherfailwhale Kubectl create namespace anotherfailwhale
  • 13. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.13 NODES • Doc: A node is a worker machine in Kubernetes, previously known as a minion. A node may be a VM or physical machine, depending on the cluster. Each node contains the services necessary to run pods and is managed by the master components. The services on a node include the container runtime, kubelet and kube-proxy • Taylor: The physical server or virtual machine running all the magic.
  • 14. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.14 NODE COMMANDS CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.14 NODE COMMANDS Kubectl get nodes
  • 15. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.15 POD • Doc: A Pod is the basic execution unit of a Kubernetes application–the smallest and simplest unit in the Kubernetes object model that you create or deploy. A Pod represents processes running on your Cluster. • Taylor: Because they share a local host with all containers in pod I think of it like docker- compose on your laptop.
  • 16. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.16 POD COMMANDS
  • 17. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.17 AND MORE POD COMMANDS kubectl describe pod
  • 18. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.18 SERVICE • Doc: a Service is an abstraction which defines a logical set of Pods and a policy by which to access them. The set of Pods targeted by a Service is usually determined by a selector. • Taylor: what the doc said….
  • 19. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.19 PV/PVC • Doc: A PersistentVolume (PV) is a piece of storage in the cluster that has been provisioned by an administrator or dynamically provisioned using Storage Classes. A PersistentVolumeClaim (PVC) is a request for storage by a user. It is similar to a pod. Pods consume node resources and PVCs consume PV resources. • Taylor: LUN and VMDK
  • 20. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.20 PV
  • 21. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.21 DEPLOYMENT / REPLICASET • A Deployment controller provides declarative updates for Pods and ReplicaSets. • A ReplicaSet’s purpose is to maintain a stable set of replica Pods running at any given time. As such, it is often used to guarantee the availability of a specified number of identical Pods. • Taylor:
  • 22. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.22 STATEFULSET • Doc: StatefulSet is the workload API object used to manage stateful applications. Manages the deployment and scaling of a set of Pods , and provides guarantees about the ordering and uniqueness of these Pods. • Taylor: Where you run a database. Stable, unique network identifiers. $(statefulset name)-$(ordinal) Stable, persistent storage. Ordered, graceful deployment and scaling. Ordered, automated rolling updates.
  • 23. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.23 DESIGN PATTERNS
  • 24. © Copyright EnterpriseDB Corporation, 2019. All rights reserved.24 SINGLE NODE Postgres Data Application Database Stand alone Postgres server basic configuration Containers Pods
  • 25. © Copyright EnterpriseDB Corporation, 2019. All rights reserved. metrics 25 HA REFERENCE ARCHITECTURE Postgres HA Agent Proxy Mon Agent Data Application EDB-Service Postgres HA Agent Mon Agent Data Postgres HA Agent DR Tool Proxy Mon Agent Data Admin Tool read/write readread redundant streaming replication streaming replication Shared or Local Storage Database, Tools, Agents Containers Pods Application Application Master Standby 2Standby 1 Proxy Postgres cluster with application scale-out Backup
  • 26. © Copyright EnterpriseDB Corporation, 2019. All rights reserved. metrics 26 On-Prem In-Memory Compute Nodes Postgres HA Agent Proxy Mon Agent EDB-Service Postgres HA Agent Mon AgentPostgres HA Agent DR Tool Proxy Mon Agent Admin Tool read/write readread redundant streaming replication Database, Tools, Agents Containers Pods Master Standby 2Standby 1 Proxy NODE POOL DB PREFORMANCE NODE 2 NODE 3 Volume Claim Volume Claim Volume Claim Data Data DataBackup Nodes ApplicationApplication Application streaming replication 17k TPS PgBench
  • 27. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.27 OK LETS DEPLOY
  • 28. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.28 KUBECTL
  • 29. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.29 HELM • helm install edb-2.4.2.tgz -f myvalues.yaml
  • 30. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.30 OPENSHIFT
  • 31. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.31 RANDOM THOUGHTS
  • 32. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.32 MONITORING THOUGHTS Old way Utilization (U): The percentage of time a resource is in use. Saturation (S): The amount of work the resource must (the “queue” of work). Errors (E): A count of errors. RED methodology Rate (R): The number of requests per second. Errors (E): The number of failed requests. Duration (D): The amount of time to process a request. RED is actually derived from The Four Golden Signals Latency: The time it takes to service a request. Traffic: A measure of how much demand on the system. Errors: The rate of failed requests. Saturation: A measure of how “full” a service is, often measured by latency. OOM KILLER
  • 33. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved.33 EVERYTHING ELSE
  • 34. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved. QUESTIONS & DISCUSSION 34
  • 35. CONFIDENTIAL © Copyright EnterpriseDB Corporation, 2019. All rights reserved. THANK YOU info@enterprisedb.com www.enterprisedb.com 35