pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: jaime soler gómez <jsoler@hoplasoftware.com>
To: Thorsten Schöning <tschoening@am-soft.de>
To: pgsql-admin <pgsql-admin@postgresql.org>
Subject: Re: Per thread Connection memory
Date: Mon, 01 Feb 2016 12:23:01 +0100
Message-ID: <1454325781.5847.84.camel@hoplasoftware.com> (raw)
In-Reply-To: <34973063.20160129141840@am-soft.de>
References: <CALXoLqxVbxJy8DKqmACkyE_UFZpuL0L38102S-vM+6=eQ+FHng@mail.gmail.com>
	<CAFe9ZTqe3_SqnCYbWhQe9Ve+mw+V+R=ksdr-r9DASZ4NSQu40Q@mail.gmail.com>
	<CALXoLqzk5CkZq=tKvv=W+ugc43gr6Ug-ELo9HnjM9pxJ0Pm-FQ@mail.gmail.com>
	<1690525.20160127153353@am-soft.de>
	<CALXoLqxODO4UTFrgDs7YZh+mArE=4tZsx1jiAHiUKYi97AvZ4g@mail.gmail.com>
	<34973063.20160129141840@am-soft.de>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-admin>

El vie, 29-01-2016 a las 14:18 +0100, Thorsten Schöning escribió:
> Guten Tag Ankur Kaushik,
> am Freitag, 29. Januar 2016 um 13:16 schrieben Sie:
> 
> > To Kill idle connection in every 10 sec , But after 15 -30 Min top
> > command show as below
> 
> Killing idle connections is completely pointless, because those are
> kept open for performance reasons, pgbouncer is designed to keep
> connections open and idle, so that applications use them faster. If 
> you want less idle connections, reduce the configuration for those in
> pgbouncer, but in the end you defeat its purpose that way.

+1. If you don't want to keep many connections open in idle state, you
can configure them at pgbouncer level or pool configuration in tomcat
or application level.

> 
> 
> >   PID USER      PR  NI  VIRT  RES  SHR S     %CPU %MEM    TIME+ 
> >  COMMAND
> > 10454 root        20   0 7101m   2.4g  11m  S    751.3 15.4 
> >  84:47.60 java
> 
> You problem is obviously that you don't have any clue what your
> problem is, therefore you're just guessing things around. Don't do
> that, at least look at the logs of your Tomcat, you may even use Java
> Mission Control to monitor the performance of Tomcat and so on. This
> high load might even be the result of your script introducing some
> kind of a race condition, where you kill a connection just in that
> moment where it was given to a using process in Tomcat.

Java is consuming 7/8 core of cpu, so i think you your look closer into
tomcat and java processes.

How about your work_mem parameter and top stats relatives of postgresql
server ?


> 
> If your problem is with Tomcat consuming too much memory or having
> unexplainable high CPU load, don't waste your time with advancing the
> complexity of your setup by installing pgbouncer. Focus on Tomcat and
> its logs first.

+1

> 
> Mit freundlichen Grüßen,
> 
> Thorsten Schöning
> 
> -- 
> Thorsten Schöning       E-Mail: Thorsten.Schoening@AM-SoFT.de
> AM-SoFT IT-Systeme      http://www.AM-SoFT.de/
> 
> Telefon...........05151-  9468- 55
> Fax...............05151-  9468- 88
> Mobil..............0178-8 9468- 04
> 
> AM-SoFT GmbH IT-Systeme, Brandenburger Str. 7c, 31789 Hameln
> AG Hannover HRB 207 694 - Geschäftsführer: Andreas Muchow
> 
> 
> 
-- 
Jaime Soler Gómez
HOPLA Software
EnterpriseDB exclusive distributor ES/PT/IT & LatAm
| P : (+34) 616 71 44 41 | SKYPE : jaimesolergomez | W : http://www.hoplasoftware.com/



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



view thread (10+ messages)  latest in thread

Message-ID: <1454325781.5847.84.camel@hoplasoftware.com>
Permalink:  ../1454325781.5847.84.camel@hoplasoftware.com/
Also on:    postgresql.org/message-id/1454325781.5847.84.camel@hoplasoftware.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: jsoler@hoplasoftware.com, tschoening@am-soft.de
  Subject: Re: Per thread Connection memory
  In-Reply-To: <1454325781.5847.84.camel@hoplasoftware.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox