Re: [GENERAL] does pg_restore respect CLUSTER ON in the schema?

2014-11-06 Thread David G Johnston
Seth Pollack wrote > I have a database where several tables have been physically clustered on > disk. Those clustering configuration parameters are stored in the schema > (via ALTER TABLE mytable CLUSTER ON myindex). > > My question is, when i restore a backup of this database using pg_restore, >

Re: [GENERAL] does pg_restore respect CLUSTER ON in the schema?

2014-11-06 Thread John R Pierce
On 11/6/2014 3:03 PM, Seth Pollack wrote: I have a database where several tables have been physically clustered on disk. Those clustering configuration parameters are stored in the schema (via ALTER TABLE mytable CLUSTER ON myindex). My question is, when i restore a backup of this database usi

[GENERAL] does pg_restore respect CLUSTER ON in the schema?

2014-11-06 Thread Seth Pollack
I have a database where several tables have been physically clustered on disk. Those clustering configuration parameters are stored in the schema (via ALTER TABLE mytable CLUSTER ON myindex). My question is, when i restore a backup of this database using pg_restore, is it restored with that phy

Re: [GENERAL] Tablespace limit feature

2014-11-06 Thread Stephen Frost
* Jim Nasby (jim.na...@bluetreble.com) wrote: > On 11/4/14, 2:10 PM, Alvaro Herrera wrote: > >Alejandro Carrillo escribió: > >>> > >>>But This feature is very necessary to control the amount space expensed by > >>>a postgresql user or tablespace. This feature could be used in PostgreSQL > >>>Shar

Re: [GENERAL] Tablespace limit feature

2014-11-06 Thread Jim Nasby
On 11/4/14, 2:10 PM, Alvaro Herrera wrote: Alejandro Carrillo escribió: > >But This feature is very necessary to control the amount space expensed by a postgresql user or tablespace. This feature could be used in PostgreSQL Sharing Hosting, see: Shared Database Hosting - PostgreSQL wiki Sure.

Re: [GENERAL] Postgres char type inconsistency

2014-11-06 Thread Adrian Klaver
On 11/04/2014 10:43 AM, Brent Wood wrote: Looking at the behaviour of char & varchar types, there seems to be an issue. Can anyone explain this behaviour? Is there a bug of some sort? According to the docs http://www.postgresql.org/docs/9.3/static/datatype-character.html)(: " If the string to b

Re: [GENERAL] Incomplete startup packet help needed

2014-11-06 Thread Jon Erdman
On Thu, 6 Nov 2014 13:40:14 +0100 Francisco Olarte wrote: > Hi Juan Antonio: > > On Tue, Nov 4, 2014 at 9:54 PM, memtec > wrote: > > > You can force this message executing: > > $ echo | nc SERVER_IP 5432 > > 2014-11-04 21:44:37 CET LOG: incomplete startup packet > > > > What do you need help

Re: [GENERAL] Postgres char type inconsistency

2014-11-06 Thread Bill Moran
On Tue, 4 Nov 2014 18:43:38 + Brent Wood wrote: > > Looking at the behaviour of char & varchar types, there seems to be an issue. > Can anyone explain this behaviour? Is there a bug of some sort? > > According to the docs > http://www.postgresql.org/docs/9.3/static/datatype-character.html

Re: [GENERAL] phppgadmin

2014-11-06 Thread Raymond O'Donnell
On 06/11/2014 15:24, Ramesh T wrote: > hello, > any guidelines is their how to use these tool..? > not home site.. > http://phppgadmin.kattare.com/phppgadmin/...:) Here's the home site: http://phppgadmin.sourceforge.net Lots of documentation available there. Ray. -- Raymond O'

[GENERAL] Postgres char type inconsistency

2014-11-06 Thread Brent Wood
Looking at the behaviour of char & varchar types, there seems to be an issue. Can anyone explain this behaviour? Is there a bug of some sort? According to the docs http://www.postgresql.org/docs/9.3/static/datatype-character.html)(: " If the string to be stored is shorter than the declared leng

Re: [GENERAL] DATA corruption after promoting slave to master

2014-11-06 Thread Kirit Parmar
Hey Shaun, Hope you are keeping well. Will you please help me with this un-common behaviour of postgres. When executing the query (1) it takes around 62 seconds. However when disabling the index scan the same query (2) executes in around 2 seconds. Is there any reason why the query planner prefers

[GENERAL] phppgadmin

2014-11-06 Thread Ramesh T
hello, any guidelines is their how to use these tool..? not home site.. http://phppgadmin.kattare.com/phppgadmin/...:)

Re: [GENERAL] phppgadmin

