Re: Pre-allocation of shared memory ...

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Pre-allocation of shared memory ...
Date: 2003-06-12 16:46:39
Message-ID: 200306121646.h5CGkdQ10035@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Well, let's see what feedback we get.

---------------------------------------------------------------------------

Andrew Dunstan wrote:
>
> A couple of points:
>
> . It is probably a good idea to put do this via /etc/sysctl.conf, which will
> be called earlyish by init scripts (on RH9 it is in the network startup
> file, for some reason).
>
> . The setting is not available on all kernel versions AFAIK. The admin needs
> to check the docs. I have no idea when this went into the kernel, and no
> time to spend finding out. Even if we knew, it might have gone into vendor
> kernels at other odd times - there are often times when the vendors are in
> advance of the officially released kernels.
>
> Andrew
>
>
> Bruce wrote:
> >
> > OK, new text is:
> >
> > <para>
> > Linux has poor default memory overcommit behavior. Rather than
> > failing if it can not reserve enough memory, it returns success,
> > but later fails when the memory can't be mapped and terminates
> > the application with <literal>kill -9</>. To prevent
> > unpredictable process termination, use:
> > <programlisting>
> > sysctl -w vm.overcommit_memory=3
> > </programlisting>
> > Note, you will need enough swap space to cover all your memory
> > needs.
> > </para>
> > </listitem>
> > </varlistentry>
> >
> > ---------------------------------------------------------------------------
> >
> > Tom Lane wrote:
> >> Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> >> > OK, doc patch attached and applied. Improvements?
> >>
> >> I think it would be worth spending another sentence to tell people
> >> exactly what the symptom looks like, ie, backends dying with signal 9.
> >>
> >> regards, tom lane
> >>
> >
> > --
> > Bruce Momjian | http://candle.pha.pa.us
> > pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
> > + If your life is a hard drive, | 13 Roberts Road
> > + Christ can be your backup. | Newtown Square, Pennsylvania
> > 19073
> >
> > ---------------------------(end of
> > broadcast)--------------------------- TIP 2: you can get off all lists
> > at once with the unregister command
> > (send "unregister YourEmailAddressHere" to majordomo(at)postgresql(dot)org)
>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
>

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Dennis Gearon 2003-06-12 16:58:49 Re: [HACKERS] SAP and MySQL ... [and Benchmark]
Previous Message Dennis Björklund 2003-06-12 16:33:57 Re: Alter strings that don't belong to the application