Work_mem: It's a Trap
https://mydbanotebook.org/posts/work_mem-its-a-trap/
#HackerNews #Work_mem #Database #Performance #Optimization #Memory #Management
work_mem: it's a trap! | My DBA Notebook
My friend Henrietta Dombrovskaya pinged me on Telegram. Her production cluster had just been killed by the OOM killer after eating 2 TB of RAM. work_mem was set to 2 MB. Something didn’t add up. Hetty, like me, likes playing with monster hardware. 2 TB of RAM is not unusual in her world. But losing the whole cluster to a single query during peak operations is a very different kind of problem from a 3am outage.
