Re: [HACKERS] Socket problem using beta2 on Windows-XP

2005-09-29 Thread Magnus Hagander
> >Right. Please try turning it off and see if the problem goes away. > > > > > No, wait! It does *not* go away. Do I need to do anything > more than setting this in my postgresql.conf file: > > autovacuum = false# enable autovacuum subprocess? > > and restart the service? > > The

Re: [HACKERS] Socket problem using beta2 on Windows-XP

2005-09-29 Thread Thomas Hallgren
Magnus Hagander wrote: Right. Please try turning it off and see if the problem goes away. No, wait! It does *not* go away. Do I need to do anything more than setting this in my postgresql.conf file: autovacuum = false# enable autovacuum subprocess? and restart the service? Th

Re: [HACKERS] Socket problem using beta2 on Windows-XP

2005-09-29 Thread Thomas Hallgren
Magnus Hagander wrote: Right. Please try turning it off and see if the problem goes away. It does (go away). - thomas ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org

Re: [HACKERS] Socket problem using beta2 on Windows-XP

2005-09-29 Thread Magnus Hagander
> >IIRC, the win32 installer will enable autovacuum by default. > And yes, > >autovacuum was my first thought as well after Thomas last > mail - that > >would be a good explanation to why it happens when the postmaster is > >idle. > > > > > I used the win32 installer defaults so autovacuum

Re: [HACKERS] Socket problem using beta2 on Windows-XP

2005-09-29 Thread Thomas Hallgren
Magnus Hagander wrote: IIRC, the win32 installer will enable autovacuum by default. And yes, autovacuum was my first thought as well after Thomas last mail - that would be a good explanation to why it happens when the postmaster is idle. I used the win32 installer defaults so autovacuum is p

Re: [HACKERS] Socket problem using beta2 on Windows-XP

2005-09-29 Thread Magnus Hagander
> > 2. It happens while the postmaster is idle. If I leave it > idle for a > > while and then come back, I'll have a whole bunch of new > processes in > > my task-manager and zombies in tcpview. > > Hmm ... how many processes? Did you enable autovacuum > perchance? If so, does the number of

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Luke Lonergan
Jeff, On 9/29/05 10:44 AM, "Jeffrey W. Baker" <[EMAIL PROTECTED]> wrote: > On Thu, 2005-09-29 at 10:06 -0700, Luke Lonergan wrote: > Looking through tuplesort.c, I have a couple of initial ideas. Are we > allowed to fork here? That would open up the possibility of using the > CPU and the I/O in

Re: [HACKERS] GSSAPI or Kerberos authentication problems

2005-09-29 Thread Kris Jurka
Mike Warnecke wrote: Does the postgresql-jdbc driver support Kerberos/GSSAPI authentication? If not, what is required to get it done? Doing a little further reading and testing shows that the server would need to be extended to provide GSSAPI support even though the underlying authenticati

Re: [HACKERS] Socket problem using beta2 on Windows-XP

2005-09-29 Thread Alvaro Herrera
On Thu, Sep 29, 2005 at 11:43:37PM +0200, Thomas Hallgren wrote: > 2. It happens while the postmaster is idle. If I leave it idle for a > while and then come back, I'll have a whole bunch of new processes in my > task-manager and zombies in tcpview. Hmm ... how many processes? Did you enable a

Re: [HACKERS] Found small issue with OUT params

2005-09-29 Thread Tom Lane
Mike Rylander <[EMAIL PROTECTED]> writes: > Using that logic, a functions with one OUT param would be the same as > a function returning a rowtype with only one column, But it's not (and no, I don't want to make it so, because the overhead for the useless record result would be significant).

Re: [HACKERS] Found small issue with OUT params

2005-09-29 Thread Mike Rylander
On 9/29/05, Tom Lane <[EMAIL PROTECTED]> wrote: > Tony Caduto <[EMAIL PROTECTED]> writes: > > Please don't take this the wrong way, but don't you think even if a > > single param is declared as OUT it should return the name of the OUT param? > > Not really, because "create function foo (in x int, o

Re: [HACKERS] pg_total_relation_size() could not open relation with OID X

