SlideShare a Scribd company logo
1 of 150
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Grant McAlister – Senior Principal Engineer – Amazon RDS
Sept 2017
Tuning PostgreSQL for High
Write Workloads
High Write Workloads?
CLIENT
Database
Storage
Single
Insert/Update
High Write Workloads?
CLIENT
Database
Storage
Commit
Latency
Client
Latency
Single
Insert/Update
High Write Workloads?
CLIENT
Database
Storage
Commit
Latency
Client
Latency
CLIENT
Database
Storage
Single
Insert/Update
High Write Workloads?
CLIENT
Database
Storage
Commit
Latency
Client
Latency
CLIENT
Database
Storage
Commit
Latency
Client
Latency
Single
Insert/Update
Copy or
Multi-Insert
High Write Workloads?
CLIENT
Database
Storage
Commit
Latency
Client
Latency
CLIENT
Database
Storage
Commit
Latency
Client
Latency
Single
Insert/Update
Copy or
Multi-Insert
CLIENT
Database
Storage
High Write Workloads?
CLIENT
Database
Storage
Commit
Latency
Client
Latency
CLIENT
Database
Storage
Commit
Latency
Client
Latency
Single
Insert/Update
Copy or
Multi-Insert
CLIENT
Database
Storage
Commit
Latency
Many
Clients
T
H
R
O
U
G
H
P
U
T
Insert Test
Test Table
• UUID PK – Random
• ID int – Right Lean Sequence
• VARCHAR(100) – Random
• VARCHAR(50) – Small Set of Words
• INT – Random
• INT – Random (smaller set)
• BOOLEAN – Random (50/50)
• BOOLEAN – Somewhat Random (75/25)
• Timestamp – Right Lean
0
5,000
10,000
15,000
20,000
25,000
30,000
1 31 61 91 121 151 181 211 241 271
InsertsPerSecond
Minutes
Insert Workload- PostgreSQL 9.6
BASE Non Random GUID
WHICH ONE WOULD YOU LIKE
Update Test
Test Table
• UUID PK – Random
• ID int – Right Lean Sequence
• VARCHAR(100) – Random
• VARCHAR(50) – Small Set of Words
• INT – Random
• INT – Random (smaller set)
• BOOLEAN – Random (50/50)
• BOOLEAN – Somewhat Random (75/25)
• Timestamp – Right Lean
UPDATE #1
UPDATE #2
3,729 3,949
4,871
4,302
9,177
10,290
17,158
-
5,000
10,000
15,000
20,000
TPS(2UpdatesperTransaction)
Update Workload - PostgreSQL 9.6
BASE WAL Compression 16GB Max WAL
Async Reduced Indexes Non Random GUID
Aurora PostgreSQL
WHICH ONE WOULD YOU LIKE
Parameter Tuning
Concurrency and Throughput – Log Buffer
Queued Work
Log Buffer
Most Databases
Storage
Concurrency and Throughput – Log Buffer
Queued Work
Log Buffer
Most Databases
Storage
Concurrency and Throughput – Log Buffer
Queued Work
Log Buffer
Most Databases
Storage
Concurrency and Throughput – Log Buffer
Queued Work
Log Buffer
Most Databases
Storage
Concurrency and Throughput – Log Buffer
Queued Work
Log Buffer
Most Databases
Storage
Concurrency and Throughput – Log Buffer
Queued Work
Log Buffer
Most Databases
Storage
Concurrency and Throughput – Log Buffer
Queued Work
Log Buffer
Most Databases
Storage
Full Page Writes
Block in
Memory
PostgreSQL
WAL
Full Page Writes
Block in
Memory
PostgreSQL
update t set y = 6;
WAL
Full Page Writes
Block in
Memory
PostgreSQL
update t set y = 6;
Full
Block
WAL
Full Page Writes
Block in
Memory
PostgreSQL
update t set y = 6;
Full
Block
WAL
Full Page Writes
Block in
Memory
PostgreSQL
update t set y = 6;
Checkpoint
Datafile
Full
Block
WAL
Full Page Writes
Block in
Memory
PostgreSQL
update t set y = 6;
Checkpoint
Datafile
Full
Block
WAL
Archive
Full Page Writes
Block in
Memory
PostgreSQL
update t set y = 6;
Checkpoint
Datafile
Full
Block
WAL
Archive
4K
4K
8K
Full Page Writes
Block in
Memory
PostgreSQL
update t set y = 6;
Checkpoint
Datafile
Full
Block
WAL
Archive
4K
4K
8K
During crash
recovery
PostgreSQL
uses the FPW
block in the
WAL to replace
the bad
checkpointed
block
Full Page Writes
Block in
Memory
PostgreSQL
update t set y = 6;
Checkpoint
Datafile
Full
Block
WAL
Archive
4K
4K
8K
During crash
recovery
PostgreSQL
uses the FPW
block in the
WAL to replace
the bad
checkpointed
block
WAL throughput – Dump of wal
Btree d: INSERT_LEAF off 184, blkref #0: rel 1663/32772/32779 blk 300
Btree d: INSERT_LEAF off 110, blkref #0: rel 1663/32772/32784 blk 1092
Btree d: INSERT_LEAF off 41, blkref #0: rel 1663/32772/32782 blk 5752
Btree d: INSERT_LEAF off 40, blkref #0: rel 1663/32772/32782 blk 8000
Btree d: INSERT_LEAF off 89, blkref #0: rel 1663/32772/32779 blk 1757
Btree d: INSERT_LEAF off 363, blkref #0: rel 1663/32772/32781 blk 1355
Btree d: INSERT_LEAF off 77, blkref #0: rel 1663/32772/32783 blk 4
Btree d: INSERT_LEAF off 94, blkref #0: rel 1663/32772/32779 blk 2083
Btree d: INSERT_LEAF off 362, blkref #0: rel 1663/32772/32781 blk 1355
Btree d: INSERT_LEAF off 10, blkref #0: rel 1663/32772/32782 blk 7687
Btree d: INSERT_LEAF off 365, blkref #0: rel 1663/32772/32781 blk 1355
Btree d: INSERT_LEAF off 114, blkref #0: rel 1663/32772/32784 blk 791
Btree d: INSERT_LEAF off 2, blkref #0: rel 1663/32772/32783 blk 2213
Btree d: INSERT_LEAF off 2, blkref #0: rel 1663/32772/32785 blk 1639
Btree d: INSERT_LEAF off 209, blkref #0: rel 1663/32772/32784 blk 1433
Transaction d: COMMIT 2017-09-07 01:08:55.354810 UTC
At the beginning of the run
WAL throughput – Dump of wal
Btree d: INSERT_LEAF off 184, blkref #0: rel 1663/32772/32779 blk 300
Btree d: INSERT_LEAF off 110, blkref #0: rel 1663/32772/32784 blk 1092
Btree d: INSERT_LEAF off 41, blkref #0: rel 1663/32772/32782 blk 5752
Btree d: INSERT_LEAF off 40, blkref #0: rel 1663/32772/32782 blk 8000
Btree d: INSERT_LEAF off 89, blkref #0: rel 1663/32772/32779 blk 1757
Btree d: INSERT_LEAF off 363, blkref #0: rel 1663/32772/32781 blk 1355
Btree d: INSERT_LEAF off 77, blkref #0: rel 1663/32772/32783 blk 4
Btree d: INSERT_LEAF off 94, blkref #0: rel 1663/32772/32779 blk 2083
Btree d: INSERT_LEAF off 362, blkref #0: rel 1663/32772/32781 blk 1355
Btree d: INSERT_LEAF off 10, blkref #0: rel 1663/32772/32782 blk 7687
Btree d: INSERT_LEAF off 365, blkref #0: rel 1663/32772/32781 blk 1355
Btree d: INSERT_LEAF off 114, blkref #0: rel 1663/32772/32784 blk 791
Btree d: INSERT_LEAF off 2, blkref #0: rel 1663/32772/32783 blk 2213
Btree d: INSERT_LEAF off 2, blkref #0: rel 1663/32772/32785 blk 1639
Btree d: INSERT_LEAF off 209, blkref #0: rel 1663/32772/32784 blk 1433
Transaction d: COMMIT 2017-09-07 01:08:55.354810 UTC
Btree d: INSERT_LEAF off 216, blkref #0: rel 1663/16395/16407 blk 14331 FPW
Btree d: INSERT_LEAF off 123, blkref #0: rel 1663/16395/16406 blk 5
Btree d: INSERT_LEAF off 139, blkref #0: rel 1663/16395/16404 blk 25954
Btree d: INSERT_LEAF off 59, blkref #0: rel 1663/16395/16407 blk 17944 FPW
Btree d: INSERT_LEAF off 45, blkref #0: rel 1663/16395/16408 blk 17
Btree d: INSERT_LEAF off 252, blkref #0: rel 1663/16395/16404 blk 25954
Btree d: INSERT_LEAF off 135, blkref #0: rel 1663/16395/16408 blk 7
Btree d: INSERT_LEAF off 5, blkref #0: rel 1663/16395/16405 blk 131373 FPW
Btree d: INSERT_LEAF off 175, blkref #0: rel 1663/16395/16404 blk 25954
Btree d: INSERT_LEAF off 19, blkref #0: rel 1663/16395/16405 blk 40974 FPW
Btree d: INSERT_LEAF off 2, blkref #0: rel 1663/16395/16409 blk 1
Btree d: INSERT_LEAF off 19, blkref #0: rel 1663/16395/16405 blk 143873 FPW
Btree d: INSERT_LEAF off 123, blkref #0: rel 1663/16395/16406 blk 5
Btree d: INSERT_LEAF off 14, blkref #0: rel 1663/16395/16405 blk 37468 FPW
Btree d: INSERT_LEAF off 2, blkref #0: rel 1663/16395/16409 blk 1
Btree d: INSERT_LEAF off 84, blkref #0: rel 1663/16395/16407 blk 2696
Btree d: INSERT_LEAF off 149, blkref #0: rel 1663/16395/16407 blk 1401 FPW
Btree d: INSERT_LEAF off 2, blkref #0: rel 1663/16395/16406 blk 39718
Btree d: INSERT_LEAF off 2, blkref #0: rel 1663/16395/16410 blk 29411
Btree d: INSERT_LEAF off 2, blkref #0: rel 1663/16395/16408 blk 29370
Btree d: INSERT_LEAF off 123, blkref #0: rel 1663/16395/16406 blk 5
Btree d: INSERT_LEAF off 2, blkref #0: rel 1663/16395/16409 blk 1
Btree d: INSERT_LEAF off 24, blkref #0: rel 1663/16395/16405 blk 69991 FPW
Transaction d: COMMIT 2017-09-07 01:04:32.650362 UTC
At the beginning of the run Later in the run
1K vs 48K of data
WAL Compression
Block in
Memory
update t set y = 6;
Full
Block
WAL
WAL Compression
Block in
Memory
update t set y = 6;
WAL
Compressed
Block
WAL Compression
Block in
Memory
update t set y = 6;
WAL
Compressed
BlockCompressed
Block
WAL Compression
Block in
Memory
update t set y = 6;
WAL
Compressed
BlockCompressed
Block
WAL Compression
Block in
Memory
update t set y = 6;
WAL
Compressed
BlockCompressed
Block
WAL Compression
Block in
Memory
update t set y = 6;
WAL
Compressed
BlockCompressed
Block
WAL Compression
Block in
Memory
update t set y = 6;
WAL
Compressed
BlockCompressed
Block
WAL Compression
Block in
Memory
update t set y = 6;
Block on
Disk
Checkpoint
Datafile
WAL
Archive
Compressed
BlockCompressed
Block
Lot of Random
Values
=
Poor
Compression
0
5,000
10,000
15,000
20,000
25,000
30,000
1 31 61 91 121 151 181 211 241 271
InsertsPerSecond
Minutes
Insert Workload- PostgreSQL 9.6
BASE WAL Compression
3,729 3,949
4,871
4,302
9,177
10,290
17,158
-
5,000
10,000
15,000
20,000
TPS(2UpdatesperTransaction)
Update Workload - PostgreSQL 9.6
BASE WAL Compression 16GB Max WAL
Async Reduced Indexes Non Random GUID
Aurora PostgreSQL
Why didn’t WAL compression help
Regular – Average 5.7KB per FPW
Why didn’t WAL compression help
Regular – Average 5.7KB per FPW
Compressed – Average 5.2KB per FPW
Why didn’t WAL compression help
Regular – Average 5.7KB per FPW
Compressed – Average 5.2KB per FPW
Random Data does not compress well
0
5,000
10,000
15,000
20,000
25,000
30,000
1 31 61 91 121 151 181 211 241 271
InsertsPerSecond
Minutes
Insert Workload- PostgreSQL 9.6
BASE WAL Compression 16GB Max WAL
max_wal_size=16GB
More Blocks + Random Inserts = More FPW
Randomness and Size of the Data
Assume 10K Random Updates per Second
Assume checkpoint every 60 second
Touch 10K x 60 = 600K blocks between checkpoints
1GB table is ~130K blocks - Touch every block 4 times
100GB table is 13M blocks - Low chance of same block touch
3,729 3,949
4,871
4,302
9,177
10,290
17,158
-
5,000
10,000
15,000
20,000
TPS(2UpdatesperTransaction)
Update Workload - PostgreSQL 9.6
BASE WAL Compression 16GB Max WAL
Async Reduced Indexes Non Random GUID
Aurora PostgreSQL
3,729 3,949
4,871
4,302
9,177
10,290
17,158
-
5,000
10,000
15,000
20,000
TPS(2UpdatesperTransaction)
Update Workload - PostgreSQL 9.6
BASE WAL Compression 16GB Max WAL
Async Reduced Indexes Non Random GUID
Aurora PostgreSQL
What about ASYNC
Async Commit – Log Buffer
Queued Work
Log Buffer
Most Databases
Storage
Async Commit – Log Buffer
Queued Work
Log Buffer
Most Databases
StorageThese sessions no longer have
to wait
Async Commit – Log Buffer
Queued Work
Log Buffer
Most Databases
StorageThese sessions no longer have
to wait
Async Commit – Log Buffer
Queued Work
Log Buffer
Most Databases
StorageThese sessions no longer have
to wait
Longer Checkpoints – Reduce FPW - BUT
Default
min_wal_size=256MB, max_wal_size=2GB
recovery time = 3 seconds
New
min_wal_size=2GB, max_wal_size=16GB
recovery time = 91 seconds
Non Parameter Tuning
1-
200
1-
100
101-
200
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
Insert a Sequence Number into a B-tree
1-
200
1-
100
101-
200
Insert 201
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
1-
201
101-
201
151-
201
176-
201
4 blocks
loaded
Insert a Sequence Number into a B-tree
1-
200
1-
100
101-
200
Insert 201
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
Insert 202
1-
201
101-
201
151-
201
176-
201
1-
202
101-
202
151-
202
176-
202
4 blocks
loaded
Insert a Sequence Number into a B-tree
0 blocks
loaded
1-
200
1-
100
101-
200
Insert 201
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
Insert 202
1-
201
101-
201
151-
201
176-
201
1-
202
101-
202
151-
202
176-
202
4 blocks
loaded
Insert a Sequence Number into a B-tree
0 blocks
loaded
At least 1 FPW
1-
200
1-
100
101-
200
Insert
124
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
1-
200
101-
200
101-
150
101-
125
4 blocks
loaded
Insert a Random value into a B-tree
1-
200
1-
100
101-
200
Insert
124
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
Insert 99
1-
200
101-
200
101-
150
101-
125
4 blocks
loaded
1-
100
51-
100
76-
100
3 blocks
loaded
Insert a Random value into a B-tree
1-
200
1-
100
101-
200
Insert
124
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
Insert 99
1-
200
101-
200
101-
150
101-
125
4 blocks
loaded
1-
100
51-
100
76-
100
3 blocks
loaded
Insert a Random value into a B-tree
151-
200
151-
200
2 blocks
loaded
Insert 161
At least 3 FPW
Remember those 9 Indexes – Cut it to 6
Test Table
• UUID PK – Random
• ID int – Right Lean Sequence
• VARCHAR(100) – Random
• VARCHAR(50) – Small Set of Words
• INT – Random
• INT – Random (smaller set)
• BOOLEAN – Random (50/50)
• BOOLEAN – Somewhat Random (75/25)
• Timestamp – Right Lean
Remove Index
Remove Index
Remove Index – Allows HOT Update
HOT (Heap-Only-Tuple) Update
Not HOT
a
b
f
Indexes Heap
a, b, c, d, e, f
HOT (Heap-Only-Tuple) Update
Not HOT
a
b
f
Indexes Heap
a, b, c, d, e, f
a, b, c, d, e, f1
HOT (Heap-Only-Tuple) Update
Not HOT
a
b
f
Indexes Heap
a, b, c, d, e, f
a, b, c, d, e, f1
a’
b’
HOT (Heap-Only-Tuple) Update
Not HOT
a
b
f
Indexes Heap
a, b, c, d, e, f
a, b, c, d, e, f1
a’
b’
f1
HOT (Heap-Only-Tuple) Update
Not HOT
a
b
f
Indexes Heap
a, b, c, d, e, f
a, b, c, d, e, f1
a’
b’
f1
a, b, c1, d, e, f
HOT (Heap-Only-Tuple) Update
Not HOT
a
b
f
Indexes Heap
a, b, c, d, e, f
a, b, c, d, e, f1
a’
b’
f1
a, b, c1, d, e, f
HOT
a
b
f
Indexes Heap
a, b, c, d, e, f
HOT (Heap-Only-Tuple) Update
Not HOT
a
b
f
Indexes Heap
a, b, c, d, e, f
a, b, c, d, e, f1
a’
b’
f1
a, b, c1, d, e, f
HOT
a
b
f
Indexes Heap
a, b, c, d, e, f
a, b, c1, d, e, f
HOT (Heap-Only-Tuple) Update
Not HOT
a
b
f
Indexes Heap
a, b, c, d, e, f
a, b, c, d, e, f1
a’
b’
f1
a, b, c1, d, e, f
HOT
a
b
f
Indexes Heap
a, b, c, d, e, f
a, b, c1, d, e, f
HOT Updates – Looking at FPW in the logs
HOT Updated
Heap 14/ 68, , d: HOT_UPDATE off 19 xmax 2327993188 ; new off 3 xmax 0, blkref #0: rel 1663/41083/41086 blk 28
XLOG 0/ 3368, , d: FPI_FOR_HINT , blkref #0: rel 1663/41083/41092 blk 1492899 FPW
Transaction 8/ 34, , d: COMMIT 2017-09-07 00:07:17.532647 UTC
Non HOT Update
Heap 14/ 75, , d: UPDATE off 67 xmax 2327993195 ; new off 7 xmax 0, blkref #0: rel 1663/41083/41086 blk 285
XLOG 0/ 2774, , d: FPI_FOR_HINT , blkref #0: rel 1663/41083/41090 blk 7039952 FPW
Btree 2/ 120, , d: INSERT_LEAF off 17, blkref #0: rel 1663/41083/41090 blk 7039952
XLOG 0/ 3150, , d: FPI_FOR_HINT , blkref #0: rel 1663/41083/41092 blk 29 FPW
Btree 2/ 64, , d: INSERT_LEAF off 205, blkref #0: rel 1663/41083/41092 blk 29
Btree 2/ 2639, , d: INSERT_LEAF off 73, blkref #0: rel 1663/41083/41093 blk 4 FPW
Btree 2/ 3148, , d: INSERT_LEAF off 2, blkref #0: rel 1663/41083/41094 blk 1 FPW
Btree 2/ 5099, , d: INSERT_LEAF off 364, blkref #0: rel 1663/41083/41095 blk 4237904 FPW
Transaction 8/ 34, , d: COMMIT 2017-09-07 00:24:29.427017 UTC
3.4K VS 16.7K
HOT Updates – How to Track
sfo=> select n_tup_upd, n_tup_hot_upd from pg_stat_all_tables where relname = 'benchmark_uuid';
n_tup_upd | n_tup_hot_upd
-----------+---------------
0 | 0
sfo=> update benchmark_uuid set e=cast(0 as boolean) where id = 1000;
UPDATE 1
sfo=> select n_tup_upd, n_tup_hot_upd from pg_stat_all_tables where relname = 'benchmark_uuid';
n_tup_upd | n_tup_hot_upd
-----------+---------------
1 | 1
sfo=> update benchmark_uuid set last_updated=CURRENT_TIMESTAMP where id=1001;
UPDATE 1
sfo=> select n_tup_upd, n_tup_hot_upd from pg_stat_all_tables where relname = 'benchmark_uuid';
n_tup_upd | n_tup_hot_upd
-----------+---------------
2 | 1
HOT UPDATE
=
!=
0
5,000
10,000
15,000
20,000
25,000
30,000
1 31 61 91 121 151 181 211 241 271
InsertsPerSecond
Minutes
Insert Workload- PostgreSQL 9.6
BASE WAL Compression 16GB Max WAL Reduced Indexes
3,729 3,949
4,871
4,302
9,177
10,290
17,158
-
5,000
10,000
15,000
20,000
TPS(2UpdatesperTransaction)
Update Workload - PostgreSQL 9.6
BASE WAL Compression 16GB Max WAL
Async Reduced Indexes Non Random GUID
Aurora PostgreSQL
Remember those 9 Indexes – Cut it to 6
Test Table
• UUID PK – Random
• ID int – Right Lean Sequence
• VARCHAR(100) – Random
• VARCHAR(50) – Small Set of Words
• INT – Random
• INT – Random (smaller set)
• BOOLEAN – Random (50/50)
• BOOLEAN – Somewhat Random (75/25)
• Timestamp – Right Lean
1-
200
1-
100
101-
200
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
Insert a Constrained Random Value into a B-tree
1-
200
1-
100
101-
200
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
Insert a Constrained Random Value into a B-tree
1-
200
1-
100
101-
200
Insert
172
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
1-
200
101-
200
151-
200
151-
175
4 blocks
loaded
Insert a Constrained Random Value into a B-tree
1-
200
1-
100
101-
200
Insert
172
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
Insert 199
1-
200
101-
200
151-
200
151-
175
4 blocks
loaded
176-
200
1 blocks
loaded
Insert a Constrained Random Value into a B-tree
Insert 161
1-
200
1-
100
101-
200
Insert
172
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
Insert 199
1-
200
101-
200
151-
200
151-
175
4 blocks
loaded
176-
200
1 blocks
loaded
Insert a Constrained Random Value into a B-tree
Insert 161
0 blocks
loaded
1-
200
1-
100
101-
200
Insert
172
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
Insert 199
1-
200
101-
200
151-
200
151-
175
4 blocks
loaded
176-
200
1 blocks
loaded
Insert a Constrained Random Value into a B-tree
Insert 161
0 blocks
loaded
Insert 168
0 blocks
loaded
1-
200
1-
100
101-
200
Insert
172
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
Insert 199
1-
200
101-
200
151-
200
151-
175
4 blocks
loaded
176-
200
1 blocks
loaded
Insert a Constrained Random Value into a B-tree
Insert 161
0 blocks
loaded
Insert 168
0 blocks
loaded At least 2 FPW
Constraining Random Values
Prefix UUID with a date
• 550e8400-e29b-41d4-a716-446655440000
• YYYYMMDDHH24-UUID
• Example
• 2010022712-550e8400-e29b-41d4-a716-446655440000
• 2010022713-550e8400-e29b-41d4-a716-446655440000
• Balance the number of hot blocks vs contention
• More date precision
• less random to b-tree = less blocks touched
• Possibly more contention on the leaf blocks
Change PK to UUID like and remove 3 indexes
Test Table
• UUID PK – Random
• ID int – Right Lean Sequence
• VARCHAR(100) – Random
• VARCHAR(50) – Small Set of Words
• INT – Random
• INT – Random (smaller set)
• BOOLEAN – Random (50/50)
• BOOLEAN – Somewhat Random (75/25)
• Timestamp – Right Lean
Remove Index
Remove Index
Remove Index – Allows HOT Update
Remove Index
Remove Index
Make non random – right lean
0
5,000
10,000
15,000
20,000
25,000
30,000
1 31 61 91 121 151 181 211 241 271
InsertsPerSecond
Minutes
Insert Workload- PostgreSQL 9.6
BASE WAL Compression 16GB Max WAL Reduced Indexes Non Random GUID
3,729 3,949
4,871
4,302
9,177
10,290
17,158
-
5,000
10,000
15,000
20,000
TPS(2UpdatesperTransaction)
Update Workload - PostgreSQL 9.6
BASE WAL Compression 16GB Max WAL
Async Reduced Indexes Non Random GUID
Aurora PostgreSQL
Why Vacuuming Matter
tuple1
tuple2
tuple3
tuple4
tuple5
tuple6
tuple1tuple1
Why Vacuuming Matter
tuple1
tuple2
tuple3
tuple4
tuple5
tuple6
tuple1tuple1
tuple2 tuple2
Why Vacuuming Matter
tuple1
tuple2
tuple3
tuple4
tuple5
tuple6
tuple1tuple1
tuple2 tuple2
tuple7
Why Vacuuming Matter
tuple1
tuple2
tuple3
tuple4
tuple5
tuple6
tuple1tuple1
tuple2 tuple2
tuple7
tuple8
tuple9
tuple10
Why Vacuuming Matter
tuple1
tuple2
tuple3
tuple4
tuple5
tuple6
tuple1tuple1
tuple2 tuple2
tuple7
tuple8
tuple9
tuple10
Run Vacuum
Why Vacuuming Matter
tuple2
tuple3
tuple4
tuple5
tuple6
tuple1tuple1
tuple2 tuple2
tuple7
tuple8
tuple9
tuple10
Run Vacuum
Why Vacuuming Matter
tuple3
tuple4
tuple5
tuple6
tuple1
tuple2
tuple7
tuple8
tuple9
tuple10
Run Vacuum
Why Vacuuming Matter
tuple3
tuple4
tuple5
tuple6
tuple1
tuple2
tuple7
tuple8
tuple9
tuple10
Run Vacuumtuple3
tuple3
Why Vacuuming Matter
tuple3
tuple4
tuple5
tuple6
tuple1
tuple2
tuple7
tuple8
tuple9
tuple10
Run Vacuumtuple3
tuple4
tuple3
tuple4
Why Vacuuming Matter
tuple3
tuple4
tuple5
tuple6
tuple1
tuple2
tuple7
tuple8
tuple9
tuple10
Run Vacuumtuple3
tuple4
tuple3
tuple4
tuple1
tuple2
tuple3
tuple4
tuple5
tuple6
tuple1tuple1
tuple2 tuple2
tuple7
tuple8
tuple9
tuple10
No Vacuum
Why Vacuuming Matter
tuple3
tuple4
tuple5
tuple6
tuple1
tuple2
tuple7
tuple8
tuple9
tuple10
Run Vacuumtuple3
tuple4
tuple3
tuple4
tuple1
tuple2
tuple3
tuple4
tuple5
tuple6
tuple1tuple1
tuple2 tuple2
tuple7
tuple8
tuple9
tuple10
No Vacuumtuple3
tuple3
Why Vacuuming Matter
tuple3
tuple4
tuple5
tuple6
tuple1
tuple2
tuple7
tuple8
tuple9
tuple10
Run Vacuumtuple3
tuple4
tuple3
tuple4
tuple1
tuple2
tuple3
tuple4
tuple5
tuple6
tuple1tuple1
tuple2 tuple2
tuple7
tuple8
tuple9
tuple10
No Vacuumtuple3
tuple4
tuple3
tuple4
Why Vacuuming Matter
tuple3
tuple4
tuple5
tuple6
tuple1
tuple2
tuple7
tuple8
tuple9
tuple10
Run Vacuumtuple3
tuple4
tuple3
tuple4
tuple1
tuple2
tuple3
tuple4
tuple5
tuple6
tuple1tuple1
tuple2 tuple2
tuple7
tuple8
tuple9
tuple10
No Vacuumtuple3
tuple4
tuple3
tuple4
More blocks = More Cache Misses,non HOT updates & more FPW
4,000
5,000
6,000
7,000
8,000
9,000
10,000
1 61 121 181 241 301 361 421 481 541 601 661 721 781 841 901 961 1021 1081 1141 1201 1261
TPS
Minutes
Updates - No Vacuum Running
Vacuuming in Memory – Insert Only Workload
HEAP
PAGES
Vacuuming in Memory – Insert Only Workload
HEAP
PAGES
1-
200
1-
100
101-
200
1-50
51-
100
1-25
26-
50
51-
75
76-
100
101-
150
151-
200
101-
125
126-
150
151-
175
176-
200
1-
201
101-
201
151-
201
176-
201
1-
202
101-
202
151-
202
176-
202
NO LONG RUNNING TRANSACTIONS
Vacuum Freeze in Memory
Block in
Memory
WAL
Vacuum Freeze in Memory
Block in
Memory
WAL
Vacuum Freeze in Memory
Block in
Memory
WAL
Vacuum Freeze in Memory
Block in
Memory
WAL
Vacuum Freeze in Memory
Block in
Memory
WAL
Vacuum Freeze in Memory
Block in
Memory
WAL
Vacuum Freeze in Memory
Block in
Memory
Checkpoint
Datafile
WAL
Archive
Not
Frozen
Vacuum Freeze in Memory
Block in
Memory
Checkpoint
Datafile
WAL
Archive
Not
Frozen
Vacuum Freeze in Memory
Block in
Memory
Checkpoint
Datafile
WAL
Archive
Not
Frozen
VACUUM
Vacuum Freeze in Memory
Block in
Memory
Checkpoint
Datafile
Full
Block
WAL
Archive
Not
Frozen
VACUUM
Vacuum Freeze in Memory
Block in
Memory
WAL
Vacuum Freeze in Memory
Block in
Memory
WAL
Vacuum Freeze in Memory
Block in
Memory
WAL
Vacuum Freeze in Memory
Block in
Memory
Checkpoint
Datafile
WAL
Archive
Frozen
Vacuum in Memory Continued
• Increase checkpoint_timeout
• alter table X set (vacuum settings);
• Manual Test
• Vacuum in Memory before checkpoint – 3.5 seconds
• Vacuum in Memory after checkpoint – 84.5 seconds
• Vacuum not in Memory – 165.8 seconds
Aurora PostgreSQL
Aurora PostgreSQL Differences
• No Checkpoints
• No Full Page Writes (FPW)
• No Log Buffer
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
Queued Work
Storage
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
Queued Work
Storage
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
Queued Work
Storage
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
Queued Work
Storage
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
Queued Work
Storage
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
Queued Work
Storage
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
Queued Work
Storage
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A Queued Work
Storage
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A Queued Work
Storage
B
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B
C
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B C
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B C
D
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B C D
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B C D
E
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B C D E
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B C D E
0 0 0 0 0
A B C D E
Durability
Tracking
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B C D E
0 0 0 0 0
A B C D E
2 2 1 0 1
A B C D E
Durability
Tracking
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B C D E
4 3 4 2 4
A B C D E
Durability
Tracking
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B C D E
4 3 4 2 4
A B C D E
Durability
Tracking
Concurrency
Queued Work
Log Buffer
PostgreSQL Aurora
Storage
A
Queued Work
Storage
B C D E
6 5 6 3 5
A B C D E
Durability
Tracking
Aurora – Writing Less
Block in
Memory
PostgreSQL Aurora
WAL
Block in
Memory
Aurora
Storage
Aurora – Writing Less
Block in
Memory
PostgreSQL Aurora
update t set y = 6;
Full
Block
WAL
Block in
Memory
Aurora
Storage
Aurora – Writing Less
Block in
Memory
PostgreSQL Aurora
update t set y = 6;
Full
Block
WAL
Block in
Memory
Aurora
Storage
Aurora – Writing Less
Block in
Memory
PostgreSQL Aurora
update t set y = 6; update t set y = 6;
Checkpoint
Datafile
Full
Block
WAL
Archive
Block in
Memory
Aurora
Storage
Aurora – Writing Less
Block in
Memory
PostgreSQL Aurora
update t set y = 6; update t set y = 6;
Checkpoint
Datafile
Full
Block
WAL
Archive
Block in
Memory
Aurora
Storage
Aurora – Writing Less
Block in
Memory
PostgreSQL Aurora
update t set y = 6; update t set y = 6;
Checkpoint
Datafile
Full
Block
WAL
Archive
Block in
Memory
Aurora
Storage
Aurora – Writing Less
Block in
Memory
PostgreSQL Aurora
update t set y = 6; update t set y = 6;
Checkpoint
Datafile
Full
Block
WAL
Archive
Block in
Memory
Aurora
Storage
0
5,000
10,000
15,000
20,000
25,000
30,000
1 31 61 91 121 151 181 211 241 271
InsertsPerSecond
Minutes
Insert Workload- PostgreSQL 9.6
BASE WAL Compression 16GB Max WAL
Reduced Indexes Non Random GUID Aurora PostgreSQL
3,729 3,949
4,871
4,302
9,177
10,290
17,158
-
5,000
10,000
15,000
20,000
TPS(2UpdatesperTransaction)
Update Workload - PostgreSQL 9.6
BASE WAL Compression 16GB Max WAL
Async Reduced Indexes Non Random GUID
Aurora PostgreSQL
Thank you!
Questions?