2014-11-06 Thread Ramesh T
tell me good guidelines for phppgadmin..? On Thu, Nov 6, 2014 at 8:54 PM, Ramesh T wrote: > hello, > any guidelines is their how to use these tool..? > not home site.. > http://phppgadmin.kattare.com/phppgadmin/...:) >

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread Francisco Olarte
Hi John. On Thu, Nov 6, 2014 at 4:47 PM, John R Pierce wrote: note that net mask?the loopback interface is the entire 127.0.0.0/8 > networkyou can't put a host at 127.0.1.x and expect it to work right. > You can, and it works, it just connects to yourself. Even without names, I have use

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread Edoardo Panfili
Il 06/11/14 16:54, Adrian Klaver ha scritto: On 11/06/2014 07:47 AM, John R Pierce wrote: On 11/6/2014 7:36 AM, Edoardo Panfili wrote: grep localhost /etc/hosts 127.0.0.1 localhost 127.0.1.1 host.host host wah? https://lists.debian.org/debian-devel/2013/07/msg00809.html

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread Adrian Klaver
On 11/06/2014 07:57 AM, Edoardo Panfili wrote: Il 06/11/14 16:47, John R Pierce ha scritto: On 11/6/2014 7:36 AM, Edoardo Panfili wrote: grep localhost /etc/hosts 127.0.0.1 localhost 127.0.1.1 host.host host wah? whats the output of ... # ifconfig lo loLink enca

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread Edoardo Panfili
Il 06/11/14 16:47, John R Pierce ha scritto: On 11/6/2014 7:36 AM, Edoardo Panfili wrote: grep localhost /etc/hosts 127.0.0.1 localhost 127.0.1.1 host.host host wah? whats the output of ... # ifconfig lo loLink encap:Local Loopback inet addr:127.0.0.1

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread Adrian Klaver
On 11/06/2014 07:47 AM, John R Pierce wrote: On 11/6/2014 7:36 AM, Edoardo Panfili wrote: grep localhost /etc/hosts 127.0.0.1 localhost 127.0.1.1 host.host host wah? https://lists.debian.org/debian-devel/2013/07/msg00809.html -- Adrian Klaver adrian.kla...@aklaver.c

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread Edoardo Panfili
Il 06/11/14 16:18, Adrian Klaver ha scritto: On 11/06/2014 07:00 AM, John R Pierce wrote: On 11/6/2014 6:34 AM, Edoardo Panfili wrote: Why localhost is not an alias for 127.0.0.1 ? grep localhost /etc/hosts I've seen some weird stuff on some systems. I have localhost/127.0.0.1 set up cor

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread Edoardo Panfili
Il 06/11/14 16:08, Tom Lane ha scritto: Edoardo Panfili writes: I am using postgres 9.4beta3 (Debian jessie) this is my pg_hba.conf -- localallpostgrespeer localallallmd5 hostallall127.0.0.1/32md5 hostallall::1/128md5 -

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread John R Pierce
On 11/6/2014 7:36 AM, Edoardo Panfili wrote: grep localhost /etc/hosts 127.0.0.1 localhost 127.0.1.1 host.host host wah? whats the output of ... # ifconfig lo loLink encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread Edoardo Panfili
Il 06/11/14 16:00, John R Pierce ha scritto: On 11/6/2014 6:34 AM, Edoardo Panfili wrote: Why localhost is not an alias for 127.0.0.1 ? grep localhost /etc/hosts 127.0.0.1 localhost 127.0.1.1 host.host host # The following lines are desirable for IPv6 capable hosts ::1

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread Adrian Klaver
On 11/06/2014 07:00 AM, John R Pierce wrote: On 11/6/2014 6:34 AM, Edoardo Panfili wrote: Why localhost is not an alias for 127.0.0.1 ? grep localhost /etc/hosts I've seen some weird stuff on some systems. I have localhost/127.0.0.1 set up correctly on my machine and I see the same behav

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread Tom Lane
Edoardo Panfili writes: > I am using postgres 9.4beta3 (Debian jessie) > this is my pg_hba.conf > -- > localallpostgrespeer > localallallmd5 > hostallall127.0.0.1/32md5 > hostallall::1/128md5 > -- > bu

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread John R Pierce
On 11/6/2014 6:34 AM, Edoardo Panfili wrote: Why localhost is not an alias for 127.0.0.1 ? grep localhost /etc/hosts I've seen some weird stuff on some systems. -- john r pierce 37N 122W somewhere on the middle of the left coast -- Sent via pgsql-gene

Re: [GENERAL] Performance of UPDATE SET = FROM vs UPDATE SET = (SELECT ...)

2014-11-06 Thread Shaun Thomas
These updates aren't equivalent. It's very important you know this, because you're also inflating your table with a lot of extra updated rows. Take the first UPDATE: > UPDATE second SET time1 = orig.time1 > FROM orig > WHERE second.key1 = orig.key1; If you wrote this as a SELECT, it would look

Re: [GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread Adrian Klaver
On 11/06/2014 06:34 AM, Edoardo Panfili wrote: I am using postgres 9.4beta3 (Debian jessie) this is my pg_hba.conf -- localallpostgrespeer localallallmd5 hostallall127.0.0.1/32md5 hostallall::1/128md5 ---

[GENERAL] psql connection via localhost or 127.0.0.1

2014-11-06 Thread Edoardo Panfili
I am using postgres 9.4beta3 (Debian jessie) this is my pg_hba.conf -- localallpostgrespeer localallallmd5 hostallall127.0.0.1/32md5 hostallall::1/128md5 -- but if I use psql to connect via tcp to the

Re: [GENERAL] DATA corruption after promoting slave to master

2014-11-06 Thread Shaun Thomas
Hi Krit, It looks like your actual problem is here: >  Index Scan using t1_orderid_creationtime_idx on t1 >  (cost=0.43..1181104.36 rows=9879754 width=158) > (actual time=0.021..60830.724 rows=2416614 loops=1 This index scan estimates 9.8M rows, and had to touch 2.4M. The issue is that your LI

Re: [GENERAL] Performance problem on 2 PG versions on same query

2014-11-06 Thread Rémy-Christophe Schermesser
Thank you very much for the insights (and how to read correctly a explain :)). There is a difference in data between the 2 databases, crons where running on one and not the other. But your insights enabled us to dive deeper, thanks ! 2014-11-05 18:30 GMT+01:00 Tom Lane : > "Tomas Vondra" writes

Re: [GENERAL] Incomplete startup packet help needed

2014-11-06 Thread Francisco Olarte
Hi Juan Antonio: On Tue, Nov 4, 2014 at 9:54 PM, memtec wrote: > You can force this message executing: > $ echo | nc SERVER_IP 5432 > 2014-11-04 21:44:37 CET LOG: incomplete startup packet > What do you need help on? PG uses a binary protocol, you sent it bad data ( I think this will open conn