2005-09-29 Thread Alvaro Herrera
I wrote: > The code is obviously confused between Oid and relfilenode. The > calculate_total_relation_size() function gets a relfilenode parameter > and then tries to call relation_open() with it. This is wrong. This is the patch I'm about to apply. Besides fixing this particular problem, I ma

Re: [HACKERS] Socket problem using beta2 on Windows-XP

2005-09-29 Thread Thomas Hallgren
Hi, I'm Sorry, Time was short today. To answer your questions. 1. I can run a psql and other client programs. Everything works fine. But while doing it, I get a lot of zombies in the tcpview and eventually, I think I run out of ports. Psql just hangs when I try to connect. When that happens, I

Re: [HACKERS] pgbench: undefined reference to strndup()

2005-09-29 Thread Tatsuo Ishii
> Michael Fuhr <[EMAIL PROTECTED]> writes: > > A recent pgbench commit causes build failures due to an undefined > > reference to strndup(), at least on FreeBSD and UnixWare: Oops. > Yeah, breaks on HPUX too. Patch applied. Thanks. -- SRA OSS, Inc. Japan Tatsuo Ishii --

Re: [HACKERS] Open items list

2005-09-29 Thread Bruce Momjian
We are basically on hold until we can resolve these items. We need a beta3, but some of these items might require an initdb (ALTER SCHEMA RENAME and ROLES), so until we resolve them, we can't go for beta3 and can't get to an RC candidate. I know Tom is busy right now, but I know we will get ther

Re: [HACKERS] Socket problem using beta2 on Windows-XP