More Related Content

What's hot

2021.02 new in Ceph Pacific Dashboard
2021.02 new in Ceph Pacific Dashboard2021.02 new in Ceph Pacific Dashboard
2021.02 new in Ceph Pacific DashboardCeph Community
 
RocksDB compaction
RocksDB compactionRocksDB compaction
RocksDB compactionMIJIN AN
 
Deep dive into PostgreSQL statistics.
Deep dive into PostgreSQL statistics.Deep dive into PostgreSQL statistics.
Deep dive into PostgreSQL statistics.Alexey Lesovsky
 
The Linux Block Layer - Built for Fast Storage
The Linux Block Layer - Built for Fast StorageThe Linux Block Layer - Built for Fast Storage
The Linux Block Layer - Built for Fast StorageKernel TLV
 
ceph optimization on ssd ilsoo byun-short
ceph optimization on ssd ilsoo byun-shortceph optimization on ssd ilsoo byun-short
ceph optimization on ssd ilsoo byun-shortNAVER D2
 
Oracle Latch and Mutex Contention Troubleshooting
Oracle Latch and Mutex Contention TroubleshootingOracle Latch and Mutex Contention Troubleshooting
Oracle Latch and Mutex Contention TroubleshootingTanel Poder
 
PostgreSQL Deep Internal
PostgreSQL Deep InternalPostgreSQL Deep Internal
PostgreSQL Deep InternalEXEM
 
