postgresql operational tasks by 90% with scalegrid how to ......postgresql operational tasks by 90%...

23
How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid Presented by Dharshan Rangegowda PostgresConf Silicon Valley 2019

Upload: others

Post on 07-Jan-2020

12 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming

PostgreSQL Operational Tasks by 90% with ScaleGrid

Presented by Dharshan RangegowdaPostgresConf Silicon Valley 2019

Page 2: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Managing a PostgreSQL Production Deployment is Hard.

Page 3: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

There are hundreds of operational tasks involved, and missing one could critically impact on your deployment.

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Replication UpgradesScaling BackupsRestores FailoverEncryption-in-Transit OS PatchingMigrations ImportsProvisioning DeprovisioningMonitoring Query OptimizationAlerts PartitioningPerformance Tuning TroubleshootingExtensions User ManagementEncryption-at-Rest CloningCapacity Planning FirewallsLog Rotations Jobs MonitoringRefreshing Server ManagementRole Management Connections

Page 4: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

90% of Tasks Can Be Automated,100% Can Be Optimized.

Page 5: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

Automate vs. Optimize

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Replication UpgradesScaling BackupsRestores FailoverEncryption-in-Transit OS PatchingMigrations ImportsProvisioning DeprovisioningMonitoring AlertsPartitioning TroubleshootingExtensions User ManagementEncryption-at-Rest CloningCapacity Planning FirewallsLog Rotations Jobs MonitoringRefreshing Server ManagementRole Management Connections

Query Optimizations Performance TuningCapacity Planning

Page 6: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

So, Which PostgreSQL Operations Are The Most Time-Consuming?

Page 7: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Managing queries is the #1 time-consuming PostgreSQL task.Source: Latest PostgreSQL Trends: Most Time-Consuming Tasks & Important Metrics to Track

Page 8: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Provisioning PostgreSQL

Page 9: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

Creating New Clusters

Customize Your Deployment

- Primary & standby regions - Virtual machine size - PostgreSQL version - Replication strategy - SSL encryption-in-transit - Encryption-at-rest - Enable PgBouncer - Configure firewalls

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Page 10: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Automating PostgreSQL Backups

Page 11: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

Automating Backups

Scheduled Backups

- Customize frequency - Customize backup time - Customize the max number to retain

On-Demand Backups

- Perform before application events

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Page 12: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Scaling with Zero Downtime

Page 13: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

Dynamic Scaling

Scale with Zero Downtime

As long as you’re using a primary-standby configuration, you can scale dynamically with zero downtime in one click.

- Rolling operation - Take one node down at a time - Update instance type, disk, and IOPS - Bring node back up, wait to sync, repeat

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Page 14: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Fully Managed Upgrades

Page 15: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

Managed Upgrades

Scheduled Backups

- Customize frequency - Customize backup time - Customize the max number to retain

On-Demand Backups

- Perform before application events

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Page 16: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Customizing Your Alerts

Page 17: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

Customize Your Alerts

Alert Types - Metrics - Disk Free % - Role Change

PostgreSQL Metrics - CPU - Connections - Memory - Locks - Disk - Checkpoints - Operation - Many more..

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Page 18: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Configure PostgreSQL Parameters

Page 19: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Monitoring Performance

Page 20: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

Monitoring

OS Metrics - CPU - Disk IOPS

PostgreSQL Metrics - Connections- Operations (insert, update, query etc) - Disk queues - Replication delay

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Page 21: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Analyzing Slow Queries

Page 22: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

Query Analysis

Problem Queries

- Frequent queries - Slowest queries - Queries scanning most rows - Queries returning large # of results - Queries causing high lock %

How to Reduce Your Time-Consuming PostgreSQL Operational Tasks by 90% with ScaleGrid

Page 23: PostgreSQL Operational Tasks by 90% with ScaleGrid How to ......PostgreSQL Operational Tasks by 90% with ScaleGrid ... Performance Tuning Troubleshooting Extensions User Management

Get in touch

Questions?Twitter | @scalegridio

Email | [email protected]