Re: [PATCHES] pg_regress updates for vc++ bulid
Yes, please. Provided there are no objections and that it looks ok, of course ;-) //Magnus On Tue, Jan 09, 2007 at 05:22:20PM -0500, Bruce Momjian wrote: Would you like this applied? --- Magnus Hagander wrote: Magnus Hagander wrote: Hello! Per some previous discussion that I can't really recall if it was on or off list, here is a WIP patch to make pg_regress run completely outside of msys on win32. The change needed is that the processing of files from input/ and output/ into sql/ and expected/ is moved from the Makefile and into pg_regress itself. I have tested on Win32 non-MSVC and on Linux (non-VPATH), and it appears to work there. Still to be done is the make install part on MSVC build, currently #ifdef:ed out. While working on that, I'd appreciate some comments on the patch in general - if there are more things I need to fix before it can be considered. Particularly I'm concerned around the VPATH stuff, since I've never used that myself. Here's the patch without the WIP tag. It works for me per above, and also for a check (not just installcheck) on msvc built without msys. Again, the vpath part is the one I'm most unsure about, but I'm sure there could be other parts. Hopefully this will make it possible to get the msvc build up on the buildfarm not too long from now. Also, as in the first patch but not noted, this one makes it possible to run the regression tests as an admin account the proper way on both mingw and msvc. //Magnus ---(end of broadcast)--- TIP 7: You can help support the PostgreSQL project by donating at http://www.postgresql.org/about/donate
Re: [pgsql-patches] [HACKERS] [PATCHES] SGML index build fix
Am Mittwoch, 10. Januar 2007 01:41 schrieb Bruce Momjian: Peter Eisentraut wrote: Bruce Momjian wrote: ? %-A4.tex-ps: %.sgml $(ALLSGML) stylesheet.dsl bookindex.sgml ? $(JADE.tex.call) -V texdvi-output -V '%paper-type%'=A4 -o $@ $ + ifndef DRAFT + [EMAIL PROTECTED] -s HTML.index.start HTML.index || $(MAKE) $* + endif What is the point of that? If HTML.index changed during the build, we need to rerun it until it is unchanged. But that rule doesn't change HTML.index. -- Peter Eisentraut http://developer.postgresql.org/~petere/ ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings
Re: [pgsql-patches] [BUGS] xlog lockup patch (was: BUG #2712: could not fsync
Hi. On Mon, 20 Nov 2006 15:33:33 -0500 (EST) Bruce Momjian [EMAIL PROTECTED] wrote: Thomas H. wrote: me wrote: i've loaded 1gb of data without any xlog-problems, whereas with the 8.2b2 executable it locked up after ~100mb. the xlog-files are cycling... if i need to test for some specific behaviour let me know. what's the status on this patch for inclusion in future 8.2 builds? would be nice to see it in b4 or rc1... This was fixed the day after we packaged beta3: revision 1.44 date: 2006/11/08 20:12:05; author: tgl; state: Exp; lines: +20 -48 Change Windows rename and unlink substitutes so that they time out after 30 seconds instead of retrying forever. Also modify xlog.c so that if it fails to rename an old xlog segment up to a future slot, it will unlink the segment instead. Per discussion of bug #2712, in which it became apparent that Windows can handle unlinking a file that's being held open, but not renaming it. beta4 will have the fix. Are there any plan to backport this patch for 8.1/8.0 server ? My customer has same problem in 8.1.5 , but this bug doesn't seems to be fixed in 8.1.6 . Backport patch for 8.1.6 attached. Sorry for replying old mail. -- TANIDA Yutaka [EMAIL PROTECTED] 81_win_xlog_lockup_fix.patch Description: Binary data ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster
Re: [pgsql-patches] [HACKERS] [PATCHES] Last infomask bit
Bruce Momjian wrote: Tom Lane wrote: Bruce Momjian [EMAIL PROTECTED] writes: Patch applied. Thanks. I added a comment about the unused bits in the header file. Has anyone bothered to measure the overhead added by having to mask to fetch or store the natts value? This is not a zero-cost improvement. SHOW ALL has: log_temp_files | -1 | Log the use of temporary files larger than th and pg_settings has: log_temp_files| -1 | kB | Reporting and Logging / What to Log Looks OK to me. What? I'm completely lost here. What does log_temp_files have to do with the bits on the tuple header? -- Heikki Linnakangas EnterpriseDB http://www.enterprisedb.com ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org
Re: [pgsql-patches] [HACKERS] [PATCHES] Last infomask bit
Tom Lane wrote: Bruce Momjian [EMAIL PROTECTED] writes: Tom Lane wrote: Has anyone bothered to measure the overhead added by having to mask to fetch or store the natts value? This is not a zero-cost improvement. I haven't tested it. Agreed, it does add an AND operation to places where t_natts is accessed. Tom, how should this be tested? I assume some loop of the same query over and over again. I'd be satisfied by a demonstration of no meaningful difference in pgbench numbers. It's *probably* not a problem, but you never know if you don't check... I doubt there's any measurable difference, but I can do a pgbench run to make sure. -- Heikki Linnakangas EnterpriseDB http://www.enterprisedb.com ---(end of broadcast)--- TIP 7: You can help support the PostgreSQL project by donating at http://www.postgresql.org/about/donate
Re: [pgsql-patches] [HACKERS] [PATCHES] Bundle of patches
Nice, thanks a lot. Tom Lane wrote: Teodor Sigaev [EMAIL PROTECTED] writes: Just a freshing for clean applying.. http://www.sigaev.ru/misc/user_defined_typmod-0.11.gz Applied with some revisions, and pg_dump support and regression tests added. regards, tom lane ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq -- Teodor Sigaev E-mail: [EMAIL PROTECTED] WWW: http://www.sigaev.ru/ ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org
Re: [pgsql-patches] [PATCHES] fix build on Solaris 10/x86_64 in 64bit mode with Sun
Stefan Kaltenbrunner wrote: on an Intel based Solaris 10U2 box using Sun Studio 11 with -xarch=generic64 we get a compile time failure in contrib/pgcrypto because BYTE_ORDER is not defined. in src/include/port/solaris.h we define it to little endian only for __i386 - however in 64bit mode the compiler only defines __amd64 causing YTE_ORDER to be undefined. The other option would be to use __x86 which is defined on all intel architectures. attached is a quick hack to allow pgcrypto to compile on that platform. buildfarm report for that issue: http://www.pgbuildfarm.org/cgi-bin/show_log.pl?nm=clownfishdt=2007-01-10%2014:18:23 Stefan ---(end of broadcast)--- TIP 6: explain analyze is your friend
Re: [pgsql-patches] [HACKERS] [PATCHES] Last infomask bit
Heikki Linnakangas [EMAIL PROTECTED] writes: What? I'm completely lost here. What does log_temp_files have to do with the bits on the tuple header? Nothing, it looks like Bruce replied to the wrong message at one point while these two threads were active ... regards, tom lane ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org
Re: [pgsql-patches] [HACKERS] [PATCHES] Last infomask bit
Heikki Linnakangas wrote: Bruce Momjian wrote: Tom Lane wrote: Bruce Momjian [EMAIL PROTECTED] writes: Patch applied. Thanks. I added a comment about the unused bits in the header file. Has anyone bothered to measure the overhead added by having to mask to fetch or store the natts value? This is not a zero-cost improvement. SHOW ALL has: log_temp_files | -1 | Log the use of temporary files larger than th and pg_settings has: log_temp_files| -1 | kB | Reporting and Logging / What to Log Looks OK to me. What? I'm completely lost here. What does log_temp_files have to do with the bits on the tuple header? Sorry, Tom wanted two things tested and I replied to the wrong email. -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDBhttp://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org
Re: [pgsql-patches] [PATCHES] Building libpq/psql with Borland BCC5
Tom Lane wrote: Gavin Sherry [EMAIL PROTECTED] writes: Can we be sure that a BCC build libpq is even safe to use given the problems seen when using psql? Well, I'd not trust it a lot, but surely we have to get it to build before anyone can debug it ... It does build, but the report is that psql crashes after a few commands. -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDBhttp://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your message can get through to the mailing list cleanly
Re: [pgsql-patches] [HACKERS] [PATCHES] SGML index build fix
Peter Eisentraut wrote: Am Mittwoch, 10. Januar 2007 01:41 schrieb Bruce Momjian: Peter Eisentraut wrote: Bruce Momjian wrote: ? %-A4.tex-ps: %.sgml $(ALLSGML) stylesheet.dsl bookindex.sgml ? $(JADE.tex.call) -V texdvi-output -V '%paper-type%'=A4 -o $@ $ + ifndef DRAFT + [EMAIL PROTECTED] -s HTML.index.start HTML.index || $(MAKE) $* + endif What is the point of that? If HTML.index changed during the build, we need to rerun it until it is unchanged. But that rule doesn't change HTML.index. Now that the rule is right: %-A4.tex-ps: %.sgml $(ALLSGML) stylesheet.dsl bookindex.sgml $(JADE.tex.call) -V texdvi-output -V '%paper-type%'=A4 -o $@ $ ifndef DRAFT @cmp -s HTML.index.start HTML.index || $(MAKE) $@ endif The rule re-runs the makefile for the specific target, and the target modifies HTML.index, or it is only the HTML rule that modifies that. That was a question I had. If that is true, it has to be: %-A4.tex-ps: %.sgml $(ALLSGML) stylesheet.dsl bookindex.sgml $(JADE.tex.call) -V texdvi-output -V '%paper-type%'=A4 -o $@ $ ifndef DRAFT @cmp -s HTML.index.start HTML.index || $(MAKE) html $@ endif -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDBhttp://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq
Re: [pgsql-patches] [HACKERS] [PATCHES] Building libpq/psql with Borland BCC5
Bruce Momjian wrote: Tom Lane wrote: Gavin Sherry [EMAIL PROTECTED] writes: Can we be sure that a BCC build libpq is even safe to use given the problems seen when using psql? Well, I'd not trust it a lot, but surely we have to get it to build before anyone can debug it ... It does build, but the report is that psql crashes after a few commands. What about a Mingw or VC++ psql with a BCC libpq? Is it possible to link something like that? It would be nice to have the libpq at least able to pass the regression tests. -- Alvaro Herrerahttp://www.CommandPrompt.com/ The PostgreSQL Company - Command Prompt, Inc. ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster
Re: [pgsql-patches] [HACKERS] [PATCHES] Building libpq/psql with Borland BCC5
Alvaro Herrera wrote: Bruce Momjian wrote: Tom Lane wrote: Gavin Sherry [EMAIL PROTECTED] writes: Can we be sure that a BCC build libpq is even safe to use given the problems seen when using psql? Well, I'd not trust it a lot, but surely we have to get it to build before anyone can debug it ... It does build, but the report is that psql crashes after a few commands. What about a Mingw or VC++ psql with a BCC libpq? Is it possible to link something like that? No idea. It would be nice to have the libpq at least able to pass the regression tests. True. -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDBhttp://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 6: explain analyze is your friend
Re: [pgsql-patches] [BUGS] xlog lockup patch (was: BUG #2712:
It was considered too risky to backpatch because we couldn't do sufficient testing. --- TANIDA Yutaka wrote: Hi. On Mon, 20 Nov 2006 15:33:33 -0500 (EST) Bruce Momjian [EMAIL PROTECTED] wrote: Thomas H. wrote: me wrote: i've loaded 1gb of data without any xlog-problems, whereas with the 8.2b2 executable it locked up after ~100mb. the xlog-files are cycling... if i need to test for some specific behaviour let me know. what's the status on this patch for inclusion in future 8.2 builds? would be nice to see it in b4 or rc1... This was fixed the day after we packaged beta3: revision 1.44 date: 2006/11/08 20:12:05; author: tgl; state: Exp; lines: +20 -48 Change Windows rename and unlink substitutes so that they time out after 30 seconds instead of retrying forever. Also modify xlog.c so that if it fails to rename an old xlog segment up to a future slot, it will unlink the segment instead. Per discussion of bug #2712, in which it became apparent that Windows can handle unlinking a file that's being held open, but not renaming it. beta4 will have the fix. Are there any plan to backport this patch for 8.1/8.0 server ? My customer has same problem in 8.1.5 , but this bug doesn't seems to be fixed in 8.1.6 . Backport patch for 8.1.6 attached. Sorry for replying old mail. -- TANIDA Yutaka [EMAIL PROTECTED] [ Attachment, skipping... ] ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDBhttp://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq
Re: [pgsql-patches] [HACKERS] [PATCHES] SGML index build fix
Bruce Momjian wrote: The rule re-runs the makefile for the specific target, and the target modifies HTML.index, or it is only the HTML rule that modifies that. Only the html rule modifies HTML.index. That was a question I had. If that is true, it has to be: %-A4.tex-ps: %.sgml $(ALLSGML) stylesheet.dsl bookindex.sgml $(JADE.tex.call) -V texdvi-output -V '%paper-type%'=A4 -o $@ $ ifndef DRAFT @cmp -s HTML.index.start HTML.index || $(MAKE) html $@ endif It would much easier to just run the html rule before the other stuff. -- Peter Eisentraut http://developer.postgresql.org/~petere/ ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your message can get through to the mailing list cleanly
Re: [pgsql-patches] [HACKERS] [PATCHES] SGML index build fix
Peter Eisentraut wrote: Bruce Momjian wrote: The rule re-runs the makefile for the specific target, and the target modifies HTML.index, or it is only the HTML rule that modifies that. Only the html rule modifies HTML.index. That was a question I had. If that is true, it has to be: %-A4.tex-ps: %.sgml $(ALLSGML) stylesheet.dsl bookindex.sgml $(JADE.tex.call) -V texdvi-output -V '%paper-type%'=A4 -o $@ $ ifndef DRAFT @cmp -s HTML.index.start HTML.index || $(MAKE) html $@ endif It would much easier to just run the html rule before the other stuff. OK, so just make HTML a depenency for those. Patch attached and applied. -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDBhttp://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + Index: doc/src/sgml/Makefile === RCS file: /cvsroot/pgsql/doc/src/sgml/Makefile,v retrieving revision 1.89 diff -c -c -r1.89 Makefile *** doc/src/sgml/Makefile 10 Jan 2007 01:57:15 - 1.89 --- doc/src/sgml/Makefile 10 Jan 2007 17:45:35 - *** *** 89,94 --- 89,95 .PHONY: html + # This is run for all output formats because we need bookindex.sgml html: postgres.sgml $(ALLSGML) stylesheet.dsl @rm -f *.html $(JADE) $(JADEFLAGS) $(SPFLAGS) $(SGMLINCLUDE) $(CATALOG) -d stylesheet.dsl -i output-html -t sgml $ *** *** 96,130 @cp $(srcdir)/stylesheet.css . endif ifndef DRAFT ! @cmp -s HTML.index.start HTML.index || $(MAKE) $(MAKECMDGOALS) endif COLLATEINDEX := LC_ALL=C $(PERL) $(COLLATEINDEX) -f -g draft: ifndef DRAFT ifneq ($(MAKECMDGOALS), draft) - # Call ourselves with the DRAFT value set. This seems to be the only - # way to set gmake variables in a rule. @$(MAKE) DRAFT=Y $(MAKECMDGOALS) else ! # run default 'all' rule @$(MAKE) DRAFT=Y all endif endif bookindex.sgml: HTML.index # create a dummy bookindex.html test -s HTML.index || $(COLLATEINDEX) -o $@ -N ! # If HTML.index is valid, create a valid bookindex.sgml. This ! # is required so the output has a proper index. test ! -s HTML.index || $(COLLATEINDEX) -i 'bookindex' -o $@ $ # save copy of HTML.index for later comparison @cp HTML.index HTML.index.start HTML.index: ! # create HTML.index if it does not exist @$(if $(wildcard HTML.index), , touch HTML.index) version.sgml: $(top_builddir)/src/Makefile.global --- 97,132 @cp $(srcdir)/stylesheet.css . endif ifndef DRAFT ! @cmp -s HTML.index.start HTML.index || $(MAKE) $@ endif COLLATEINDEX := LC_ALL=C $(PERL) $(COLLATEINDEX) -f -g + # The draft rule calls $(MAKE) again and sets the DRAFT variable. + # This seems to be the only way to set gmake variables in a rule. draft: ifndef DRAFT ifneq ($(MAKECMDGOALS), draft) @$(MAKE) DRAFT=Y $(MAKECMDGOALS) else ! # simulate $(MAKE) with no arguments @$(MAKE) DRAFT=Y all endif endif + # bookindex.sgml is required so there is a proper index for all output formats bookindex.sgml: HTML.index # create a dummy bookindex.html test -s HTML.index || $(COLLATEINDEX) -o $@ -N ! # If HTML.index is valid, create a valid bookindex.sgml. test ! -s HTML.index || $(COLLATEINDEX) -i 'bookindex' -o $@ $ # save copy of HTML.index for later comparison @cp HTML.index HTML.index.start + # HTML.index is used to create bookindex.sgml HTML.index: ! # create an empty HTML.index if it does not exist @$(if $(wildcard HTML.index), , touch HTML.index) version.sgml: $(top_builddir)/src/Makefile.global *** *** 156,184 JADE.tex.call = $(JADE) $(JADEFLAGS) $(SGMLINCLUDE) $(CATALOG) -d $(srcdir)/stylesheet.dsl -t tex -V tex-backend -i output-print ! %-A4.tex-ps: %.sgml $(ALLSGML) stylesheet.dsl bookindex.sgml $(JADE.tex.call) -V texdvi-output -V '%paper-type%'=A4 -o $@ $ - ifndef DRAFT - @cmp -s HTML.index.start HTML.index || $(MAKE) $@ - endif ! %-US.tex-ps: %.sgml $(ALLSGML) stylesheet.dsl bookindex.sgml $(JADE.tex.call) -V texdvi-output -V '%paper-type%'=USletter -o $@ $ - ifndef DRAFT - @cmp -s HTML.index.start HTML.index || $(MAKE) $@ - endif ! %-A4.tex-pdf: %.sgml $(ALLSGML) stylesheet.dsl bookindex.sgml $(JADE.tex.call) -V texpdf-output -V '%paper-type%'=A4 -o $@ $ - ifndef DRAFT - @cmp -s HTML.index.start HTML.index || $(MAKE) $@ - endif ! %-US.tex-pdf: %.sgml $(ALLSGML) stylesheet.dsl bookindex.sgml $(JADE.tex.call) -V texpdf-output -V '%paper-type%'=USletter -o $@ $ - ifndef DRAFT - @cmp -s HTML.index.start HTML.index || $(MAKE) $@ - endif %.dvi: %.tex-ps @rm -f $*.aux $*.log --- 158,174 JADE.tex.call = $(JADE) $(JADEFLAGS) $(SGMLINCLUDE) $(CATALOG) -d $(srcdir)/stylesheet.dsl -t tex -V tex-backend -i output-print ! %-A4.tex-ps: %.sgml $(ALLSGML) html $(JADE.tex.call) -V texdvi-output -V '%paper-type%'=A4 -o $@ $ ! %-US.tex-ps: %.sgml
Re: [pgsql-patches] [HACKERS] [PATCHES] COPY with no WAL, in certain circumstances
On Sat, Jan 06, 2007 at 09:20:53PM -0500, Tom Lane wrote: Bruce Momjian [EMAIL PROTECTED] writes: Simon Riggs wrote: Reason for no documentation was that CREATE INDEX and CREATE TABLE AS SELECT already use this optimisation, but to my knowledge neither was/is documented on those command pages. I wasn't aware those used the optimization. Seems they all should be documented somewhere. We don't document every single optimization in the system ... if we did, the docs would be as big as the source code and equally unreadable by non-programmers. I think it's a much better idea just to mention it one place and not try to enumerate exactly which commands have the optimization. I think it would be reasonable to refer to the 'tuning page' from the appropriate pages in the documentation... I'm thinking of something similar to the SEE ALSO section of man pages. The big complain that I have (and have heard) about the docs is that it's very hard to find something unless you know exactly what it is you're looking for. If you don't know that there are performance shortcuts associated with CREATE INDEX you're unlikely to find out about them. -- Jim Nasby[EMAIL PROTECTED] EnterpriseDB http://enterprisedb.com 512.569.9461 (cell) ---(end of broadcast)--- TIP 6: explain analyze is your friend
Re: [pgsql-patches] [PATCHES] fix build on Solaris 10/x86_64 in 64bit mode with Sun Studio 11
Stefan Kaltenbrunner [EMAIL PROTECTED] writes: in src/include/port/solaris.h we define it to little endian only for __i386 - however in 64bit mode the compiler only defines __amd64 causing YTE_ORDER to be undefined. The other option would be to use __x86 which is defined on all intel architectures. Shouldn't this use the already-defined __x86_64__ symbol? I assume that's already defined because otherwise s_lock.h would fail... regards, tom lane ---(end of broadcast)--- TIP 6: explain analyze is your friend
Re: [pgsql-patches] [PATCHES] fix build on Solaris 10/x86_64 in 64bit mode with Sun Studio 11
Stefan Kaltenbrunner [EMAIL PROTECTED] writes: on an Intel based Solaris 10U2 box using Sun Studio 11 with -xarch=generic64 we get a compile time failure in contrib/pgcrypto because BYTE_ORDER is not defined. After further thought I changed this to handle either __amd64 or __x86_64 (or both). Applied. regards, tom lane ---(end of broadcast)--- TIP 6: explain analyze is your friend
Re: [pgsql-patches] [PATCHES] fix build on Solaris 10/x86_64 in 64bit mode with Sun
Tom Lane wrote: Stefan Kaltenbrunner [EMAIL PROTECTED] writes: on an Intel based Solaris 10U2 box using Sun Studio 11 with -xarch=generic64 we get a compile time failure in contrib/pgcrypto because BYTE_ORDER is not defined. After further thought I changed this to handle either __amd64 or __x86_64 (or both). Applied. I think it defines both at all times - if we want fewer rules in there we could switch to just testing __x86 für both 64bit and 32bit but I guess it's fine as it stands now. Stefan ---(end of broadcast)--- TIP 6: explain analyze is your friend
Re: [pgsql-patches] [HACKERS] [PATCHES] Building libpq/psql with Borland BCC5
On 1/10/07, Alvaro Herrera [EMAIL PROTECTED] wrote: What about a Mingw or VC++ psql with a BCC libpq? Is it possible to link something like that? It would be nice to have the libpq at least able to pass the regression tests. you can use microsoft/mingw compiled DLL files but not library files. however, borland provides a command line tool (implib i thnk) to create an import library for it which works ok. (i think you have to pass a switch to fix underscore issue). libpq.lib is not directly usable (coff vs. omf) but digital mars makes a tool which can do this and I have confirmed it works. note: I've used borland compiled libpq (not psql) with borland C++ builder 3 5 with no problems. I had to hack pg_config.h however. merlin ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq
[pgsql-patches] Remove of .SECONDARY from SGML Makefile
To get the new html dependency to work properly, I removed the .SECONDARY tag from the Makefile. SECONDARY prevents missing files from being built. Patch attached and applied. The rules now work properly and are less error-prone. -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDBhttp://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + Index: doc/src/sgml/Makefile === RCS file: /cvsroot/pgsql/doc/src/sgml/Makefile,v retrieving revision 1.90 diff -c -c -r1.90 Makefile *** doc/src/sgml/Makefile 10 Jan 2007 19:06:04 - 1.90 --- doc/src/sgml/Makefile 11 Jan 2007 00:00:13 - *** *** 10,16 top_builddir = ../../.. include $(top_builddir)/src/Makefile.global - .SECONDARY: .NOTPARALLEL: ifndef COLLATEINDEX --- 10,15 *** *** 97,109 @cp $(srcdir)/stylesheet.css . endif ifndef DRAFT @cmp -s HTML.index.start HTML.index || $(MAKE) $@ endif COLLATEINDEX := LC_ALL=C $(PERL) $(COLLATEINDEX) -f -g ! # The draft rule calls $(MAKE) again and sets the DRAFT variable. # This seems to be the only way to set gmake variables in a rule. draft: ifndef DRAFT --- 96,109 @cp $(srcdir)/stylesheet.css . endif ifndef DRAFT + # If not draft, re-run the this rule until HTML.index does not change @cmp -s HTML.index.start HTML.index || $(MAKE) $@ endif COLLATEINDEX := LC_ALL=C $(PERL) $(COLLATEINDEX) -f -g ! # The draft rule calls gmake again and sets the DRAFT variable. # This seems to be the only way to set gmake variables in a rule. draft: ifndef DRAFT *** *** 148,156 # RTF to allow minor editing for hardcopy ! ! %.rtf: %.sgml $(ALLSGML) stylesheet.dsl ! $(JADE) $(JADEFLAGS) $(SGMLINCLUDE) $(CATALOG) -d stylesheet.dsl -t rtf -V rtf-backend -i output-print $ # TeX # Regular TeX and pdfTeX have slightly differing requirements, so we --- 148,155 # RTF to allow minor editing for hardcopy ! %.rtf: %.sgml $(ALLSGML) html ! $(JADE) $(JADEFLAGS) $(SGMLINCLUDE) $(CATALOG) -d stylesheet.dsl -t rtf -V rtf-backend -i output-print postgres.sgml # TeX # Regular TeX and pdfTeX have slightly differing requirements, so we *** *** 192,198 # This generates an XML version of the flow-object tree. It's useful # for debugging DSSSL code, and possibly to interface to some other # tools that can make use of this. ! %.fot: %.sgml $(ALLSGML) stylesheet.dsl $(JADE) $(JADEFLAGS) $(SGMLINCLUDE) $(CATALOG) -d stylesheet.dsl -t fot -i output-print -o $@ $ --- 191,197 # This generates an XML version of the flow-object tree. It's useful # for debugging DSSSL code, and possibly to interface to some other # tools that can make use of this. ! %.fot: %.sgml $(ALLSGML) html $(JADE) $(JADEFLAGS) $(SGMLINCLUDE) $(CATALOG) -d stylesheet.dsl -t fot -i output-print -o $@ $ Index: doc/src/sgml/docguide.sgml === RCS file: /cvsroot/pgsql/doc/src/sgml/docguide.sgml,v retrieving revision 1.64 diff -c -c -r1.64 docguide.sgml *** doc/src/sgml/docguide.sgml 9 Jan 2007 22:19:36 - 1.64 --- doc/src/sgml/docguide.sgml 11 Jan 2007 00:00:14 - *** *** 543,549 para To create a proper index, the build might process several identical ! stages. If you do not care about an index, and just want to proof-read the output, use literaldraft/: screen promptdoc/src/sgml$ /promptuserinputgmake draft html/userinput --- 543,549 para To create a proper index, the build might process several identical ! stages. If you do not care about the index, and just want to proof-read the output, use literaldraft/: screen promptdoc/src/sgml$ /promptuserinputgmake draft html/userinput *** *** 552,558 para To allow for easier handling in the final distribution, the files ! comprising the HTML documentation are stored in a tar archive that is unpacked at installation time. To create the acronymHTML/acronym documentation package, use the commands programlisting --- 552,558 para To allow for easier handling in the final distribution, the files ! comprising the HTML documentation can be stored in a tar archive that is unpacked at installation time. To create the acronymHTML/acronym documentation package, use the commands programlisting ---(end of broadcast)--- TIP 6: explain analyze is your friend
Re: [pgsql-patches] [BUGS] follow-up: problems with pg_ctl -w
I have added additional documentation for environment variables for pg_ctl, patch attached. --- Marvin Solomon wrote: [This is meant to be a follow-up of a bug report I sent earlier using the web form. It's not clear to me the right way to post a follow-up, since I didn't get a copy of the email generated by the web form, and the email hasn't shown up on the pgsql-bugs web site -- at least not yet.] I subsequently discovered that setting PGUSER in the environment gets around the first problem I mentioned, so it's really just a documentation problem: PGUSER is not mentioned on the pg_ctl doc page. But I found a worse problem. Sometimes (not repeatably), pg_ctl start -w logs the message FATAL: the database is starting up and immediately returns. I believe the correct thing for it to do when it gets this message from an attempt to open a session is to try again. Instead, it returns as if the startup was successful. ---(end of broadcast)--- TIP 7: You can help support the PostgreSQL project by donating at http://www.postgresql.org/about/donate -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDBhttp://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + Index: doc/src/sgml/ref/pg_ctl-ref.sgml === RCS file: /cvsroot/pgsql/doc/src/sgml/ref/pg_ctl-ref.sgml,v retrieving revision 1.36 diff -c -c -r1.36 pg_ctl-ref.sgml *** doc/src/sgml/ref/pg_ctl-ref.sgml 5 Jan 2007 16:17:54 - 1.36 --- doc/src/sgml/ref/pg_ctl-ref.sgml 11 Jan 2007 02:28:00 - *** *** 356,362 /variablelist para !For others, see xref linkend=app-postgres. /para /refsect1 --- 356,362 /variablelist para !For additional server variables, see xref linkend=app-postgres. /para /refsect1 *** *** 427,433 para Waiting for complete start is not a well-defined operation and may fail if access control is set up so that a local client cannot !connect without manual interaction (e.g., password authentication). /para /refsect1 --- 427,435 para Waiting for complete start is not a well-defined operation and may fail if access control is set up so that a local client cannot !connect without manual interaction (e.g., password authentication). For !additional connection variables, see xref linkend=libpq-envars, !and for passwords, also see xref linkend=libpq-pgpass. /para /refsect1 ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org
Re: [pgsql-patches] [PATCHES] Building libpq/psql with Borland BCC5
Patch applied. Thanks. Backpatch to 8.2.X.z --- L Bayuk wrote: The attached patch against PostgreSQL-8.2.1 was discussed on [INTERFACES]. It fixes bcc32.mak makefiles for the Borland BCC compiler to build libpq and psql*. There are also changes to some header files to hide some things BCC doesn't like. *Note: psql compiles with bcc after the patch, but it does not run very well. [ Attachment, skipping... ] ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDBhttp://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match
Re: [pgsql-patches] [HACKERS] [PATCHES] Allow the identifier length to be
Tom Lane wrote: Peter Eisentraut [EMAIL PROTECTED] writes: Tom Lane wrote: ... why is NAMEDATALEN exported at all?) I think because it used to be used in libpq's notification structure. Yeah, you're probably right. Maybe we should take it out of postgres_ext.h and move it to pg_config_manual.h. If no one complains after a release cycle or so, we could reconsider making it configurable more easily. Added to TODO: * Move NAMEDATALEN from postgres_ext.h to pg_config_manual.h and consider making it more configurable in future releases -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDBhttp://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match
Re: [pgsql-patches] [PATCHES] Building libpq/psql with Borland BCC5
On Wed, Jan 10, 2007 at 02:53:01PM +1100, Gavin Sherry wrote: ... Can we be sure that a BCC build libpq is even safe to use given the problems seen when using psql? I have high confidence in my BCC-built libpq, in so far as its functions are exposed through the Tcl interface pgtcl-ng. My test suite for pgtcl is rather thorough (more below), and it passes using BCC-built libpq. Compare that to the fact that my BCC-built psql crashes consistently after six \h set commands - which don't even use libpq! - and you can see why I think the problem is entirely in psql. BCC was free to use and easy to set up, and I was able to make Tcl-loadable modules with it, so that's what I'm using for pgtcl-ng. I'm not suggesting people use it for anything else based on what I've done. If there is a regression test for libpq which does not use psql, show me and I'll run it. Otherwise, people will have to do their own testing. But in my opinion if you have Mingw or VC++, use it (not that I've used either). . My test suite exercises libpq/pgtcl. I use it for pgtclng and pgintcl (see pgfoundry). It runs about 160 test cases on Windows (more on Linux, where it tests for memory leaks, but I don't know how to do that on Windows). It includes: synchronous and asynchronous queries, extended 8-bit characters, COPY From/To, cursors with text and binary data, error detection, prepared and parameterized queries (text and binary data), large objects, long TEXT fields, 300-column table queries, transactions, and more. I have some performance tests in there as a sanity check, including my favorite: a single query against a 1-column 10-row table which takes 3-10 minutes of backend time. Three tests claim to fail on Windows, same as always. Changes to environment variables like PGUSER within the script are not seen by pg_connect; this is apparently a DLL thing. The other 2 failures are false, and have to do with a limitation of tcltest not seeing output notification messages written by libpq. These are not real errors. ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings
Re: [pgsql-patches] [PATCHES] COPY with no WAL, v2
Will hold for doc patches. Your patch has been added to the PostgreSQL unapplied patches list at: http://momjian.postgresql.org/cgi-bin/pgpatches It will be applied as soon as one of the PostgreSQL committers reviews and approves it. --- Simon Riggs wrote: VERSION 2, with all changed made as requested to date. As discussed on -hackers, its possible to avoid writing any WAL at all for COPY in these circumstances: http://archives.postgresql.org/pgsql-hackers/2006-10/msg01172.php and again recently. BEGIN; CREATE TABLE foo.. COPY foo... COMMIT; BEGIN; TRUNCATE foo.. COPY foo... COMMIT; The enclosed patch implements this, as discussed. There is no user interface to enable/disable, just as with CTAS and CREATE INDEX; no docs, just code comments. This plays nicely with the --single-transaction option in psql to allow fast restores/upgrades. YMMV but disk bound COPY will benefit greatly from this patch, some tests showing 100% gain. COPY is still *very* CPU intensive, so some tests have shown negligible benefit, fyi, but that isn't the typical case. While testing this, I realised something: small COPY commands get no benefit at all, but larger ones do. When we do a small normal COPY the data stays in cache, but the WAL is written to disk and fsynced. When we do a small fast COPY, no WAL is written, but the data is written to disk and fsynced. With COPY, WAL and data are roughly same size, hence no I/O benefit. With larger COPY statements, benefit is very substantial. Applies cleanly to CVS HEAD, passes make check. I enclose a test case that shows whether the test has succeeded by reading the WAL Insert pointer before/after each COPY. This has been written in such a way that we could, if we wanted to, include a new regression test for this. There is a function that returns an immutable value if the test passes, rather than simply showing the WAL insert pointer which would obviously vary between tests. The tests enclosed here *also* include the WAL insert pointer so you can manually/visibly see that the enclosed patch writes no WAL at appropriate times. psql -f copy_nowal_prep.sql postgres psql -f copy_nowal_test.sql postgres Do we want an additional test case along these lines? Agreed doc changes for Performance Tips forthcoming. -- Simon Riggs EnterpriseDB http://www.enterprisedb.com [ Attachment, skipping... ] [ Attachment, skipping... ] [ Attachment, skipping... ] ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDBhttp://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings
Re: [pgsql-patches] [HACKERS] [PATCHES] wal_checksum = on (default) | off
Simon Riggs wrote: On Fri, 2007-01-05 at 22:57 -0500, Tom Lane wrote: Jim Nasby [EMAIL PROTECTED] writes: On Jan 5, 2007, at 6:30 AM, Zeugswetter Andreas ADI SD wrote: Ok, so when you need CRC's on a replicate (but not on the master) you Which sounds to me like a good reason to allow the option in recovery.conf as well... Actually, I'm not seeing the use-case for a slave having a different setting from the master at all? My backup server is less reliable than the primary. My backup server is more reliable than the primary. Somehow, neither of these statements seem likely to be uttered by a sane DBA ... If I take a backup of a server and bring it up on a new system, the blocks in the backup will not have been CRC checked before they go to disk. If I take the same server and now stream log records across to it, why *must* that data be CRC checked, when the original data has not been? I'm proposing choice, with a safe default. That's all. I am assuming this item is dead because no performance results have been reported. -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDBhttp://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org