Phil Eaton

EDB Staff Engineer

Phil Eaton is a Staff Engineer at EDB; contributing to EDB's highly available Postgres offering, Postgres Distributed. In the past 10 years he's been a developer, a manager, and a cofounder at infrastructure companies. Outside of work he runs the NYC Systems talk series, the Software Internals Discord, the NYC Systems Coffee Club, the /r/databasedevelopment subreddit, and various technical book clubs.

Read Blogs

Technical Blog
Log in or register for a free EDB account and grab your subscription token. Export it in your environment: $ export EDB_SUBSCRIPTION_TOKEN=whatever-it-is Now set up repositories for EDB Postgres Distributed (PGD) and EDB Postgres Extended (EDB's distribution of Postgres). $ curl -1sLf "https://downloads.enterprisedb.com/$EDB_SUBSCRIPTION_TOKEN/postgres_distributed/setup.deb.sh" | sudo -E bash $...
Technical Blog
If Postgres crashes you can get a stack trace with gdb. But how do you debug errors that don't crash Postgres? Let's grab the Postgres 17 source and build it with debug symbols. $ git clone https://github.com/postgres/postgres $ cd postgres $ git checkout REL_17_STABLE $ ./configure --enable-debug --without-icu \ --prefix=$(pwd)/build \ --libdir=$(pwd)/build/lib $ make -j16 && make install Create...
Technical Blog
I've been talking about debugging memory leaks for more than a year now; covering Valgrind, AdressSanitizer, memleak, and heaptrack. But there are still a few more tools to explore 1 and today we're going to look at jemalloc, the alternative malloc implementation from 2 Meta. Alternative malloc implementations are popular and practical. Google has tcmalloc, Microsoft has mimalloc, and Meta has...
Technical Blog
In this post we'll introduce two memory leaks into Postgres and debug them with heaptrack. Like almost every memory leak tool available to us (including memleak which I wrote about last time), heaptrack requires you to be on Linux. But a Linux VM on a Mac is fine too (that is where I'm running this code from). Although we use Postgres as the codebase with which to explore tools like memleak (last...
Technical Blog
In this post we'll set up a 3-node EDB Postgres Distributed (PGD) cluster running community Postgres 16. Then we'll upgrade the entire cluster in place from Postgres 16 to Postgres 17. We'll demonstrate that even while bringing individual nodes down for the major version upgrade, the cluster overall will remain available for reads and writes. There may be nuances to your particular environment...
EDB Labs
The latest generation of programming languages (Rust, Go, Zig) come bundled not just with a standard library but with a suite of first-party tools for working with the code itself (e.g. cargo fmt, gofmt, zig fmt, etc.). But I suspect that some future generation of (statically typed) programming languages will also come with a first-party embedded scripting language to make it easier to write tests...
EDB Labs
In this post we'll explore the basics of logical replication between two Postgres databases as both a user and a developer. Postgres first implemented physical replication where it shipped bytes on disk from one database A to another database B. Database B would write those bytes right back to disk. But this physical replication limits you to replicating between Postgres instances running the same Postgres version and on the same CPU architecture (and likely other operating system settings like page size).
EDB Labs
Postgres manages memory through nested arenas called MemoryContexts. MemoryContexts are convenient because, for the most part, you don't need to worry about explicitly freeing memory because memory allocated within the context will be freed when the context is freed. So the next two things you worry about, things that took me a while to understand, are 1) in which MemoryContext should some...
EDB Labs
Learn how EDB Postgres Distributed improves logical replication for seamless upgrades, high availability, and optimized DML performance in PostgreSQL clusters.
EDB Labs
You’re looking for production-grade Postgres. You need to keep multiple copies of your data around for high-availability. And this data must stay consistent across the copies. You need to handle rolling upgrades of the cluster. You need to handle taking a node out of the cluster for maintenance. You need to handle DDL changes across nodes in the cluster. And we might be getting ahead of ourselves, but you may also need low-latency read replicas or even need to geo-distribute your data while adhering to data governance policies.