2005-09-29 Thread Magnus Hagander
Hmm. Bummer. Anyway. The netstat indicates that the pipe() call works. The order is pretty much: parent: create socket pair, connected to each other. parent: Duplicate socket [this is what fails] parent: close own copy of socket child: recreate socket from structure [this is never called, thus t

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Dann Corbit
If I were to be nosy and poke around in this, what patches of code would I be interested in? > -Original Message- > From: [EMAIL PROTECTED] [mailto:pgsql-hackers- > [EMAIL PROTECTED] On Behalf Of Josh Berkus > Sent: Thursday, September 29, 2005 11:28 AM > To: pgsql-hackers@postgresql.org >

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Josh Berkus
Jeff, > I would just run it under the profiler and see how many times > beginmerge() is called. Hmm, I'm not seeing it at all in the oprofile results on a 100million-row sort. -- --Josh Josh Berkus Aglio Database Solutions San Francisco ---(end of broadcast)--

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Jeffrey W. Baker
On Thu, 2005-09-29 at 11:03 -0700, Josh Berkus wrote: > Jeff, > > > Josh, do you happen to know how many passes are needed in the multiphase > > merge on your 60GB table? > > No, any idea how to test that? I would just run it under the profiler and see how many times beginmerge() is called. -jw

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Josh Berkus
Jeff, > Josh, do you happen to know how many passes are needed in the multiphase > merge on your 60GB table? No, any idea how to test that? > I think the largest speedup will be to dump the multiphase merge and > merge all tapes in one pass, no matter how large M. Currently M is > capped at 6,

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Jeffrey W. Baker
On Thu, 2005-09-29 at 10:06 -0700, Luke Lonergan wrote: > Josh, > > On 9/29/05 9:54 AM, "Josh Berkus" wrote: > > > Following an index creation, we see that 95% of the time required is the > > external sort, which averages 2mb/s. This is with seperate drives for > > the WAL, the pg_tmp, the tabl

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread David Fetter
On Thu, Sep 29, 2005 at 10:06:52AM -0700, Luke Lonergan wrote: > Josh, > > On 9/29/05 9:54 AM, "Josh Berkus" wrote: > > > Following an index creation, we see that 95% of the time required > > is the external sort, which averages 2mb/s. This is with seperate > > drives for the WAL, the pg_tmp, t

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Luke Lonergan
Josh, On 9/29/05 9:54 AM, "Josh Berkus" wrote: > Following an index creation, we see that 95% of the time required is the > external sort, which averages 2mb/s. This is with seperate drives for > the WAL, the pg_tmp, the table and the index. I've confirmed that > increasing work_mem beyond a s

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Josh Berkus
Jeff, Ron, First off, Jeff, please take it easy. We're discussing 8.2 features at this point and there's no reason to get stressed out at Ron. You can get plenty stressed out when 8.2 is near feature freeze. ;-) Regarding use cases for better sorts: The biggest single area where I see Po

Re: [HACKERS] effective SELECT from child tables

2005-09-29 Thread Josh Berkus
Ilia, Well, Simon is still writing the CE docs. In the meantime: http://archives.postgresql.org/pgsql-hackers/2005-07/msg00461.php --josh ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose

Re: [HACKERS] pgbench: undefined reference to strndup()

2005-09-29 Thread Tom Lane
Michael Fuhr <[EMAIL PROTECTED]> writes: > A recent pgbench commit causes build failures due to an undefined > reference to strndup(), at least on FreeBSD and UnixWare: Yeah, breaks on HPUX too. Patch applied. regards, tom lane ---(end of broadcas

Re: [HACKERS] postgresql clustering

2005-09-29 Thread Luke Lonergan
Daniel, >From what I've researched, the concepts and practices seem to fall > under one of two abstract categorizations: fail-over (ok... > high-availability), and parallel execution (high-performance... sure). > While some consider the implementation of only one of these to qualify > a cluster, o

Re: [HACKERS] postgresql clustering

2005-09-29 Thread Tino Wildenhain
Jonah H. Harris schrieb: On 9/29/05, *Tino Wildenhain* <[EMAIL PROTECTED] > wrote: Well, I dont know why many people believe parallel execution automatically means high performance. Actually most of the time the performance is much worser this way. If y

[HACKERS] pgbench: undefined reference to strndup()

2005-09-29 Thread Michael Fuhr
A recent pgbench commit causes build failures due to an undefined reference to strndup(), at least on FreeBSD and UnixWare: http://pgbuildfarm.org/cgi-bin/show_log.pl?nm=echidna&dt=2005-09-29%2014:30:01 http://pgbuildfarm.org/cgi-bin/show_log.pl?nm=firefly&dt=2005-09-29%2014:27:00 I don't see str

Re: [HACKERS] postgresql clustering

2005-09-29 Thread Gaetano Mendola
Daniel Duvall wrote: > While "clustering" in some circles may be an open-ended buzzword -- > mainly the commercial DB marketing crowd -- there are concepts beneath > the bull that are even inherent in the name. However, I understand > your point. > >>From what I've researched, the concepts and pr

Re: [HACKERS] [DOCS] Added documentation about caching, reliability

2005-09-29 Thread Bruce Momjian
Peter Eisentraut wrote: > Bruce Momjian wrote: > > Well, now the chapter is about WAL and reliability, so I thought > > reliability hit both topics. Also, maybe we should consider moving > > this FAQ item into the docs: > > > > 3.7) What computer hardware should I > > use? > > Hardware choice

Re: [HACKERS] Found small issue with OUT params

2005-09-29 Thread Tony Caduto
Tom Lane wrote: Tony Caduto <[EMAIL PROTECTED]> writes: Please don't take this the wrong way, but don't you think even if a single param is declared as OUT it should return the name of the OUT param? Not really, because "create function foo (in x int, out y float)" is supposed to have

Re: [HACKERS] [DOCS] Added documentation about caching, reliability

2005-09-29 Thread Peter Eisentraut
Bruce Momjian wrote: > Well, now the chapter is about WAL and reliability, so I thought > reliability hit both topics. Also, maybe we should consider moving > this FAQ item into the docs: > > 3.7) What computer hardware should I > use? Hardware choice and configuration are important topics, b

Re: [HACKERS] PCTFree Results

2005-09-29 Thread Jonah H. Harris
Has there been any movement on this?  If not, I finally have some time to look at it. On 9/23/05, Jim C. Nasby <[EMAIL PROTECTED]> wrote: On Thu, Sep 22, 2005 at 10:05:57PM -0400, Tom Lane wrote:> With respect to the original point, I'm pretty nervous about either> accepting or rejecting a perform

Re: [HACKERS] postgresql clustering

2005-09-29 Thread Jonah H. Harris
On 9/29/05, Tino Wildenhain <[EMAIL PROTECTED]> wrote: Well, I dont know why many people believe parallel executionautomatically means high performance. Actually most of the timethe performance is much worser this way.If your dataset remains statically and you do only read-only requets, you get hig