BlueStore: a new, faster storage backend for Ceph
BlueStore: a new, faster storage backend for CephBlueStore: a new, faster storage backend for Ceph
BlueStore: a new, faster storage backend for CephSage Weil
 
Technical Introduction to PostgreSQL and PPAS
Technical Introduction to PostgreSQL and PPASTechnical Introduction to PostgreSQL and PPAS
Technical Introduction to PostgreSQL and PPASAshnikbiz
 
PostgreSQL on EXT4, XFS, BTRFS and ZFS
PostgreSQL on EXT4, XFS, BTRFS and ZFSPostgreSQL on EXT4, XFS, BTRFS and ZFS
PostgreSQL on EXT4, XFS, BTRFS and ZFSTomas Vondra
 
High Availability PostgreSQL with Zalando Patroni
High Availability PostgreSQL with Zalando PatroniHigh Availability PostgreSQL with Zalando Patroni
High Availability PostgreSQL with Zalando PatroniZalando Technology
 
ProxySQL - High Performance and HA Proxy for MySQL
ProxySQL - High Performance and HA Proxy for MySQLProxySQL - High Performance and HA Proxy for MySQL
ProxySQL - High Performance and HA Proxy for MySQLRené Cannaò
 
Patroni - HA PostgreSQL made easy
Patroni - HA PostgreSQL made easyPatroni - HA PostgreSQL made easy
Patroni - HA PostgreSQL made easyAlexander Kukushkin
 
