Re: [HACKERS] Fix pgstattuple/pgstatindex to use regclass-type as the argument

2013-07-16 Thread Satoshi Nagayasu
(2013/07/04 3:58), Fujii Masao wrote: On Wed, Jun 26, 2013 at 12:39 AM, Robert Haas robertmh...@gmail.com wrote: On Thu, Jun 20, 2013 at 2:32 PM, Fujii Masao masao.fu...@gmail.com wrote: Since pg_relpages(oid) doesn't exist, pg_relpages() is in the same situation as pgstatindex(), i.e., we

Re: [HACKERS] Fix pgstattuple/pgstatindex to use regclass-type as the argument

2013-07-16 Thread Satoshi Nagayasu
Hi Rushabh, (2013/07/16 14:58), Rushabh Lathia wrote: Hello Satoshi, I assigned myself for the reviewer of this patch. Issue status is waiting on author. Thank you for picking it up. Now looking at the discussion under the thread it seems like we are waiting for the suggestion for the new

[HACKERS] make dist error

2013-07-16 Thread Tatsuo Ishii
I'm getting errors while executing make dist on git master head. $ make dist make dist rm -rf postgresql-9.4devel* =install= for x in `cd . find . \( -name CVS -prune \) -o \( -name .git -prune \) -o -print`; do \ file=`expr X$x : 'X\./\(.*\)'`; \ if test -d ./$file ; then \

Re: [HACKERS] Add visibility map information to pg_freespace.

2013-07-16 Thread Satoshi Nagayasu
(2013/07/09 19:55), Kyotaro HORIGUCHI wrote: Hello, I've brought visibilitymap extentions for pg_freespacemap and pgstattuple. At Mon, 08 Jul 2013 16:59:05 +0900 (Tokyo Standard Time), Kyotaro HORIGUCHI horiguchi.kyot...@lab.ntt.co.jp wrote in

Re: [HACKERS] [PATCH] pgbench --throttle (submission 7 - with lag measurement)

2013-07-16 Thread Tatsuo Ishii
To clarify what state this is all in: Fabien's latest pgbench-throttle-v15.patch is the ready for a committer version. The last two revisions are just tweaking the comments at this point, and his version is more correct than my last one. Got it. I will take care of this. -- Tatsuo Ishii SRA

Re: [HACKERS] Fix pgstattuple/pgstatindex to use regclass-type as the argument

2013-07-16 Thread Rushabh Lathia
Hi Satoshi, I spent some time on the revised version on the patch(pgstattuple_regclass_v2.diff) and here are my comments. .) Patch get applies cleanly on PG master branch .) Successful build and database creation .) Basic test coverage included in the patch .) make check running cleanly

[HACKERS] A general Q about index

2013-07-16 Thread Soroosh Sardari
Hi I want to know how an index is created and used. actually if you can show to me a simple start point, it would be great. Regards, Soroosh Sardari

Re: [HACKERS] changeset generation v5-01 - Patches git tree

2013-07-16 Thread Robert Haas
On Sun, Jul 7, 2013 at 4:34 PM, Andres Freund and...@2ndquadrant.com wrote: On 2013-07-07 15:43:17 -0400, Tom Lane wrote: Andres Freund and...@2ndquadrant.com writes: 3b) Add catcache 'filter' that ensures the cache stays unique and use that for the mapping I slightly prefer 3b)

[HACKERS] findDependentObjects() mutual exclusion vs. MVCC catalog scans

2013-07-16 Thread Noah Misch
Consider this sequence of commands: create type rowtype as (c int, d int); create temp table t of rowtype; \c - drop type rowtype cascade; Since the switch to MVCC catalog scans, it exhibits the following error about 10% of the time on my system: CREATE TYPE CREATE TABLE You are

Re: [HACKERS] make dist error

2013-07-16 Thread Andrew Dunstan
On 07/16/2013 02:53 AM, Tatsuo Ishii wrote: I'm getting errors while executing make dist on git master head. $ make dist make dist rm -rf postgresql-9.4devel* =install= for x in `cd . find . \( -name CVS -prune \) -o \( -name .git -prune \) -o -print`; do \ file=`expr X$x :

Re: [HACKERS] make dist error

2013-07-16 Thread Tatsuo Ishii
It's working for me: ... /bin/tar chf postgresql-9.4devel.tar postgresql-9.4devel gzip --best -c postgresql-9.4devel.tar postgresql-9.4devel.tar.gz bzip2 -c postgresql-9.4devel.tar postgresql-9.4devel.tar.bz2 rm -rf postgresql-9.4devel It looks like your source directory

