Re: FATAL: could not receive data from WAL stream

From: Lucas Possamai <drum(dot)lucas(at)gmail(dot)com>
To: Venkata B Nagothi <nag1010(at)gmail(dot)com>
Cc: Patrick B <patrickbakerbr(at)gmail(dot)com>, pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: Re: FATAL: could not receive data from WAL stream
Date: 2016-09-20 04:29:52
Message-ID: CAE_gQfXHVX8GUr8QVm8=_W0PrtXThDxMVUK9-8AuUV8=urCmFw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

2016-09-20 16:29 GMT+12:00 Lucas Possamai <drum(dot)lucas(at)gmail(dot)com>:

>
>
> 2016-09-20 15:14 GMT+12:00 Venkata B Nagothi <nag1010(at)gmail(dot)com>:
>
>>
>> On Tue, Sep 20, 2016 at 12:38 PM, Patrick B <patrickbakerbr(at)gmail(dot)com>
>> wrote:
>>
>>> Hi guys,
>>>
>>> I got a slave server running Postgres 9.2 with streaming replication and
>>> wal_archive in an EC2 Instance at Amazon.
>>>
>>> Postgres logs are showing me this error:
>>>
>>>> restored log file "000000020000179A000000F8" from archive
>>>> invalid record length at 179A/F8FFF3D0
>>>> WAL segment `/var/lib/pgsql/9.2/archive/00000003.history` not found
>>>> streaming replication successfully connected to primary
>>>> FATAL: could not receive data from WAL stream: FATAL: requested WAL
>>>> segment 000000020000179A000000F8 has already been removed
>>>
>>>
>>> However, 000000020000179A000000F8 file is inside
>>> /var/lib/pgsql/9.2/archive directory:
>>>
>>>> postgres(at)devops:/var/lib/pgsql/9.2/archive$ ls -la | grep
>>>> 000000020000179A000000F8
>>>> -rw------- 1 postgres postgres 16777216 Sep 16 05:16
>>>> 000000020000179A000000F8
>>>
>>>
>>>
>>> It's an UBUNTU instance, so my recovery.conf is:
>>>
>>>
>>> */etc/postgresql/9.2/main/recovery.conf:*
>>>
>>>> restore_command = 'exec /var/lib/pgsql/bin/restore_wal_segment.bash
>>>> "/var/lib/pgsql/9.2/wal_archive/%f" "%p"'
>>>> archive_cleanup_command = '/var/lib/postgresql/bin/pg_ar
>>>> chivecleaup_mv.bash'
>>>> recovery_target_timeline = 'latest'
>>>> standby_mode = on
>>>> primary_conninfo = 'host=IP_MY_SLAVE port=5432 user=replicator
>>>> application_name=devops'
>>>
>>>
>>>
>>> What can be happening, if the file is in there?
>>>
>>
>> Do you mean to say that the WAL file "000000020000179A000000F8" is
>> available @ "/var/lib/pgsql/9.2/archive" location ?
>>
>> Regards,
>> Venkata B N
>>
>> Fujitsu Australia
>>
>>
>
>
>
> Yes.....
>
>

Ops.. sorry... sent to the wrong email

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Patrick B 2016-09-20 04:30:27 Re: FATAL: could not receive data from WAL stream
Previous Message Lucas Possamai 2016-09-20 04:29:23 Re: FATAL: could not receive data from WAL stream