Tech Talk: RocksDB Slides by Dhruba Borthakur & Haobo Xu of Facebook
Tech Talk: RocksDB Slides by Dhruba Borthakur & Haobo Xu of FacebookTech Talk: RocksDB Slides by Dhruba Borthakur & Haobo Xu of Facebook
Tech Talk: RocksDB Slides by Dhruba Borthakur & Haobo Xu of FacebookThe Hive
 
Ceph: Open Source Storage Software Optimizations on Intel® Architecture for C...
Ceph: Open Source Storage Software Optimizations on Intel® Architecture for C...Ceph: Open Source Storage Software Optimizations on Intel® Architecture for C...
Ceph: Open Source Storage Software Optimizations on Intel® Architecture for C...Odinot Stanislas
 
Basic and Advanced Analysis of Ceph Volume Backend Driver in Cinder - John Haan
Basic and Advanced Analysis of Ceph Volume Backend Driver in Cinder - John HaanBasic and Advanced Analysis of Ceph Volume Backend Driver in Cinder - John Haan
Basic and Advanced Analysis of Ceph Volume Backend Driver in Cinder - John HaanCeph Community
 
BlueStore, A New Storage Backend for Ceph, One Year In
BlueStore, A New Storage Backend for Ceph, One Year InBlueStore, A New Storage Backend for Ceph, One Year In
BlueStore, A New Storage Backend for Ceph, One Year InSage Weil
 

