pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Julien Rouhaud <julien.rouhaud@dalibo.com>
To: Samir Magar <samirmagar8@gmail.com>
To: pgsql-performance@postgresql.org
Subject: Re: Delay in converting logs from ready state to done state
Date: Wed, 12 Oct 2016 08:03:53 +0200
Message-ID: <ec7967ee-10bb-d0fc-e27d-a0e2200652c9@dalibo.com> (raw)
In-Reply-To: <CAA=to3jfR91csHz70eXZOTf_9WYzVHKWE2HG4EuZZPRO-XV4Gw@mail.gmail.com>
References: <CAA=to3jfR91csHz70eXZOTf_9WYzVHKWE2HG4EuZZPRO-XV4Gw@mail.gmail.com>
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-performance>

On 12/10/2016 07:26, Samir Magar wrote:
> Team,
> 
> we are seeing delay in converting logs from ready state to done state in
> pg_xlog archive status.
> 
> we have seen pg_xlog generated 2000 per hour and it is getting archived
> 1894. So the speed at which the archiving is done is too slow as compare
> to the pg_xlog generation
> 
> So our pg_xlog directory keeps filling regularly. What should be the
> real cause here?
> 
> We cannot see any specific error on pg_log  except no space left on device.
> 
>  
> 
> current setting:
> 
> wal_level = archive
> 
> archive_mode = on
> 
> max_wal_senders = 3
> 
> archive_command = 'gzip < %p > /pgarchive/%f'
> 

You could use pigz which is parallel, that could speed up compression.

> checkpoint_segments = 3
> 

this is way to low. If you generate 2000 WAL per hour, you should
configure it to something like 170 (or 5 min average if 2000 is a
spike).  It'll perform less checkpoint and also generate less WALs.


-- 
Julien Rouhaud
http://dalibo.com - http://dalibo.org


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



view thread (3+ messages)  latest in thread

Message-ID: <ec7967ee-10bb-d0fc-e27d-a0e2200652c9@dalibo.com>
Permalink:  ../ec7967ee-10bb-d0fc-e27d-a0e2200652c9@dalibo.com/
Also on:    postgresql.org/message-id/ec7967ee-10bb-d0fc-e27d-a0e2200652c9@dalibo.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-performance@postgresql.org
  Cc: julien.rouhaud@dalibo.com, samirmagar8@gmail.com
  Subject: Re: Delay in converting logs from ready state to done state
  In-Reply-To: <ec7967ee-10bb-d0fc-e27d-a0e2200652c9@dalibo.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