Re: [HACKERS] make dist error

2013-07-16 Thread Andrew Dunstan
On 07/16/2013 09:53 AM, Andrew Dunstan wrote: On 07/16/2013 02:53 AM, Tatsuo Ishii wrote: I'm getting errors while executing make dist on git master head. $ make dist make dist rm -rf postgresql-9.4devel* =install= for x in `cd . find . \( -name CVS -prune \) -o \( -name .git -prune \) -o

Re: [HACKERS] A general Q about index

2013-07-16 Thread David Johnston
soroosh sardari wrote Hi I want to know how an index is created and used. actually if you can show to me a simple start point, it would be great. Regards, Soroosh Sardari In the documentation there is a table of contents and listed on that table is a section named Indexes. David J.

Re: [HACKERS] A general Q about index

2013-07-16 Thread David Johnston
David Johnston wrote soroosh sardari wrote Hi I want to know how an index is created and used. actually if you can show to me a simple start point, it would be great. Regards, Soroosh Sardari In the documentation there is a table of contents and listed on that table is a section

Re: [HACKERS] findDependentObjects() mutual exclusion vs. MVCC catalog scans

2013-07-16 Thread Robert Haas
On Tue, Jul 16, 2013 at 9:50 AM, Noah Misch n...@leadboat.com wrote: Consider this sequence of commands: create type rowtype as (c int, d int); create temp table t of rowtype; \c - drop type rowtype cascade; Since the switch to MVCC catalog scans, it exhibits the following

Re: [HACKERS] findDependentObjects() mutual exclusion vs. MVCC catalog scans

2013-07-16 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: On Tue, Jul 16, 2013 at 9:50 AM, Noah Misch n...@leadboat.com wrote: Let's fix this by having systable_recheck_tuple() acquire a fresh catalog MVCC snapshot and recheck against that. I believe it would also be fully safe to use SnapshotNow here;

Re: [HACKERS] make dist error

2013-07-16 Thread Peter Eisentraut
On 7/16/13 10:03 AM, Andrew Dunstan wrote: Incidentally, the buildfarm animal guaibasaurus builds make dist every build, via a bespoke buildfarm module. See for example http://www.pgbuildfarm.org/cgi-bin/show_stage_log.pl?nm=guaibasaurusdt=2013-07-16%2004%3A17%3A01stg=make-dist, so we should

Re: [HACKERS] Differences in WHERE clause of SELECT

2013-07-16 Thread Robert Haas
On Tue, Jul 9, 2013 at 7:12 PM, Josh Berkus j...@agliodbs.com wrote: Like uses the operator class text_pattern_ops which doesn't include an implict cast. This is wrong. Casts are associated with data types, not operator classes. For one thing, the implicit cast is from text -- integer, not

Re: [HACKERS] findDependentObjects() mutual exclusion vs. MVCC catalog scans

2013-07-16 Thread Andres Freund
On 2013-07-16 09:50:07 -0400, Noah Misch wrote: With \c, in general, you may end up executing commands under the new session before the old backend has finished exiting. For this test case specifically, the two backends' attempts to drop table t regularly overlap. The old backend would drop

Re: [HACKERS] SSL renegotiation