What's hot (20)

2021.02 new in Ceph Pacific Dashboard
2021.02 new in Ceph Pacific Dashboard2021.02 new in Ceph Pacific Dashboard
2021.02 new in Ceph Pacific Dashboard
 
RocksDB compaction
RocksDB compactionRocksDB compaction
RocksDB compaction
 
Deep dive into PostgreSQL statistics.
Deep dive into PostgreSQL statistics.Deep dive into PostgreSQL statistics.
Deep dive into PostgreSQL statistics.
 
The Linux Block Layer - Built for Fast Storage
The Linux Block Layer - Built for Fast StorageThe Linux Block Layer - Built for Fast Storage
The Linux Block Layer - Built for Fast Storage
 
ceph optimization on ssd ilsoo byun-short
ceph optimization on ssd ilsoo byun-shortceph optimization on ssd ilsoo byun-short
ceph optimization on ssd ilsoo byun-short
 
Oracle Latch and Mutex Contention Troubleshooting
Oracle Latch and Mutex Contention TroubleshootingOracle Latch and Mutex Contention Troubleshooting
Oracle Latch and Mutex Contention Troubleshooting
 
PostgreSQL Deep Internal
PostgreSQL Deep InternalPostgreSQL Deep Internal
PostgreSQL Deep Internal
 