Re: [HACKERS] [DOCS] Added documentation about caching, reliability

2005-09-29 Thread Bruce Momjian
Peter Eisentraut wrote: > Am Mittwoch, 28. September 2005 20:26 schrieb Bruce Momjian: > > I also renamed the chapter "Reilability" rather than "WAL." > > Considering that the chapter is, in fact, all about WAL, I don't think this > is > a good move. Reliability is a concern that is not only ad

Re: [HACKERS] [PATCHES] Proposed patch for sequence-renaming problems

2005-09-29 Thread Bruce Momjian
Martijn van Oosterhout wrote: -- Start of PGP signed section. > On Wed, Sep 28, 2005 at 10:41:12PM -0400, Bruce Momjian wrote: > > > > Also, why is the nextval ::text casting output by pg_dump anyway? > > AFAICS, pg_dump outputs "serial" (at least in 7.4.7 which is what I > have to hand) when it

Re: [HACKERS] pg_total_relation_size() could not open relation with OID X

2005-09-29 Thread Alvaro Herrera
On Wed, Sep 28, 2005 at 10:25:16PM -0600, Michael Fuhr wrote: > test=> TRUNCATE foo; > TRUNCATE TABLE > test=> SELECT oid, relfilenode FROM pg_class WHERE relname = 'foo'; > oid | relfilenode > ---+- > 26235 | 26237 > (1 row) The code is obviously confused between Oid a

Re: [HACKERS] postgresql clustering

2005-09-29 Thread Tino Wildenhain
Daniel Duvall schrieb: While "clustering" in some circles may be an open-ended buzzword -- mainly the commercial DB marketing crowd -- there are concepts beneath the bull that are even inherent in the name. However, I understand your point. From what I've researched, the concepts and practices

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Zeugswetter Andreas DAZ SD
> In my original example, a sequential scan of the 1TB of 2KB > or 4KB records, => 250M or 500M records of data, being sorted > on a binary value key will take ~1000x more time than reading > in the ~1GB Btree I described that used a Key+RID (plus node > pointers) representation of the data.

Re: [HACKERS] Query in SQL statement

2005-09-29 Thread Christopher Kings-Lynne
CREATE SEQUENCE ai_id; CREATE TABLE badusers ( id int DEFAULT nextval('ai_id') NOT NULL, UserName varchar(30), Date datetime DEFAULT '-00-00 00:00:00' NOT NULL, Reason varchar(200), Admin varchar(30) DEFAULT '-', PRIMARY KEY (id), KEY UserName (UserName), KEY Date (Date) );

Re: [HACKERS] Query in SQL statement

2005-09-29 Thread Obe, Regina DND\\MIS
I think this question may be more appropriate for [EMAIL PROTECTED] Anyrate for the below. Sounds like you maybe already have a table or sequence called ai_id; Try doing a DROP SEQUENCE ai_id; First Also if you plan to use this sequence only for this table it would be better to use serial8 whi

[HACKERS] Query in SQL statement

