Re: Question about wal files / pg_xlogs - Mailing list pgsql-general

From Patrick B
Subject Re: Question about wal files / pg_xlogs
Date
Msg-id CAJNY3iuQ-crCb--se03o_==K3Bs7P-3NAtoJHNzBvNHRyY9nCQ@mail.gmail.com
Whole thread Raw
In response to Re: Question about wal files / pg_xlogs  (Adrian Klaver <adrian.klaver@aklaver.com>)
Responses Re: Question about wal files / pg_xlogs  (Venkata Balaji N <nag1010@gmail.com>)
Re: Question about wal files / pg_xlogs  (John R Pierce <pierce@hogranch.com>)
Re: Question about wal files / pg_xlogs  (Adrian Klaver <adrian.klaver@aklaver.com>)
List pgsql-general


Both machines have same timezone?

Yes! Shouldn't be showing 2 hours before.. I just checked and both server has the same date / timezone
 

How fast are you generating WALs?


Check below please

checkpoint_segments = 64
checkpoint_timeout = 5min
checkpoint_completion_target = 0.6
checkpoint_warning = 30s
archive_timeout = 1800
max_wal_senders = 8
wal_keep_segments = 256
 

How are you shipping the WALs?



I use a bash script to ship them. The script hasn't being changed.... So it isn't the problem. 


postgresql.conf:
archive_command = 'exec nice -n 19 ionice -c 2 -n 7 archive_command.bash "%p" slave01 slave02'

archive_command.bash:

Basically we use TAR to ship through ssh:

# we use tar over SSH as I don't fully trust scp's exit status. The added benefit is that tar preserves all attributes
# the downside is that it's a little tricky to make the remote path relative
tar -c -O --no-same-owner -C "${WAL_SEGMENT%/*}" "${WAL_SEGMENT##*/}" | ssh -p ${NEXT_PORT} -C -o 'BatchMode=yes' -o 'CompressionLevel=3' "${USER}@${NEXT_HOST}" "exec tar -x --no-same-owner --overwrite -C '${WAL_ARCHIVE_PATH}'";
PS_CONCAT="${PIPESTATUS[*]}";


The script is complex, but as I said, nothing has been changed on it.

pgsql-general by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: Question about wal files / pg_xlogs
Next
From: Venkata Balaji N
Date:
Subject: Re: Question about wal files / pg_xlogs