BlueStore: a new, faster storage backend for Ceph
BlueStore: a new, faster storage backend for CephBlueStore: a new, faster storage backend for Ceph
BlueStore: a new, faster storage backend for Ceph
 
MyRocks Deep Dive
MyRocks Deep DiveMyRocks Deep Dive
MyRocks Deep Dive
 
Technical Introduction to PostgreSQL and PPAS
Technical Introduction to PostgreSQL and PPASTechnical Introduction to PostgreSQL and PPAS
Technical Introduction to PostgreSQL and PPAS
 
PostgreSQL on EXT4, XFS, BTRFS and ZFS
PostgreSQL on EXT4, XFS, BTRFS and ZFSPostgreSQL on EXT4, XFS, BTRFS and ZFS
PostgreSQL on EXT4, XFS, BTRFS and ZFS
 
High Availability PostgreSQL with Zalando Patroni
High Availability PostgreSQL with Zalando PatroniHigh Availability PostgreSQL with Zalando Patroni
High Availability PostgreSQL with Zalando Patroni
 
ProxySQL - High Performance and HA Proxy for MySQL
ProxySQL - High Performance and HA Proxy for MySQLProxySQL - High Performance and HA Proxy for MySQL
ProxySQL - High Performance and HA Proxy for MySQL
 
Patroni - HA PostgreSQL made easy
Patroni - HA PostgreSQL made easyPatroni - HA PostgreSQL made easy
Patroni - HA PostgreSQL made easy
 
Tech Talk: RocksDB Slides by Dhruba Borthakur & Haobo Xu of Facebook
Tech Talk: RocksDB Slides by Dhruba Borthakur & Haobo Xu of FacebookTech Talk: RocksDB Slides by Dhruba Borthakur & Haobo Xu of Facebook
Tech Talk: RocksDB Slides by Dhruba Borthakur & Haobo Xu of Facebook
 
Ceph: Open Source Storage Software Optimizations on Intel® Architecture for C...
Ceph: Open Source Storage Software Optimizations on Intel® Architecture for C...Ceph: Open Source Storage Software Optimizations on Intel® Architecture for C...
Ceph: Open Source Storage Software Optimizations on Intel® Architecture for C...
 
Ceph issue 해결 사례
Ceph issue 해결 사례Ceph issue 해결 사례
Ceph issue 해결 사례
 
Basic and Advanced Analysis of Ceph Volume Backend Driver in Cinder - John Haan
Basic and Advanced Analysis of Ceph Volume Backend Driver in Cinder - John HaanBasic and Advanced Analysis of Ceph Volume Backend Driver in Cinder - John Haan
Basic and Advanced Analysis of Ceph Volume Backend Driver in Cinder - John Haan
 
PostgreSQL Replication Tutorial
PostgreSQL Replication TutorialPostgreSQL Replication Tutorial
PostgreSQL Replication Tutorial
 
BlueStore, A New Storage Backend for Ceph, One Year In
BlueStore, A New Storage Backend for Ceph, One Year InBlueStore, A New Storage Backend for Ceph, One Year In
BlueStore, A New Storage Backend for Ceph, One Year In
 

Similar to Tuning PostgreSQL for High Write Throughput

