Re: [HACKERS] proposal: get oldest LSN - function

2016-03-11 Thread Kartyshov Ivan
On 11.03.2016 16:33, Kartyshov Ivan wrote: On 28.02.2016 11:36, Michael Paquier wrote: On Sun, Feb 28, 2016 at 4:40 PM, Kartyshov Ivan wrote: It will not satisfy our purposes and our administrators for three reasons. 1) DBA set me task to get the oldest number that present in WAL

Re: [HACKERS] proposal: get oldest LSN - function

2016-03-11 Thread Kartyshov Ivan
On 28.02.2016 11:36, Michael Paquier wrote: On Sun, Feb 28, 2016 at 4:40 PM, Kartyshov Ivan wrote: It will not satisfy our purposes and our administrators for three reasons. 1) DBA set me task to get the oldest number that present in WAL, not last Yeah I got that. 2) Surely we can choose

Re: [HACKERS] proposal: get oldest LSN - function

2016-02-27 Thread Kartyshov Ivan
On 27.02.2016 16:09, Michael Paquier wrote: On Sat, Feb 27, 2016 at 3:52 PM, Kartyshov Ivan <i.kartys...@postgrespro.ru> wrote: Maybe i wasn't too accurate in terms, because I newbie, but: We can get information about xlog, using big amout of support function (pg_current_xlog_lo

Re: [HACKERS] proposal: get oldest LSN - function

2016-02-27 Thread Kartyshov Ivan
On 27.02.2016 22:36, Yury Zhuravlev wrote: Hello. You forgot to declare a GetXLogOldestLSNPtr function in a header file (in xlog.h I think). Some compilers refuse to compile this code (MSVC for example). Now I see warning from GCC: xlog.c:10627:1: warning: no previous prototype for

Re: [HACKERS] proposal: get oldest LSN - function

2016-02-26 Thread Kartyshov Ivan
On 27.02.2016 03:07, Andres Freund wrote How does it help with any of that? Hi, thank you for fast answer. Maybe i wasn't too accurate in terms, because I newbie, but: We can get information about xlog, using big amout of support function (pg_current_xlog_location(),

[HACKERS] proposal: get oldest LSN - function

2016-02-26 Thread Kartyshov Ivan
Hello, I want to suggest a client-side little function, implemented in the attached patch. Function pg_oldest_xlog_location gets us the oldest LSN (Log Sequence Number) in xlog. It is useful additional tool for DBA (we can get replicationSlotMinLSN, so why not in master), it can show us, if