2005-09-29 Thread R, Rajesh (STSD)
Am trying to port a mysql statement to postgres. Please help me in finding the error in this, CREATE SEQUENCE ai_id; CREATE TABLE badusers ( id int DEFAULT nextval('ai_id') NOT NULL, UserName varchar(30), Date datetime DEFAULT '-00-00 00:00:00' NOT NULL, Reason varchar(200), Adm

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Ron Peacetree
In the interest of efficiency and "not reinventing the wheel", does anyone know where I can find C or C++ source code for a Btree variant with the following properties: A= Data elements (RIDs) are only stored in the leaves, Keys (actually KeyPrefixes; see "D" below) and Node pointers are only stor

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Ron Peacetree
>From: "Jeffrey W. Baker" <[EMAIL PROTECTED]> >Sent: Sep 27, 2005 1:26 PM >To: Ron Peacetree <[EMAIL PROTECTED]> >Subject: Re: [HACKERS] [PERFORM] A Better External Sort? > >On Tue, 2005-09-27 at 13:15 -0400, Ron Peacetree wrote: > >>That Btree can be used to generate a physical reordering of the d

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Ron Peacetree
>From: "Jeffrey W. Baker" <[EMAIL PROTECTED]> >Sent: Sep 29, 2005 12:27 AM >To: Ron Peacetree <[EMAIL PROTECTED]> >Cc: pgsql-hackers@postgresql.org, pgsql-performance@postgresql.org >Subject: Re: [HACKERS] [PERFORM] A Better External Sort? > >You are engaging in a length and verbose exercise in men

Re: [HACKERS] postgresql clustering

2005-09-29 Thread Daniel Duvall
While "clustering" in some circles may be an open-ended buzzword -- mainly the commercial DB marketing crowd -- there are concepts beneath the bull that are even inherent in the name. However, I understand your point. >From what I've researched, the concepts and practices seem to fall under one o

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Ron Peacetree
If I've done this correctly, there should not be anywhere near the number of context switches we currently see while sorting. Each unscheduled context switch represents something unexpected occuring or things not being where they are needed when they are needed. Reducing such circumstances to the

Re: [HACKERS] Constraint exclusion, some questions

2005-09-29 Thread Hannu Krosing
On N, 2005-09-29 at 11:24 +0200, [EMAIL PROTECTED] wrote: > Hi, I'm testing constraint exclusion on PostgreSQL 8.1 beta 1 on windows with > the GEOIP countries database and I have a few questions: > > 1. Can I say that an index created on the "parent" table is a "global" index, > an index that spa

Re: [HACKERS] [PERFORM] A Better External Sort?

2005-09-29 Thread Pailloncy Jean-Gerard
Your main example seems to focus on a large table where a key column has constrained values. This case is interesting in proportion to the number of possible values. If I have billions of rows, each having one of only two values, I can think of a trivial and very fast method of returning th

[HACKERS] Release build scripts

2005-09-29 Thread Peter Eisentraut
Can I see the scripts that build the releases? I've just tried to run "make dist" but the INSTALL and HISTORY files weren't built, so I wonder how that is done and I would like that to be moved to the makefiles so that the process is controlled from one place. Also, the INSTALL file looks terr

[HACKERS] Constraint exclusion, some questions

2005-09-29 Thread pmagnoli
Hi, I'm testing constraint exclusion on PostgreSQL 8.1 beta 1 on windows with the GEOIP countries database and I have a few questions: 1. Can I say that an index created on the "parent" table is a "global" index, an index that spans over data in all derived tables? 2. Can I say that an index creat

Re: [HACKERS] Socket problem using beta2 on Windows-XP

2005-09-29 Thread Martijn van Oosterhout
On Thu, Sep 29, 2005 at 08:50:30AM +0200, Thomas Hallgren wrote: > Hi, > I've installed PostgreSQL 8.1-beta2 as a service on my Windows-XP box. > It runs fine but I get repeated messages like this in the log: > > 2005-09-29 00:41:09 FATAL: could not duplicate socket 1880 for use > in backend:

Re: [HACKERS] [PATCHES] Proposed patch for sequence-renaming problems

2005-09-29 Thread Martijn van Oosterhout
On Wed, Sep 28, 2005 at 10:41:12PM -0400, Bruce Momjian wrote: > > Also, why is the nextval ::text casting output by pg_dump anyway? AFAICS, pg_dump outputs "serial" (at least in 7.4.7 which is what I have to hand) when it should meaning that dumps restored will get the new syntax anyway. Or am I

Re: [HACKERS] Socket problem using beta2 on Windows-XP

2005-09-29 Thread Thomas Hallgren
Nope, no anti-virus and no firewall (other then the box that fronts my home-network to the outside world). - thomas Magnus Hagander wrote: Hi, I've installed PostgreSQL 8.1-beta2 as a service on my Windows-XP box. It runs fine but I get repeated messages like this in the log: 2005-09-29

Re: [HACKERS] Socket problem using beta2 on Windows-XP

2005-09-29 Thread Magnus Hagander
> Hi, > I've installed PostgreSQL 8.1-beta2 as a service on my > Windows-XP box. > It runs fine but I get repeated messages like this in the log: > >2005-09-29 00:41:09 FATAL: could not duplicate socket > 1880 for use in backend: error code 10038 > > and for each message printed, a new po