Oracle goldengate 11g schema replication from standby database
Oracle goldengate 11g schema replication from standby databaseOracle goldengate 11g schema replication from standby database
Oracle goldengate 11g schema replication from standby databaseuzzal basak
 
Wait Events 10g
Wait Events 10gWait Events 10g
Wait Events 10gsagai
 
Ash masters : advanced ash analytics on Oracle
Ash masters : advanced ash analytics on Oracle Ash masters : advanced ash analytics on Oracle
Ash masters : advanced ash analytics on Oracle Kyle Hailey
 
Aplicações 10x a 100x mais rápida com o postgre sql
Aplicações 10x a 100x mais rápida com o postgre sqlAplicações 10x a 100x mais rápida com o postgre sql
Aplicações 10x a 100x mais rápida com o postgre sqlFabio Telles Rodriguez
 
11 Things About11g
11 Things About11g11 Things About11g
11 Things About11gfcamachob
 
11thingsabout11g 12659705398222 Phpapp01
11thingsabout11g 12659705398222 Phpapp0111thingsabout11g 12659705398222 Phpapp01
11thingsabout11g 12659705398222 Phpapp01Karam Abuataya
 
TechEvent Performance Analyses on Standby Database
TechEvent Performance Analyses on Standby DatabaseTechEvent Performance Analyses on Standby Database
TechEvent Performance Analyses on Standby DatabaseTrivadis
 
Oracle Basics and Architecture
Oracle Basics and ArchitectureOracle Basics and Architecture
Oracle Basics and ArchitectureSidney Chen
 
Hp dv6 7000 goya balen 11254-3
Hp dv6 7000 goya balen 11254-3Hp dv6 7000 goya balen 11254-3
Hp dv6 7000 goya balen 11254-3JosPinaya
 
还原Oracle中真实的cache recovery
还原Oracle中真实的cache recovery还原Oracle中真实的cache recovery
还原Oracle中真实的cache recoverymaclean liu
 
The_ERICSSON_commands_listed_below_are_f (1) (1).pdf
The_ERICSSON_commands_listed_below_are_f (1) (1).pdfThe_ERICSSON_commands_listed_below_are_f (1) (1).pdf
The_ERICSSON_commands_listed_below_are_f (1) (1).pdfssuser340a0c
 
Redo logfile addition in oracle rac 12c
Redo logfile addition in oracle rac 12cRedo logfile addition in oracle rac 12c
Redo logfile addition in oracle rac 12cDebasish Nayak
 
Blackfin Loop Asm
Blackfin Loop AsmBlackfin Loop Asm
Blackfin Loop AsmAdithya Rao
 
Pushover analysis-sacs
Pushover analysis-sacsPushover analysis-sacs
Pushover analysis-sacsHoàng Bkaero
 
Vlsi ii project presentation
Vlsi ii project presentationVlsi ii project presentation
Vlsi ii project presentationRedwan Islam
 

Similar to Tuning PostgreSQL for High Write Throughput (20)

Oracle goldengate 11g schema replication from standby database
Oracle goldengate 11g schema replication from standby databaseOracle goldengate 11g schema replication from standby database
Oracle goldengate 11g schema replication from standby database
 
Beginbackup
BeginbackupBeginbackup
Beginbackup
 
Wait Events 10g
Wait Events 10gWait Events 10g
Wait Events 10g
 
Ash masters : advanced ash analytics on Oracle
Ash masters : advanced ash analytics on Oracle Ash masters : advanced ash analytics on Oracle
Ash masters : advanced ash analytics on Oracle
 
Aplicações 10x a 100x mais rápida com o postgre sql
Aplicações 10x a 100x mais rápida com o postgre sqlAplicações 10x a 100x mais rápida com o postgre sql
Aplicações 10x a 100x mais rápida com o postgre sql
 
The propeller
The propellerThe propeller
The propeller
 
Performance Risk Management
Performance Risk ManagementPerformance Risk Management
Performance Risk Management
 
11 Things About11g
11 Things About11g11 Things About11g
11 Things About11g
 
11thingsabout11g 12659705398222 Phpapp01
11thingsabout11g 12659705398222 Phpapp0111thingsabout11g 12659705398222 Phpapp01
11thingsabout11g 12659705398222 Phpapp01
 
TechEvent Performance Analyses on Standby Database
TechEvent Performance Analyses on Standby DatabaseTechEvent Performance Analyses on Standby Database
TechEvent Performance Analyses on Standby Database
 
Rmoug ashmaster
Rmoug ashmasterRmoug ashmaster
Rmoug ashmaster
 
Oracle Basics and Architecture
Oracle Basics and ArchitectureOracle Basics and Architecture
Oracle Basics and Architecture
 
Hp dv6 7000 goya balen 11254-3
Hp dv6 7000 goya balen 11254-3Hp dv6 7000 goya balen 11254-3
Hp dv6 7000 goya balen 11254-3
 
还原Oracle中真实的cache recovery
还原Oracle中真实的cache recovery还原Oracle中真实的cache recovery
还原Oracle中真实的cache recovery
 
The_ERICSSON_commands_listed_below_are_f (1) (1).pdf
The_ERICSSON_commands_listed_below_are_f (1) (1).pdfThe_ERICSSON_commands_listed_below_are_f (1) (1).pdf
The_ERICSSON_commands_listed_below_are_f (1) (1).pdf
 
PL/SQL
PL/SQLPL/SQL
PL/SQL
 
Redo logfile addition in oracle rac 12c
Redo logfile addition in oracle rac 12cRedo logfile addition in oracle rac 12c
Redo logfile addition in oracle rac 12c
 
Blackfin Loop Asm
Blackfin Loop AsmBlackfin Loop Asm
Blackfin Loop Asm
 
Pushover analysis-sacs
Pushover analysis-sacsPushover analysis-sacs
Pushover analysis-sacs
 
Vlsi ii project presentation
Vlsi ii project presentationVlsi ii project presentation
Vlsi ii project presentation
 

More from Grant McAlister

Practical Memory Tuning for PostgreSQL
Practical Memory Tuning for PostgreSQLPractical Memory Tuning for PostgreSQL
Practical Memory Tuning for PostgreSQLGrant McAlister
 
re:Invent 2022 DAT326 Deep dive into Amazon Aurora and its innovations
re:Invent 2022  DAT326 Deep dive into Amazon Aurora and its innovationsre:Invent 2022  DAT326 Deep dive into Amazon Aurora and its innovations
re:Invent 2022 DAT326 Deep dive into Amazon Aurora and its innovationsGrant McAlister
 
re:Invent 2022 DAT316 Build resilient applications using Amazon RDS and Auror...
re:Invent 2022 DAT316 Build resilient applications using Amazon RDS and Auror...re:Invent 2022 DAT316 Build resilient applications using Amazon RDS and Auror...
re:Invent 2022 DAT316 Build resilient applications using Amazon RDS and Auror...Grant McAlister
 
re:Invent 2020 DAT301 Deep Dive on Amazon Aurora with PostgreSQL Compatibility
re:Invent 2020 DAT301 Deep Dive on Amazon Aurora with PostgreSQL Compatibilityre:Invent 2020 DAT301 Deep Dive on Amazon Aurora with PostgreSQL Compatibility
re:Invent 2020 DAT301 Deep Dive on Amazon Aurora with PostgreSQL CompatibilityGrant McAlister
 
AWS re:Invent 2019 - DAT328 Deep Dive on Amazon Aurora PostgreSQL
AWS re:Invent 2019 - DAT328 Deep Dive on Amazon Aurora PostgreSQLAWS re:Invent 2019 - DAT328 Deep Dive on Amazon Aurora PostgreSQL
AWS re:Invent 2019 - DAT328 Deep Dive on Amazon Aurora PostgreSQLGrant McAlister
 
Dat305 Deep Dive on Amazon Aurora PostgreSQL
Dat305 Deep Dive on Amazon Aurora PostgreSQLDat305 Deep Dive on Amazon Aurora PostgreSQL
Dat305 Deep Dive on Amazon Aurora PostgreSQLGrant McAlister
 
HOT Understanding this important update optimization
HOT Understanding this important update optimizationHOT Understanding this important update optimization
HOT Understanding this important update optimizationGrant McAlister
 
DAT402 - Deep Dive on Amazon Aurora PostgreSQL
DAT402 - Deep Dive on Amazon Aurora PostgreSQL DAT402 - Deep Dive on Amazon Aurora PostgreSQL
DAT402 - Deep Dive on Amazon Aurora PostgreSQL Grant McAlister
 
Deep dive into the Rds PostgreSQL Universe Austin 2017
Deep dive into the Rds PostgreSQL Universe Austin 2017Deep dive into the Rds PostgreSQL Universe Austin 2017
Deep dive into the Rds PostgreSQL Universe Austin 2017Grant McAlister
 
Amazon RDS for PostgreSQL: What's New and Lessons Learned - NY 2017
Amazon RDS for PostgreSQL: What's New and Lessons Learned - NY 2017Amazon RDS for PostgreSQL: What's New and Lessons Learned - NY 2017
Amazon RDS for PostgreSQL: What's New and Lessons Learned - NY 2017Grant McAlister
 
Amazon RDS for PostgreSQL - Postgres Open 2016 - New Features and Lessons Lea...
Amazon RDS for PostgreSQL - Postgres Open 2016 - New Features and Lessons Lea...Amazon RDS for PostgreSQL - Postgres Open 2016 - New Features and Lessons Lea...
Amazon RDS for PostgreSQL - Postgres Open 2016 - New Features and Lessons Lea...Grant McAlister
 
Amazon RDS for PostgreSQL - PGConf 2016
Amazon RDS for PostgreSQL - PGConf 2016 Amazon RDS for PostgreSQL - PGConf 2016
Amazon RDS for PostgreSQL - PGConf 2016 Grant McAlister
 

More from Grant McAlister (12)

Practical Memory Tuning for PostgreSQL
Practical Memory Tuning for PostgreSQLPractical Memory Tuning for PostgreSQL
Practical Memory Tuning for PostgreSQL
 
re:Invent 2022 DAT326 Deep dive into Amazon Aurora and its innovations
re:Invent 2022  DAT326 Deep dive into Amazon Aurora and its innovationsre:Invent 2022  DAT326 Deep dive into Amazon Aurora and its innovations
re:Invent 2022 DAT326 Deep dive into Amazon Aurora and its innovations
 
re:Invent 2022 DAT316 Build resilient applications using Amazon RDS and Auror...
re:Invent 2022 DAT316 Build resilient applications using Amazon RDS and Auror...re:Invent 2022 DAT316 Build resilient applications using Amazon RDS and Auror...
re:Invent 2022 DAT316 Build resilient applications using Amazon RDS and Auror...
 
re:Invent 2020 DAT301 Deep Dive on Amazon Aurora with PostgreSQL Compatibility
re:Invent 2020 DAT301 Deep Dive on Amazon Aurora with PostgreSQL Compatibilityre:Invent 2020 DAT301 Deep Dive on Amazon Aurora with PostgreSQL Compatibility
re:Invent 2020 DAT301 Deep Dive on Amazon Aurora with PostgreSQL Compatibility
 
AWS re:Invent 2019 - DAT328 Deep Dive on Amazon Aurora PostgreSQL
AWS re:Invent 2019 - DAT328 Deep Dive on Amazon Aurora PostgreSQLAWS re:Invent 2019 - DAT328 Deep Dive on Amazon Aurora PostgreSQL
AWS re:Invent 2019 - DAT328 Deep Dive on Amazon Aurora PostgreSQL
 
Dat305 Deep Dive on Amazon Aurora PostgreSQL
Dat305 Deep Dive on Amazon Aurora PostgreSQLDat305 Deep Dive on Amazon Aurora PostgreSQL
Dat305 Deep Dive on Amazon Aurora PostgreSQL
 
HOT Understanding this important update optimization
HOT Understanding this important update optimizationHOT Understanding this important update optimization
HOT Understanding this important update optimization
 
DAT402 - Deep Dive on Amazon Aurora PostgreSQL
DAT402 - Deep Dive on Amazon Aurora PostgreSQL DAT402 - Deep Dive on Amazon Aurora PostgreSQL
DAT402 - Deep Dive on Amazon Aurora PostgreSQL
 
Deep dive into the Rds PostgreSQL Universe Austin 2017
Deep dive into the Rds PostgreSQL Universe Austin 2017Deep dive into the Rds PostgreSQL Universe Austin 2017
Deep dive into the Rds PostgreSQL Universe Austin 2017
 
Amazon RDS for PostgreSQL: What's New and Lessons Learned - NY 2017
Amazon RDS for PostgreSQL: What's New and Lessons Learned - NY 2017Amazon RDS for PostgreSQL: What's New and Lessons Learned - NY 2017
Amazon RDS for PostgreSQL: What's New and Lessons Learned - NY 2017
 
Amazon RDS for PostgreSQL - Postgres Open 2016 - New Features and Lessons Lea...
Amazon RDS for PostgreSQL - Postgres Open 2016 - New Features and Lessons Lea...Amazon RDS for PostgreSQL - Postgres Open 2016 - New Features and Lessons Lea...
Amazon RDS for PostgreSQL - Postgres Open 2016 - New Features and Lessons Lea...
 
Amazon RDS for PostgreSQL - PGConf 2016
Amazon RDS for PostgreSQL - PGConf 2016 Amazon RDS for PostgreSQL - PGConf 2016
Amazon RDS for PostgreSQL - PGConf 2016
 

Recently uploaded

Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Manik S Magar
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfPrecisely
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxNavinnSomaal
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clashcharlottematthew16
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 

Recently uploaded (20)

Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptx
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clash
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 

Tuning PostgreSQL for High Write Throughput

Editor's Notes

  1. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  2. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  3. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  4. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  5. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  6. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  7. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  8. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  9. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  10. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  11. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  12. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  13. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  14. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  15. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  16. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  17. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  18. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  19. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  20. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  21. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  22. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  23. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  24. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  25. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  26. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  27. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  28. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  29. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  30. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  31. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  32. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  33. Quorum system for read/write; latency tolerant Quorum membership changes do not stall writes
  34. Ask about preview environment and other decoders