pg.ddx.io pgsql-general@postgresql.org mailing list archive
help / color / mirror / Atom feed"checkpointer process" is consuming more memory. How to control it?
7+ messages / 6 participants
[nested] [flat]
* "checkpointer process" is consuming more memory. How to control it?
@ 2018-08-22 13:43 Raghavendra Rao J S V <raghavendrajsv@gmail.com>
2018-08-22 13:54 ` Re: "checkpointer process" is consuming more memory. How to control it? Adrian Klaver <adrian.klaver@aklaver.com>
2018-08-22 13:56 ` Re: "checkpointer process" is consuming more memory. How to control it? Avinash Kumar <avinash.vallarapu@gmail.com>
2018-08-22 14:43 ` Re: "checkpointer process" is consuming more memory. How to control it? Maksim Milyutin <milyutinma@gmail.com>
0 siblings, 3 replies; 7+ messages in thread
From: Raghavendra Rao J S V @ 2018-08-22 13:43 UTC (permalink / raw)
To: pgsql-general@lists.postgresql.org
Hi All,
We have a database cluster as "db1_data". Under this cluster we have two
databases. one is *db1 *and other is *qovr*. I surprised to see as
"checkpointer process" is consuming 8.73GB of memory(RSS value as 9158892).
Why "checkpointer process" is consuming this much amount of memory and how
to limit the usage of the "checkpointer process" memory.
[image: image.png]
--
Regards,
Raghavendra Rao J S V
Attachments:
image.png (image/png, 177.3K) download
view image
^ permalink raw reply [nested|flat] 7+ messages in thread
* Re: "checkpointer process" is consuming more memory. How to control it?
2018-08-22 13:43 "checkpointer process" is consuming more memory. How to control it? Raghavendra Rao J S V <raghavendrajsv@gmail.com>
@ 2018-08-22 13:54 ` Adrian Klaver <adrian.klaver@aklaver.com>
2 siblings, 0 replies; 7+ messages in thread
From: Adrian Klaver @ 2018-08-22 13:54 UTC (permalink / raw)
To: Raghavendra Rao J S V <raghavendrajsv@gmail.com>; pgsql-general@lists.postgresql.org
On 08/22/2018 06:43 AM, Raghavendra Rao J S V wrote:
> Hi All,
>
> We have a database cluster as "db1_data". Under this cluster we have two
> databases. one is *db1 *and other is *qovr*. I surprised to see as
> "checkpointer process" is consuming 8.73GB of memory(RSS value as
> 9158892). Why "checkpointer process" is consuming this much amount of
> memory and how to limit the usage of the "checkpointer process" memory.
Take a look at:
https://www.postgresql.org/docs/10/static/wal-configuration.html
>
> image.png
>
> --
> Regards,
> Raghavendra Rao J S V
>
--
Adrian Klaver
adrian.klaver@aklaver.com
^ permalink raw reply [nested|flat] 7+ messages in thread
* Re: "checkpointer process" is consuming more memory. How to control it?
2018-08-22 13:43 "checkpointer process" is consuming more memory. How to control it? Raghavendra Rao J S V <raghavendrajsv@gmail.com>
@ 2018-08-22 13:56 ` Avinash Kumar <avinash.vallarapu@gmail.com>
2018-08-22 14:02 ` Re: "checkpointer process" is consuming more memory. How to control it? Raghavendra Rao J S V <raghavendrajsv@gmail.com>
2 siblings, 1 reply; 7+ messages in thread
From: Avinash Kumar @ 2018-08-22 13:56 UTC (permalink / raw)
To: raghavendrajsv@gmail.com; avi.vallarapu@percona.com; +Cc: pgsql-general@lists.postgresql.org
Hi Raghavendra,
Please let us know your PostgreSQL version.
Also, what are the values set to the following parameters ?
select name, setting from pg_settings where name IN
('checkpoint_segments','checkpoint_timeout','max_wal_size','min_wal_size','checkpoint_completion_target','wal_keep_segments');
On Wed, Aug 22, 2018 at 10:43 AM, Raghavendra Rao J S V <
raghavendrajsv@gmail.com> wrote:
> Hi All,
>
> We have a database cluster as "db1_data". Under this cluster we have two
> databases. one is *db1 *and other is *qovr*. I surprised to see as
> "checkpointer process" is consuming 8.73GB of memory(RSS value as 9158892).
> Why "checkpointer process" is consuming this much amount of memory and how
> to limit the usage of the "checkpointer process" memory.
>
> [image: image.png]
>
> --
> Regards,
> Raghavendra Rao J S V
>
>
--
9000799060
Attachments:
image.png (image/png, 177.3K) download
view image
^ permalink raw reply [nested|flat] 7+ messages in thread
* Re: "checkpointer process" is consuming more memory. How to control it?
2018-08-22 13:43 "checkpointer process" is consuming more memory. How to control it? Raghavendra Rao J S V <raghavendrajsv@gmail.com>
2018-08-22 13:56 ` Re: "checkpointer process" is consuming more memory. How to control it? Avinash Kumar <avinash.vallarapu@gmail.com>
@ 2018-08-22 14:02 ` Raghavendra Rao J S V <raghavendrajsv@gmail.com>
2018-08-22 14:14 ` Re: "checkpointer process" is consuming more memory. How to control it? Avi Vallarapu <avi.vallarapu@percona.com>
0 siblings, 1 reply; 7+ messages in thread
From: Raghavendra Rao J S V @ 2018-08-22 14:02 UTC (permalink / raw)
To: avinash.vallarapu@gmail.com; +Cc: avi.vallarapu@percona.com; pgsql-general@lists.postgresql.org
We are using PostgreSQL 9.2 version.
As you requested below you can find the checkpoint parameter values. In
pg_xlog directory , I can see each wal file size is 16mb.
select name, setting from pg_settings where name IN ('checkpoint_segments','
checkpoint_timeout','max_wal_size','min_wal_size','
checkpoint_completion_target','wal_keep_segments');
[image: image.png]
On Wed, 22 Aug 2018 at 19:26, Avinash Kumar <avinash.vallarapu@gmail.com>
wrote:
> Hi Raghavendra,
>
> Please let us know your PostgreSQL version.
>
> Also, what are the values set to the following parameters ?
>
> select name, setting from pg_settings where name IN
> ('checkpoint_segments','checkpoint_timeout','max_wal_size','min_wal_size','checkpoint_completion_target','wal_keep_segments');
>
>
>
>
> On Wed, Aug 22, 2018 at 10:43 AM, Raghavendra Rao J S V <
> raghavendrajsv@gmail.com> wrote:
>
>> Hi All,
>>
>> We have a database cluster as "db1_data". Under this cluster we have two
>> databases. one is *db1 *and other is *qovr*. I surprised to see as
>> "checkpointer process" is consuming 8.73GB of memory(RSS value as 9158892).
>> Why "checkpointer process" is consuming this much amount of memory and how
>> to limit the usage of the "checkpointer process" memory.
>>
>> [image: image.png]
>>
>> --
>> Regards,
>> Raghavendra Rao J S V
>>
>>
>
>
> --
> 9000799060
>
--
Regards,
Raghavendra Rao J S V
Mobile- 8861161425
Attachments:
image.png (image/png, 11.0K) download
view image
image.png (image/png, 177.3K) download
view image
^ permalink raw reply [nested|flat] 7+ messages in thread
* Re: "checkpointer process" is consuming more memory. How to control it?
2018-08-22 13:43 "checkpointer process" is consuming more memory. How to control it? Raghavendra Rao J S V <raghavendrajsv@gmail.com>
2018-08-22 13:56 ` Re: "checkpointer process" is consuming more memory. How to control it? Avinash Kumar <avinash.vallarapu@gmail.com>
2018-08-22 14:02 ` Re: "checkpointer process" is consuming more memory. How to control it? Raghavendra Rao J S V <raghavendrajsv@gmail.com>
@ 2018-08-22 14:14 ` Avi Vallarapu <avi.vallarapu@percona.com>
2018-08-23 13:46 ` Re: "checkpointer process" is consuming more memory. How to control it? Andres Freund <andres@anarazel.de>
0 siblings, 1 reply; 7+ messages in thread
From: Avi Vallarapu @ 2018-08-22 14:14 UTC (permalink / raw)
To: Raghavendra Rao J S V <raghavendrajsv@gmail.com>; +Cc: Avinash Kumar <avinash.vallarapu@gmail.com>; pgsql-general@lists.postgresql.org
Seams like you are with the default or fairly less checkpoint_* settings.
You need to look at several patterns to understand the best values for
these settings.
For now, i can say 300 seconds for checkpoint_timeout could be fairly very
less. Try increasing that with a reload.
See this =>
https://www.percona.com/blog/2018/06/15/tuning-postgresql-for-sysbench-tpcc/
Please do note that delaying checkpointing could also increase the time for
crash recovery/shutdown, etc.........
--
Thanks & Regards,
Avinash Vallarapu (Avi).
PostgreSQL Support Tech Lead.
+1-902-221-5976
On Wed, Aug 22, 2018 at 11:02 AM, Raghavendra Rao J S V <
raghavendrajsv@gmail.com> wrote:
>
> We are using PostgreSQL 9.2 version.
>
> As you requested below you can find the checkpoint parameter values. In
> pg_xlog directory , I can see each wal file size is 16mb.
>
>
> select name, setting from pg_settings where name IN
> ('checkpoint_segments','checkpoint_timeout','max_wal_size','
> min_wal_size','checkpoint_completion_target','wal_keep_segments');
>
> [image: image.png]
>
> On Wed, 22 Aug 2018 at 19:26, Avinash Kumar <avinash.vallarapu@gmail.com>
> wrote:
>
>> Hi Raghavendra,
>>
>> Please let us know your PostgreSQL version.
>>
>> Also, what are the values set to the following parameters ?
>>
>> select name, setting from pg_settings where name IN
>> ('checkpoint_segments','checkpoint_timeout','max_wal_
>> size','min_wal_size','checkpoint_completion_target',
>> 'wal_keep_segments');
>>
>>
>>
>>
>> On Wed, Aug 22, 2018 at 10:43 AM, Raghavendra Rao J S V <
>> raghavendrajsv@gmail.com> wrote:
>>
>>> Hi All,
>>>
>>> We have a database cluster as "db1_data". Under this cluster we have two
>>> databases. one is *db1 *and other is *qovr*. I surprised to see as
>>> "checkpointer process" is consuming 8.73GB of memory(RSS value as 9158892).
>>> Why "checkpointer process" is consuming this much amount of memory and how
>>> to limit the usage of the "checkpointer process" memory.
>>>
>>> [image: image.png]
>>>
>>> --
>>> Regards,
>>> Raghavendra Rao J S V
>>>
>>>
>>
>>
>> --
>> 9000799060
>>
>
>
> --
> Regards,
> Raghavendra Rao J S V
> Mobile- 8861161425
>
Attachments:
image.png (image/png, 177.3K) download
view image
image.png (image/png, 11.0K) download
view image
^ permalink raw reply [nested|flat] 7+ messages in thread
* Re: "checkpointer process" is consuming more memory. How to control it?
2018-08-22 13:43 "checkpointer process" is consuming more memory. How to control it? Raghavendra Rao J S V <raghavendrajsv@gmail.com>
2018-08-22 13:56 ` Re: "checkpointer process" is consuming more memory. How to control it? Avinash Kumar <avinash.vallarapu@gmail.com>
2018-08-22 14:02 ` Re: "checkpointer process" is consuming more memory. How to control it? Raghavendra Rao J S V <raghavendrajsv@gmail.com>
2018-08-22 14:14 ` Re: "checkpointer process" is consuming more memory. How to control it? Avi Vallarapu <avi.vallarapu@percona.com>
@ 2018-08-23 13:46 ` Andres Freund <andres@anarazel.de>
0 siblings, 0 replies; 7+ messages in thread
From: Andres Freund @ 2018-08-23 13:46 UTC (permalink / raw)
To: Avi Vallarapu <avi.vallarapu@percona.com>; +Cc: Raghavendra Rao J S V <raghavendrajsv@gmail.com>; Avinash Kumar <avinash.vallarapu@gmail.com>; pgsql-general@lists.postgresql.org
On 2018-08-22 11:14:48 -0300, Avi Vallarapu wrote:
> Seams like you are with the default or fairly less checkpoint_* settings.
>
> You need to look at several patterns to understand the best values for
> these settings.
>
> For now, i can say 300 seconds for checkpoint_timeout could be fairly very
> less. Try increasing that with a reload.
>
> See this =>
> https://www.percona.com/blog/2018/06/15/tuning-postgresql-for-sysbench-tpcc/
>
> Please do note that delaying checkpointing could also increase the time for
> crash recovery/shutdown, etc.........
This seems to have not that much to do with the problem the OP has, no?
I suggest just using pmap -d $process_id_of_checkpointer
that'll likely show that it doesn't actually use much memory, but that
the RSS originates from the shared memory it has touched.
- Andres
^ permalink raw reply [nested|flat] 7+ messages in thread
* Re: "checkpointer process" is consuming more memory. How to control it?
2018-08-22 13:43 "checkpointer process" is consuming more memory. How to control it? Raghavendra Rao J S V <raghavendrajsv@gmail.com>
@ 2018-08-22 14:43 ` Maksim Milyutin <milyutinma@gmail.com>
2 siblings, 0 replies; 7+ messages in thread
From: Maksim Milyutin @ 2018-08-22 14:43 UTC (permalink / raw)
To: Raghavendra Rao J S V <raghavendrajsv@gmail.com>; pgsql-general@lists.postgresql.org
22.08.2018 16:43, Raghavendra Rao J S V wrote:
> We have a database cluster as "db1_data". Under this cluster we have
> two databases. one is *db1 *and other is *qovr*. I surprised to see as
> "checkpointer process" is consuming 8.73GB of memory(RSS value as
> 9158892). Why "checkpointer process" is consuming this much amount of
> memory and how to limit the usage of the "checkpointer process" memory.
RSS value is not reasonable to determine memory leaks because it takes
into account shared segments (e.g. from shared buffer cache). As a
long-lived process checkpointer process tries to flush and as a
consequence to touch each buffer cell therefore its RSS approaches to
local allocated memory plus shared_buffers.
If you want to know the real local memory consumption you may to use
python utility *smem* to see unshared local memory size.
--
Regards,
Maksim Milyutin
^ permalink raw reply [nested|flat] 7+ messages in thread
end of thread, other threads:[~2018-08-23 13:46 UTC | newest]
Thread overview: 7+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2018-08-22 13:43 "checkpointer process" is consuming more memory. How to control it? Raghavendra Rao J S V <raghavendrajsv@gmail.com>
2018-08-22 13:54 ` Adrian Klaver <adrian.klaver@aklaver.com>
2018-08-22 13:56 ` Avinash Kumar <avinash.vallarapu@gmail.com>
2018-08-22 14:02 ` Raghavendra Rao J S V <raghavendrajsv@gmail.com>
2018-08-22 14:14 ` Avi Vallarapu <avi.vallarapu@percona.com>
2018-08-23 13:46 ` Andres Freund <andres@anarazel.de>
2018-08-22 14:43 ` Maksim Milyutin <milyutinma@gmail.com>
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