[PERFORM] Connection Options -- SSL already uses compression?

2012-10-19 Thread Karl Denninger
Am I reading this correctly -- it appears that if SSL negotiation is enabled for a connection (say, when using pg_basebackup over a WAN) that compression /*is automatically used*/ (provided it is supported on both ends)? Is there a way to check and see if it _*is*_ on for a given connection? I wa

Re: [PERFORM] Recursive query gets slower when adding an index

2012-10-19 Thread Thomas Kellerer
Tom Lane wrote on 19.10.2012 16:20: Thomas Kellerer writes: This is the execution plan without index: http://explain.depesz.com/s/ecCT When I create an index on parent_id execution time increases to something between 110ms and 130ms This is the execution plan with index: http://explain.depesz.

Re: [PERFORM] SELECT AND AGG huge tables

2012-10-19 Thread Ants Aasma
On Wed, Oct 17, 2012 at 2:24 PM, houmanb wrote: > Hi all, > Thanks for your advice and the link about posting my question in an > appropriate form. > Here are the info. I thank all of you in advance. Can you run the EXPLAIN once more with EXPLAIN (ANALYZE, BUFFERS, TIMING OFF). Given the number o

[PERFORM] How to upgrade from 9.1 to 9.2 with replication?

2012-10-19 Thread delongboy
I have replication set up on servers with 9.1 and want to upgrade to 9.2 I was hoping I could just bring them both down, upgrade them both and bring them both up and continue replication, but that doesn't seem to work, the replication server won't come up. Is there anyway to do this upgrade with ou

Re: [PERFORM] How to upgrade from 9.1 to 9.2 with replication?

2012-10-19 Thread Shaun Thomas
On 10/19/2012 10:49 AM, Karl Denninger wrote: That's an interesting idea that might work; are replicated servers in a consistent state guaranteed to have byte-identical filespaces? (other than the config file(s), of course) I have not checked that assumption. Well, if they didn't before, they

Re: [PERFORM] limit order by performance issue

2012-10-19 Thread Claudio Freire
On Wed, Oct 17, 2012 at 6:14 AM, Pedro Jiménez Pérez wrote: > select var_value from ism_floatvalues where id_signal = 29660 order by > time_stamp desc limit 1; > > This is what EXPLAIN returns (can't make EXPLAIN ANALYZE because it > "never" ends): > > "Limit (cost=0.00..258.58 rows=1 width=16)"

Re: [PERFORM] How to upgrade from 9.1 to 9.2 with replication?

2012-10-19 Thread Shaun Thomas
On 10/19/2012 09:44 AM, Karl Denninger wrote: For really BIG databases (as opposed to moderately-big) this could be a much-more material problem than it is for me. Which reminds me. I really wish pg_basebackup let you specify an alternative compression handler. We've been using pigz on our sy

Re: [PERFORM] How to upgrade from 9.1 to 9.2 with replication?

2012-10-19 Thread Karl Denninger
On 10/19/2012 10:02 AM, Claudio Freire wrote: > On Fri, Oct 19, 2012 at 11:44 AM, Karl Denninger wrote: >> On 10/18/2012 5:21 PM, delongboy wrote: >> >> I have replication set up on servers with 9.1 and want to upgrade to 9.2 >> I was hoping I could just bring them both down, upgrade them both and

Re: [PERFORM] Tablespace-derived stats?

2012-10-19 Thread Jeff Janes
On Fri, Oct 19, 2012 at 8:07 AM, Shaun Thomas wrote: > On 10/19/2012 10:05 AM, Jeff Janes wrote: > >> http://www.postgresql.org/docs/9.0/static/sql-altertablespace.html > > > Yep. I realized my error was not checking the ALTER page after going through > CREATE. I swore I remembered seeing it in th

Re: [PERFORM] Tablespace-derived stats?

2012-10-19 Thread Shaun Thomas
On 10/19/2012 10:05 AM, Jeff Janes wrote: http://www.postgresql.org/docs/9.0/static/sql-altertablespace.html Yep. I realized my error was not checking the ALTER page after going through CREATE. I swore I remembered seeing it in the past, but was surprised it wasn't there. I keep forgetting

Re: [PERFORM] Tablespace-derived stats?

2012-10-19 Thread Jeff Janes
On Fri, Oct 19, 2012 at 7:29 AM, Shaun Thomas wrote: > Hello Perf, > > Lately I've been pondering. As systems get more complex, it's not uncommon > for tiered storage to enter the picture. Say for instance, a user has some > really fast tables on a NVRAM-based device, and slower-access stuff on a

Re: [PERFORM] How to upgrade from 9.1 to 9.2 with replication?

2012-10-19 Thread Claudio Freire
On Fri, Oct 19, 2012 at 11:44 AM, Karl Denninger wrote: > On 10/18/2012 5:21 PM, delongboy wrote: > > I have replication set up on servers with 9.1 and want to upgrade to 9.2 > I was hoping I could just bring them both down, upgrade them both and bring > them both up and continue replication, but

Re: [PERFORM] Tablespace-derived stats?

2012-10-19 Thread Shaun Thomas
On 10/19/2012 09:51 AM, Tom Lane wrote: We've had tablespace-specific settings for those for some time. Ah, my apologies. I didn't see any in the CREATE TABLESPACE page, and didn't think to check ALTER TABLESPACE. I withdraw my question. :) -- Shaun Thomas OptionsHouse | 141 W. Jackson Blv

Re: [PERFORM] Tablespace-derived stats?

2012-10-19 Thread Tom Lane
Shaun Thomas writes: > Yet there's only one global setting for random_page_cost, and > seq_page_cost, and so on. We've had tablespace-specific settings for those for some time. regards, tom lane -- Sent via pgsql-performance mailing list (pgsql-performance@postgresql.

Re: [PERFORM] How to upgrade from 9.1 to 9.2 with replication?

2012-10-19 Thread Karl Denninger
On 10/18/2012 5:21 PM, delongboy wrote: > I have replication set up on servers with 9.1 and want to upgrade to 9.2 > I was hoping I could just bring them both down, upgrade them both and bring > them both up and continue replication, but that doesn't seem to work, the > replication server won't co

[PERFORM] Tablespace-derived stats?

2012-10-19 Thread Shaun Thomas
Hello Perf, Lately I've been pondering. As systems get more complex, it's not uncommon for tiered storage to enter the picture. Say for instance, a user has some really fast tables on a NVRAM-based device, and slower-access stuff on a RAID, even slower stuff on an EDB, and variants like local

Re: [PERFORM] Recursive query gets slower when adding an index

2012-10-19 Thread Tom Lane
Thomas Kellerer writes: > This is the execution plan without index: http://explain.depesz.com/s/ecCT > When I create an index on parent_id execution time increases to something > between 110ms and 130ms > This is the execution plan with index: http://explain.depesz.com/s/xiL The reason you get a

Re: [PERFORM] limit order by performance issue

2012-10-19 Thread Pedro Jiménez Pérez
Title: Documento sin título For this query: select var_value from ism_floatvalues where id_signal = 29660 order by time_stamp desc limit 1; This is what EXPLAIN returns (can't make EXPLAIN ANALYZE because it "never" ends): "Limit  (cost=0.00..258.58

[PERFORM] Recursive query gets slower when adding an index

2012-10-19 Thread Thomas Kellerer
Hi, I have a self-referencing table that defines a hierarchy of projects and sub-projects. This is the table definition: CREATE TABLE project ( project_idinteger primary key, project_name text, pl_name text, parent_id integer ); ALTER TABLE project ADD CONSTRAINT