Re: Replication slots and footguns - Mailing list pgsql-hackers

From Josh Berkus
Subject Re: Replication slots and footguns
Date
Msg-id 5320C48A.6070802@agliodbs.com
Whole thread Raw
In response to Replication slots and footguns  (Josh Berkus <josh@agliodbs.com>)
List pgsql-hackers
On 03/12/2014 12:26 PM, Andres Freund wrote:
> On 2014-03-12 12:23:01 -0700, Josh Berkus wrote:
>> On 03/12/2014 12:03 PM, Andres Freund wrote:
>>>> It seems like there's no way for a DBA to drop slots from the master if
>>>> it's rapidly running out of disk WAL space without doing a restart, and
>>>> there's no way to drop the slot for a replica which the DBA knows is
>>>> permanently offline but was connected earlier.  Am I missing something?
>>>
>>> It's sufficient to terminate the walsender and then drop the slot. That
>>> seems ok for now?
>>
>> We have no safe way to terminate the walsender that I know of;
>> pg_terminate_backend() doesn't include walsenders last I checked.
> 
> SELECT pg_terminate_backend(pid) FROM pg_stat_replication;

Aha!  Ok, I'll work on some documentation.

-- 
Josh Berkus
PostgreSQL Experts Inc.
http://pgexperts.com



pgsql-hackers by date:

Previous
From: Peter Geoghegan
Date:
Subject: Re: jsonb and nested hstore
Next
From: Josh Berkus
Date:
Subject: Re: Replication slots and footguns