Skip site navigation (1) Skip section navigation (2)

Re: BUG #4941: pg_stat_statements crash

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Itagaki Takahiro <itagaki(dot)takahiro(at)oss(dot)ntt(dot)co(dot)jp>
Cc: "" <alr(dot)nospamforme(at)gmail(dot)com>, pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #4941: pg_stat_statements crash
Date: 2009-07-27 02:28:18
Message-ID: 21301.1248661698@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-bugspgsql-hackers
Itagaki Takahiro <itagaki(dot)takahiro(at)oss(dot)ntt(dot)co(dot)jp> writes:
> We should call [Read dumpfile] routine only once even on Windows.

Seems to me that you should simply do the load only when found is false.

> How about executing the routine during AddinShmemInitLock is taken?

You should not hold AddinShmemInitLock any longer than really necessary.
I don't think there is a need for locking here anyway, though, since
found should be false only in the postmaster.

> The best solution might be to call shmem_startup_hook only once
> every platforms, but it is difficult without fork().

We're not changing that.  This is a bug in pgss_shmem_startup.

			regards, tom lane

In response to

Responses

pgsql-hackers by date

Next:From: Robert HaasDate: 2009-07-27 02:52:24
Subject: Re: generic explain options v3
Previous:From: Itagaki TakahiroDate: 2009-07-27 02:11:19
Subject: Re: BUG #4941: pg_stat_statements crash

pgsql-bugs by date

Next:From: Federico AguirreDate: 2009-07-27 02:33:43
Subject: BUG #4942: edb_apachephp.bin error
Previous:From: Itagaki TakahiroDate: 2009-07-27 02:11:19
Subject: Re: BUG #4941: pg_stat_statements crash

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group