Re: postgres in swap space
Bruce Momjian <bruce@momjian.us>
From: Bruce Momjian <bruce@momjian.us>
To: Laurenz Albe <laurenz.albe@cybertec.at>
Cc: Marc Millas <marc.millas@mokadb.com>, "pgsql-general@lists.postgresql.org" <pgsql-general@lists.postgresql.org>
Date: 2025-11-18T03:07:30Z
Lists: pgsql-general
On Mon, Nov 17, 2025 at 09:49:59PM +0100, Laurenz Albe wrote: > On Mon, 2025-11-17 at 18:25 +0100, Marc Millas wrote: > > Can someone point me to any doc describing why and how much space postgres uses on the swap of a debian machine ? > > it's an old postgres 10, because it is used by a product for which only this version is certified. > > (no comment on that, please) > > I'm biting down a comment. > > PostgreSQL itself doesn't use any swap space. > > The kernel can decide to swap out memory used by PostgreSQL. How much that is depends > on how you configured the Linux kernel and how much memory PostgreSQL uses. The latter > is mostly determined by "shared_buffers", "work_mem", "maintenance_work_mem" and > "max_connections". I wrote a blog entry about swap space: https://momjian.us/main/blogs/pgblog/2012.html#July_25_2012 -- Bruce Momjian <bruce@momjian.us> https://momjian.us EDB https://enterprisedb.com Do not let urgent matters crowd out time for investment in the future.