Re: Suggested swap size for new db?
От | Scott Marlowe |
---|---|
Тема | Re: Suggested swap size for new db? |
Дата | |
Msg-id | AANLkTi=+EQ0XKmby5RcVrPCEkJZr4o0dO+haA9qSB6YD@mail.gmail.com обсуждение исходный текст |
Ответ на | Suggested swap size for new db? ("Evan D. Hoffman" <evandhoffman@gmail.com>) |
Список | pgsql-general |
On Sun, Nov 14, 2010 at 8:34 PM, Evan D. Hoffman <evandhoffman@gmail.com> wrote: > I'm planning to migrate our pg db to a new machine in the next couple > of weeks. The current DB has 32 GB memory; the new one will have 96 > GB. It's going to be Postgres 8.2.x (we're planning to upgrade to 8.4 > as part of another project) running on CentOS 5.4 or 5.5. I know the > old rule of thumb that your swap partition/disk should be equal to the > physical memory, but when dealing with memory sizes greater than ~16 > GB that starts to seem strange to me; and now with 96 GB of physical > memory I'm starting to wonder if I'd be better off forgoing swap > altogether for the new database. My servers were setup with something like 16G of swap on a machine with 128G ram. After runnig for about a month of heavy work, kswapd decided to start thrashing the system for no apparent reason, and would not stop. The fix was sudo swapoff -a. As soon as kswapd had swapped everything back in the server returned to normal. Now, swapoff -a is the last line in my /etc/rc.local on both machines. Running Ubuntu 10.04 64 bit btw. Note that at the time of this happening I had 90+G of kernel cache, and nothing NEEDED to be swapped out. the linux kernel, and virtual memory, with a machine with lots of memory, has some rather odd behaviour, and I don't really need swap on these machines.
В списке pgsql-general по дате отправления: