Re: PgBackRest question?

2017-12-15 Thread chiru r
Hi All, Thanks,I am thinking about a specific recovery case. Lets assume Heavy transactional system we configured. It is generating WAL 2000/hr and recycling automatically in pg_wal directory. QA : Sunday -- 11 PM -- Full backup done. Monday -- 11 PM -- Differential Backup done Tuesday-- 10 A

Re: pgbench

2017-12-15 Thread John R Pierce
On 12/15/2017 7:37 AM, Olga Lytvynova-Bogdanova wrote: Is there a way to integrate pgbench with TeamCity? If yes, could you share very briefly how to do this? I would suspect this is a question for TeamCity, not for postgresql.   I don't even know what TeamCity actually is (google says 'Contin

Re: Replication questions - read-only and temporary read/write slaves

2017-12-15 Thread Tiffany Thang
Thanks! On Fri, Dec 15, 2017 at 1:56 PM, Stefano wrote: > For n.2, you can promote the standby to became a standalone (r/w) server. > This may be done via "pg_ctl -D $PGDATA promote" or, if in the > recovery.conf a "triggerfile" definition has been set, touch-ing the > triggerfile. > see https:/

Re: Dependency tree to tie type/function deps to a table

2017-12-15 Thread bricklen
On Fri, Dec 15, 2017 at 6:44 AM, Jeremy Finzel wrote: > Here is my current effort. I would love feedback in case I've missed > something. > Perhaps you'll find the version on the wiki useful as reference, it's an older version of the dependencies, and can be found at https://wiki.postgresql.org

Re: Replication questions - read-only and temporary read/write slaves

2017-12-15 Thread Stefano
For n.2, you can promote the standby to became a standalone (r/w) server. This may be done via "pg_ctl -D $PGDATA promote" or, if in the recovery.conf a "triggerfile" definition has been set, touch-ing the triggerfile. see https://www.postgresql.org/docs/current/static/standby-settings.html https:/

Re: Replication questions - read-only and temporary read/write slaves

2017-12-15 Thread Tiffany Thang
Thanks Magnus. I did not realize I could use the Hot Standby in read-only mode. For #2, would it be possible to open the Hot Standby in read/write after breaking the replication and taking a snapshot or can Hot Standby only be open in read/write after a failover? I hoping I can use the same Hot St

Re: Replication questions - read-only and temporary read/write slaves

2017-12-15 Thread Magnus Hagander
On Fri, Dec 15, 2017 at 6:03 PM, Tiffany Thang wrote: > Hi, > In PostgreSQL, would it be possible to > > 1. set up a read-only slave database? The closest solution I could find is > Hot Standby but the slave would not be accessible until after a failover. > Hot Standby will give you a standby da

Replication questions - read-only and temporary read/write slaves

2017-12-15 Thread Tiffany Thang
Hi, In PostgreSQL, would it be possible to 1. set up a read-only slave database? The closest solution I could find is Hot Standby but the slave would not be accessible until after a failover. 2. temporary convert a read-only slave in read-write mode for testing read/write workloads? Currently in

pgbench

2017-12-15 Thread Olga Lytvynova-Bogdanova
Hello, Is there a way to integrate pgbench with TeamCity? If yes, could you share very briefly how to do this? Which volumes of data does pgbench support? Much appreciated for the attention.

Clarification on PL/pgSQL query plan caching

2017-12-15 Thread George Woodring
We were experiencing insert slowdowns at the beginning of the day when we add new tables. As part of our data insert process, we have a read function and we decided to modify it to use EXECUTE to avoid plan caching. Our assumption was was the adding the table would invalidate the plan for the curr

Re: Dependency tree to tie type/function deps to a table

2017-12-15 Thread Jeremy Finzel
Here is my current effort. I would love feedback in case I've missed something. I also know there is perhaps a little redundancy in the recursion but it's looking quick enough. The query below has the relname of the base table hardcoded but I would generalize this once happy with it. WITH RECUR

Re: User-defined print format for extension-defined types in psql output

2017-12-15 Thread Laurenz Albe
Peter Devoy wrote: > To make inspecting PostGIS tables in psql easier I have written a > function which outputs PostGIS Geometry objects as a string of ASCII > art. > > Please does anyone know if there is there some way I can have my > function called automatically by psql instead of me writing it