Database has been killed after increasing memory

Started by kolszew73@gmail.comover 12 years ago3 messagesgeneral
Jump to latest
#1kolszew73@gmail.com
kolszew73@gmail.com

Hi

I Have problem with "postmaster" processes which unexpectedly consume very
big amount of memory, about 200MB!!!, and as a consequence whole available
memory in Linux, and as a consequence Linux kills postmasters processes :(

my configuration:
8 Core
8 GB RAM
max_connections = 60
work_mem = 32MB
shared_buffers = 2G

After an investigation, I suspect, than some of my queries which contains
many INNER JOIN's (about 30, and one of them about 60) probably causes
memory problem.

What are postgres limitations about JOINS in one query?
How can I estimate memory needed for postgres?
How can I protect my postgres server, when i don't know exactly how
complicated queries creates my customer, e.g. in reports?

--
View this message in context: http://postgresql.1045698.n5.nabble.com/Database-has-been-killed-after-increasing-memory-tp5784404.html
Sent from the PostgreSQL - pgadmin support mailing list archive at Nabble.com.

--
Sent via pgadmin-support mailing list (pgadmin-support@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-support

#2Dinesh Kumar
dinesh.kumar@enterprisedb.com
In reply to: kolszew73@gmail.com (#1)
Re: [pgadmin-support] Database has been killed after increasing memory

Hi,

+Adding postgresql general list. Hope, some one will provide more
information.

On Mon, Dec 23, 2013 at 1:56 PM, kolszew73@gmail.com <kolszew73@gmail.com>wrote:

Hi

I Have problem with "postmaster" processes which unexpectedly consume very
big amount of memory, about 200MB!!!, and as a consequence whole available
memory in Linux, and as a consequence Linux kills postmasters processes :(

my configuration:
8 Core
8 GB RAM
max_connections = 60
work_mem = 32MB
shared_buffers = 2G

After an investigation, I suspect, than some of my queries which contains
many INNER JOIN's (about 30, and one of them about 60) probably causes
memory problem.

What are postgres limitations about JOINS in one query?
How can I estimate memory needed for postgres?

Using EXPLAIN ANALYZE BUFFERS

How can I protect my postgres server, when i don't know exactly how
complicated queries creates my customer, e.g. in reports?

Using pgbadger/pgfounie tools, you will get the detailed statistical report.

Regards,
Dinesh

Show quoted text

--
View this message in context:
http://postgresql.1045698.n5.nabble.com/Database-has-been-killed-after-increasing-memory-tp5784404.html
Sent from the PostgreSQL - pgadmin support mailing list archive at
Nabble.com.

--
Sent via pgadmin-support mailing list (pgadmin-support@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-support

#3Dinesh Kumar
dinesh.kumar@enterprisedb.com
In reply to: kolszew73@gmail.com (#1)
Re: [pgadmin-support] Database has been killed after increasing memory

+Adding postgres general

Hi,

On Mon, Dec 23, 2013 at 9:34 PM, Krzysztof Olszewski <kolszew73@gmail.com>wrote:

Hi

thanx for your answer

"Using EXPLAIN ANALYZE BUFFERS"
how it helps me with "How can I estimate memory needed for postgres" ?

Using this information, i believe we can estimate the memory usage of a
query.

Explain Analyze
Buffers<http://www.postgresql.org/docs/9.1/static/sql-explain.html&gt;
<http://dalibo.github.io/pgbadger/samplev4.html&gt;

"Using pgbadger/pgfounie"
how it helps me with "How can I protect my postgres server, when i don't
know exactly ..." ?

By configuring the required log information on the server level, we can

get the complete statistics information using pgbadger. Find the sample
here.
pgbadger report <http://dalibo.github.io/pgbadger/samplev4.html&gt;

Thanks,
Dinesh

Show quoted text

2013/12/23 Dinesh Kumar <dinesh.kumar@enterprisedb.com>

Hi,

+Adding postgresql general list. Hope, some one will provide more
information.

On Mon, Dec 23, 2013 at 1:56 PM, kolszew73@gmail.com <kolszew73@gmail.com

wrote:

Hi

I Have problem with "postmaster" processes which unexpectedly consume
very
big amount of memory, about 200MB!!!, and as a consequence whole
available
memory in Linux, and as a consequence Linux kills postmasters processes
:(

my configuration:
8 Core
8 GB RAM
max_connections = 60
work_mem = 32MB
shared_buffers = 2G

After an investigation, I suspect, than some of my queries which contains
many INNER JOIN's (about 30, and one of them about 60) probably causes
memory problem.

What are postgres limitations about JOINS in one query?
How can I estimate memory needed for postgres?

Using EXPLAIN ANALYZE BUFFERS

How can I protect my postgres server, when i don't know exactly how
complicated queries creates my customer, e.g. in reports?

Using pgbadger/pgfounie tools, you will get the detailed statistical
report.

Regards,
Dinesh

--
View this message in context:
http://postgresql.1045698.n5.nabble.com/Database-has-been-killed-after-increasing-memory-tp5784404.html
Sent from the PostgreSQL - pgadmin support mailing list archive at
Nabble.com.

--
Sent via pgadmin-support mailing list (pgadmin-support@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-support