2013-07-16 Thread Robert Haas
On Fri, Jul 12, 2013 at 8:51 PM, Noah Misch n...@leadboat.com wrote: On Fri, Jul 12, 2013 at 04:32:52PM -0400, Alvaro Herrera wrote: Now, should we support the 0.9.6-and-earlier mechanism? My inclination is no; even RHEL 3, the oldest supported Linux distribution, uses 0.9.7 (Heck, even Red

Re: [HACKERS] Differences in WHERE clause of SELECT

2013-07-16 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: I continue to be of the opinion that our behavior in this area is bone-headed. It's reasonable to reject integer = character varying on the basis that we don't know whether integer or character varying comparison semantics are wanted, and the two

Re: [HACKERS] checking variadic any argument in parser - should be array

2013-07-16 Thread Pavel Stehule
2013/7/15 Andrew Dunstan and...@dunslane.net: On 07/14/2013 12:28 AM, Pavel Stehule wrote: Hello 2013/7/14 Andrew Dunstan and...@dunslane.net: On 06/29/2013 03:29 PM, Pavel Stehule wrote: 5. This patch has user visibility, i.e. now we are throwing an error when user only says

Re: [HACKERS] Improvement of checkpoint IO scheduler for stable transaction responses

2013-07-16 Thread Ants Aasma
On Jul 14, 2013 9:46 PM, Greg Smith g...@2ndquadrant.com wrote: I updated and re-reviewed that in 2011: http://www.postgresql.org/message-id/4d31ae64.3000...@2ndquadrant.com and commented on why I think the improvement was difficult to reproduce back then. The improvement didn't follow for

Re: [HACKERS] Differences in WHERE clause of SELECT

2013-07-16 Thread Greg Stark
On Tue, Jul 16, 2013 at 4:40 PM, Robert Haas robertmh...@gmail.com wrote: But '1' LIKE 1 is not ambiguous What about '1' LIKE 01 ? What do people who write this actually expect LIKE to do? I gather they're actually treating it as a synonym for =? -- greg -- Sent via pgsql-hackers

Re: [HACKERS] dynamic background workers

2013-07-16 Thread Robert Haas
On Wed, Jul 3, 2013 at 11:15 AM, Alvaro Herrera alvhe...@2ndquadrant.com wrote: Andres Freund escribió: Just as a datapoint, if you benchmark the numbers of forks that can be performed by a single process (i.e. postmaster) the number is easily in the 10s of thousands. Now forking that much has

Re: [HACKERS] findDependentObjects() mutual exclusion vs. MVCC catalog scans

2013-07-16 Thread Noah Misch
On Tue, Jul 16, 2013 at 05:56:10PM +0200, Andres Freund wrote: On 2013-07-16 09:50:07 -0400, Noah Misch wrote: With \c, in general, you may end up executing commands under the new session before the old backend has finished exiting. For this test case specifically, the two backends'

Re: [HACKERS] SSL renegotiation

2013-07-16 Thread David Fetter
On Fri, Jul 12, 2013 at 08:51:52PM -0400, Noah Misch wrote: On Fri, Jul 12, 2013 at 04:32:52PM -0400, Alvaro Herrera wrote: Now, should we support the 0.9.6-and-earlier mechanism? My inclination is no; even RHEL 3, the oldest supported Linux distribution, uses 0.9.7 (Heck, even Red Hat

Re: [HACKERS] Differences in WHERE clause of SELECT

2013-07-16 Thread Robert Haas
On Tue, Jul 16, 2013 at 12:05 PM, Tom Lane t...@sss.pgh.pa.us wrote: I don't agree with this opinion. I know. '1' + '2' might be claimed to have only one plausible meaning as well, but that doesn't mean that we should accept it. That example clearly has multiple sensible interpretations,

Re: [HACKERS] Improvement of checkpoint IO scheduler for stable transaction responses

2013-07-16 Thread Greg Smith
On 7/16/13 12:46 PM, Ants Aasma wrote: Spread checkpoints sprinkles the writes out over a long period and the general tuning advice is to heavily bound the amount of memory the OS willing to keep dirty. That's arguing that you can make this feature be useful if you tune in a particular way.

Re: [HACKERS] A general Q about index

2013-07-16 Thread Soroosh Sardari
On Tue, Jul 16, 2013 at 7:00 PM, David Johnston pol...@yahoo.com wrote: David Johnston wrote soroosh sardari wrote Hi I want to know how an index is created and used. actually if you can show to me a simple start point, it would be great. Regards, Soroosh Sardari In the

Re: [HACKERS] Differences in WHERE clause of SELECT

2013-07-16 Thread Merlin Moncure
On Tue, Jul 16, 2013 at 12:58 PM, Robert Haas robertmh...@gmail.com wrote: PostgreSQL requires more casts that any other mainstream database system on the planet, and it's one of the biggest barriers to migrating from other database systems to PostgreSQL. I understand that there is a

Re: [HACKERS] Proposal: template-ify (binary) extensions

2013-07-16 Thread Markus Wanner
On 07/16/2013 01:27 AM, Robert Haas wrote: Andres points out that you can install adminpack to obtain local filesystem access, and that is true. But the system administrator can also refuse to allow adminpack, and/or use selinux or other mechanisms to prevent the postgres binary from writing

Re: [HACKERS] Differences in WHERE clause of SELECT

2013-07-16 Thread Robert Haas
On Tue, Jul 16, 2013 at 2:58 PM, Merlin Moncure mmonc...@gmail.com wrote: On Tue, Jul 16, 2013 at 12:58 PM, Robert Haas robertmh...@gmail.com wrote: PostgreSQL requires more casts that any other mainstream database system on the planet, and it's one of the biggest barriers to migrating from

Re: [HACKERS] Proposal: template-ify (binary) extensions

2013-07-16 Thread Robert Haas
On Tue, Jul 16, 2013 at 3:14 PM, Markus Wanner mar...@bluegap.ch wrote: But okay, you're saying we *have* and *want* a guarantee that even a superuser cannot execute arbitrary native code via libpq (at least in default installs w/o extensions). Yes, that's a good way of summarizing my

Re: [HACKERS] review: Non-recursive processing of AND/OR lists

2013-07-16 Thread Pavel Stehule
Hello 2013/7/15 Gurjeet Singh gurj...@singh.im: On Sun, Jul 14, 2013 at 8:27 PM, Robert Haas robertmh...@gmail.com wrote: On Wed, Jul 10, 2013 at 9:02 PM, Josh Berkus j...@agliodbs.com wrote: I think it's a waste of code to try to handle bushy trees. A list is not a particularly efficient

Re: [HACKERS] Differences in WHERE clause of SELECT

2013-07-16 Thread Kevin Grittner
Robert Haas robertmh...@gmail.com wrote: We can certainly continue to play whack-a-mole and dream up a new solution every time a really intolerable variant of this problem comes up.  But that doesn't seem good to me.  It means that every case behaves a little different from every other case,

Re: [HACKERS] pg_memory_barrier() doesn't compile, let alone work, for me

2013-07-16 Thread Martijn van Oosterhout
On Sun, Jul 14, 2013 at 09:26:38PM -0400, Robert Haas wrote: I'm pretty sure we've got latent memory-ordering risks in our existing code which we just haven't detected and fixed yet. Consider, for example, this exciting code from GetNewTransactionId:

Re: [HACKERS] Proposal - Support for National Characters functionality

2013-07-16 Thread Martijn van Oosterhout
On Mon, Jul 15, 2013 at 05:11:40PM +0900, Tatsuo Ishii wrote: Does support for alternative multi-byte encodings have something to do with the Han unification controversy? I don't know terribly much about this, so apologies if that's just wrong. There's a famous problem regarding

Re: [HACKERS] pg_filedump 9.3: checksums (and a few other fixes)

2013-07-16 Thread Josh Berkus
On 07/08/2013 04:59 PM, Tom Lane wrote: Alvaro Herrera alvhe...@2ndquadrant.com writes: Well, Tom opined in http://www.postgresql.org/message-id/23249.1370878...@sss.pgh.pa.us that the current patch is okay. I have a mild opinion that it should instead print only SHR_LOCK when both bits are

Re: [HACKERS] Re: patch submission: truncate trailing nulls from heap rows to reduce the size of the null bitmap [Review]

2013-07-16 Thread Josh Berkus
On 07/11/2013 09:28 AM, Greg Stark wrote: Neither of these address Tom's concerns about API changes and future flexibility. I was assigned this patch in the rreviewers list and my inclination would be to take it but I wasn't about to overrule Tom. If he says he's ok with it then I'm fine going

Re: [HACKERS] pg_filedump 9.3: checksums (and a few other fixes)

2013-07-16 Thread Tom Lane
Josh Berkus j...@agliodbs.com writes: On 07/08/2013 04:59 PM, Tom Lane wrote: FWIW, I think that's exactly what I did in the preliminary 9.3 patch that I committed to pg_filedump a few weeks ago. Could you take a look at what's there now and see if that's what you meant? So, is this getting

Re: [Review] Re: [HACKERS] minor patch submission: CREATE CAST ... AS EXPLICIT

2013-07-16 Thread Josh Berkus
On 07/09/2013 01:10 AM, Fabien COELHO wrote: Where are we with this patch? Fabien, are you going to submit an updated version which addresses the objections, or should I mark it Returned With Feedback? There is no need for an updated patch. I addressed the objections with words, not

Re: [Review] Re: [HACKERS] minor patch submission: CREATE CAST ... AS EXPLICIT

2013-07-16 Thread Tom Lane
Josh Berkus j...@agliodbs.com writes: On 07/09/2013 01:10 AM, Fabien COELHO wrote: Where are we with this patch? Fabien, are you going to submit an updated version which addresses the objections, or should I mark it Returned With Feedback? There is no need for an updated patch. I addressed

[HACKERS] [9.4 CF 1] SDO: Patches for Review

2013-07-16 Thread Josh Berkus
Hackers, As the Commitfest is past deadline, here is the disposition of 15 patches which were still marked Needs Review: Needs Review The following patches have not had even one substantial review. Please someone pick them up and review them ASAP: - Row-Level Security - KaiGai

Re: [Review] Re: [HACKERS] minor patch submission: CREATE CAST ... AS EXPLICIT

2013-07-16 Thread Josh Berkus
On 07/16/2013 03:12 PM, Tom Lane wrote: Josh Berkus j...@agliodbs.com writes: On 07/09/2013 01:10 AM, Fabien COELHO wrote: Where are we with this patch? Fabien, are you going to submit an updated version which addresses the objections, or should I mark it Returned With Feedback? There is

[HACKERS] [9.4 CF 1]SDO: Patches awaiting Author

2013-07-16 Thread Josh Berkus
Hackers, The following patches were Waiting on Author as of today. As such, most have been marked returned with feedback. Authors are encouraged to update their patches and submit to the next Commitfest. There are a few exceptions to Returned with feedback, though: Could Not Determine Status:

Re: [HACKERS] XLogInsert scaling, revisited

2013-07-16 Thread Michael Paquier
On Tue, Jul 16, 2013 at 2:24 AM, Fujii Masao masao.fu...@gmail.com wrote: On Mon, Jul 8, 2013 at 6:16 PM, Heikki Linnakangas hlinnakan...@vmware.com wrote: Ok, I've committed this patch now. Finally, phew! I found that this patch causes the assertion failure. When I set up simple replication

Re: [HACKERS] SSL renegotiation

2013-07-16 Thread Noah Misch
On Tue, Jul 16, 2013 at 10:41:44AM -0700, David Fetter wrote: On Fri, Jul 12, 2013 at 08:51:52PM -0400, Noah Misch wrote: Agreed. The OpenSSL Project last applied a security fix to 0.9.6 over eight years ago. Compatibility with 0.9.6 has zero or negative value. You've made a persuasive

Re: [HACKERS] findDependentObjects() mutual exclusion vs. MVCC catalog scans

2013-07-16 Thread Noah Misch
On Tue, Jul 16, 2013 at 11:27:02AM -0400, Robert Haas wrote: I recommend reworking the header comment to avoid mention of SnapshotNow, since if we get rid of SnapshotNow, the reference might not be too clear to far-future hackers. + /* + * For a scan using a non-MVCC snapshot like

Re: [HACKERS] Re: FILTER for aggregates [was Re: Department of Redundancy Department: makeNode(FuncCall) division]

2013-07-16 Thread Noah Misch
On Mon, Jul 15, 2013 at 11:43:04AM -0700, David Fetter wrote: On Sun, Jul 14, 2013 at 10:15:12PM -0400, Noah Misch wrote: See attached patch revisions. The first patch edits find_minmax_aggs_walker() per my comments just now. The second is an update of your FILTER patch with the

[HACKERS] Adding optionally commit number in PG_VERSION_STR

2013-07-16 Thread Michael Paquier
Hi all, It happens that I work occasionally on multiple builds based on different stable branches at the same time to check fixes that need to be backpatched, and I tend to easily lose track on which version the build I created is based on (Duh!). There is of course the version number up to the

Re: [HACKERS] Listen/notify across clusters

2013-07-16 Thread Andreas Karlsson
On 07/15/2013 04:10 PM, Greg Jaskiewicz wrote: In terms of features, apart from separating LISTEN so that it can be actually used on Standbys, wouldn't it be a matter of including the notifications in the WAL stream, as simple packets ? This would guarantee same behaviour as on the master. I

Re: [HACKERS] Adding optionally commit number in PG_VERSION_STR

2013-07-16 Thread Tom Lane
Michael Paquier michael.paqu...@gmail.com writes: It happens that I work occasionally on multiple builds based on different stable branches at the same time to check fixes that need to be backpatched, and I tend to easily lose track on which version the build I created is based on (Duh!).

Re: [HACKERS] Improvement of checkpoint IO scheduler for stable transaction responses

2013-07-16 Thread Ants Aasma
On Tue, Jul 16, 2013 at 9:17 PM, Greg Smith g...@2ndquadrant.com wrote: On 7/16/13 12:46 PM, Ants Aasma wrote: Spread checkpoints sprinkles the writes out over a long period and the general tuning advice is to heavily bound the amount of memory the OS willing to keep dirty. That's arguing

Re: [HACKERS] A general Q about index

2013-07-16 Thread soroosh sardari
On Tue, Jul 16, 2013 at 7:00 PM, David Johnston pol...@yahoo.com wrote: David Johnston wrote soroosh sardari wrote Hi I want to know how an index is created and used. actually if you can show to me a simple start point, it would be great. Regards, Soroosh Sardari In the

Re: [HACKERS] A general Q about index

2013-07-16 Thread Craig Ringer
On 07/16/2013 11:09 PM, soroosh sardari wrote: Actually I mean the index in the source code, I want to know how index is used in the backend for execution of some query. sorry my question is a bit ambiguous, I start to read src/backend/access/index/genam.c, and I think maybe this file is