threads
listlengths
1
2.99k
[ { "msg_contents": "Hmmm, I'll double check. The last time I built the jar file (about a\nweek ago) I used the jar rule.\n\nMy memory's not that good at the moment, so perhaps I had fixed it since\n:-)\n\nPeter\n\n-- \nPeter Mount\nEnterprise Support\nMaidstone Borough Council\nAny views stated are my own, and not those of Maidstone Borough Council.\n\n\n\n-----Original Message-----\nFrom: Thomas Lockhart [mailto:[email protected]]\nSent: Tuesday, May 02, 2000 12:08 PM\nTo: Peter Mount\nCc: Lamar Owen; Bruce Momjian; PostgreSQL-development;\nPostgreSQL-interfaces\nSubject: Re: [HACKERS] Request for 7.0 JDBC status\n\n\n> The jar file isn't built automatically in 7.0. You'll have to use:\n> make jdbc2 jar\n\n?? From fresh sources afaik:\n\n[postgres@golem jdbc]$ make jdbc2 jar\n(echo \"package org.postgresql;\" ;\\\n echo \"public class DriverClass {\" ;\\\n echo \"public static String\nconnectClass=\\\"org.postgresql.jdbc2.Connection\\\";\" ;\\\n echo \"}\" \\\n) >org/postgresql/DriverClass.java\nmake[1]: Entering directory `/opt/postgres/pgsql/src/interfaces/jdbc'\njavac -g org/postgresql/DriverClass.java\n...\njavac -g org/postgresql/jdbc2/CallableStatement.java\nNote: org/postgresql/jdbc2/CallableStatement.java uses or overrides a\ndeprecated API. Recompile with \"-deprecation\" for details.\n1 warning\njar -c0f postgresql.jar `find org/postgresql -name \"*.class\" -print` \\\n org/postgresql/errors.properties\norg/postgresql/errors_fr.properties\norg/postgresql/errors_nl.properties\n------------------------------------------------------------\nThe JDBC driver has now been built. To make it available to\n...\nTo build the CORBA example (requires Java2):\n make corba\n------------------------------------------------------------\n\nmake[1]: Leaving directory `/opt/postgres/pgsql/src/interfaces/jdbc'\nmake: *** No rule to make target `jar'. Stop.\n\n\nSeems a jar file does get built with \"make jdbc2\", but I'm not sure it\nis the right one (being *much* more advanced than Lamar in the Java\nworld, I *make* Java, but don't actually *use* Java :)) ;)\n\nAs an aside, I thought Peter might find it interesting that we do have\na fairly large Java app at my work (JPL) to manage and build\nconfigurations for a fancy hard real-time system for astronomical\noptical interferometers. The app happens to use Postgres as a backend\nfor most deliveries ;) Keck Observatory will need it working with\nSybase since they long ago standardized on that...\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Tue, 2 May 2000 12:32:08 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: [HACKERS] Request for 7.0 JDBC status" } ]
[ { "msg_contents": "As usual when replying from here, replies prefixed with PM:\n\n-- \nPeter Mount\nEnterprise Support\nMaidstone Borough Council\nAny views stated are my own, and not those of Maidstone Borough Council.\n\n\n[snip]\n\nJust to add to my earlier report, here is the kaffe 1.05 compile\nfailure. What strikes me as odd is that Connection.java complains\nbecause it can't find org/postgresql/Field, but if I try to compile\nField.java complains it can't find Connection.java.\n\nNow, having the 6.5.3 JAR file, I can compile the 6.5.3 postgresql java\ndriver because I have the jar file to back up the unreferenced\nsymbols.=20\nThe 7.0 driver uses org.postgresql, which is not in the 6.5.3 JAR file,\nso it fails.\n\nPM: That's odd. Perhaps kaffe lacks this ability.\n\nThe java IRC channel says kaffe isn't very good, so maybe I shouldn't be\nworried about it. They also said mutually-referencing java files are\nnot a good either.\n\nPM: This is strange, because mutually referenced java files are quite\ncommon. In fact, some of the javax.swing classes do this, and I've been\ndoing it since 1.0.2 :-) Anyhow, kaffe was taken over by M$ a few months\nago...\n\nSeems I may be able to modify the import lines in the java file to use\nthe 6.5.3 JAR file to get enough files compiled to compile the rest,\nthen recompile the entire thing.\n\nUsing the jar file compiled with Sun java works fine. I can connect to\nthe database and run my program.\n\nPM: I stayed away from Kaffe because when I first started with Java, I\nhad so much trouble compiling examples with it, I switched to the Sun\nJVM.\n\n[snip]\n", "msg_date": "Tue, 2 May 2000 12:54:14 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: [HACKERS] Request for 7.0 JDBC status" }, { "msg_contents": "> The java IRC channel says kaffe isn't very good, so maybe I shouldn't be\n> worried about it. They also said mutually-referencing java files are\n> not a good either.\n> \n> PM: This is strange, because mutually referenced java files are quite\n> common. In fact, some of the javax.swing classes do this, and I've been\n> doing it since 1.0.2 :-) Anyhow, kaffe was taken over by M$ a few months\n> ago...\n\nOh, OK, so I will not worry about the self-referencing issue. BSD/OS\nhas a java beta out, but I am too busy on the book to upgrade. I will\nnot worry about it. Seems kaffe can run the jdbc classes just fine.\n\n> \n> Seems I may be able to modify the import lines in the java file to use\n> the 6.5.3 JAR file to get enough files compiled to compile the rest,\n> then recompile the entire thing.\n> \n> Using the jar file compiled with Sun java works fine. I can connect to\n> the database and run my program.\n> \n> PM: I stayed away from Kaffe because when I first started with Java, I\n> had so much trouble compiling examples with it, I switched to the Sun\n> JVM.\n\nOh, that is fine. I just needed to know the code was OK. Kaffe people\ncan download the JAR file. The great part is that they work on any\nplatform. \n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 08:00:46 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Request for 7.0 JDBC status" } ]
[ { "msg_contents": "As usual when replying from here, replies prefixed with PM:\n\n-- \nPeter Mount\nEnterprise Support\nMaidstone Borough Council\nAny views stated are my own, and not those of Maidstone Borough Council.\n\n\nSeems a JAR file is better than copying the class files. The README has\nto be updated though. Also, your web page should be more prominent. \nPeople may prefer downloading the JAR file themselves rather than do the\ncompile if they have kaffe.\n\nPM: Yes, apart from special cases (mainly with applets) it's easier as\nit's not just .class files that go into the .jar file.\n\nPM: As for my site, I want to update the site but I've tried to put the\ncoding as a higher priority. If I can get this lot sorted, then I'll\nswitch to the site contents.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania\n19026\n", "msg_date": "Tue, 2 May 2000 12:57:34 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: [HACKERS] Request for 7.0 JDBC status" } ]
[ { "msg_contents": "Thinking about it, what's the date on the Makefile? I wasn't sure if the\nMakefile committed last time (I accidentally overwote the one in\nsrc/interfaces).\n\nPeter\n\n-- \nPeter Mount\nEnterprise Support\nMaidstone Borough Council\nAny views stated are my own, and not those of Maidstone Borough Council.\n\n\n\n-----Original Message-----\nFrom: Thomas Lockhart [mailto:[email protected]]\nSent: Tuesday, May 02, 2000 12:08 PM\nTo: Peter Mount\nCc: Lamar Owen; Bruce Momjian; PostgreSQL-development;\nPostgreSQL-interfaces\nSubject: Re: [HACKERS] Request for 7.0 JDBC status\n\n\n> The jar file isn't built automatically in 7.0. You'll have to use:\n> make jdbc2 jar\n\n?? From fresh sources afaik:\n\n[postgres@golem jdbc]$ make jdbc2 jar\n(echo \"package org.postgresql;\" ;\\\n echo \"public class DriverClass {\" ;\\\n echo \"public static String\nconnectClass=\\\"org.postgresql.jdbc2.Connection\\\";\" ;\\\n echo \"}\" \\\n) >org/postgresql/DriverClass.java\nmake[1]: Entering directory `/opt/postgres/pgsql/src/interfaces/jdbc'\njavac -g org/postgresql/DriverClass.java\n...\njavac -g org/postgresql/jdbc2/CallableStatement.java\nNote: org/postgresql/jdbc2/CallableStatement.java uses or overrides a\ndeprecated API. Recompile with \"-deprecation\" for details.\n1 warning\njar -c0f postgresql.jar `find org/postgresql -name \"*.class\" -print` \\\n org/postgresql/errors.properties\norg/postgresql/errors_fr.properties\norg/postgresql/errors_nl.properties\n------------------------------------------------------------\nThe JDBC driver has now been built. To make it available to\n...\nTo build the CORBA example (requires Java2):\n make corba\n------------------------------------------------------------\n\nmake[1]: Leaving directory `/opt/postgres/pgsql/src/interfaces/jdbc'\nmake: *** No rule to make target `jar'. Stop.\n\n\nSeems a jar file does get built with \"make jdbc2\", but I'm not sure it\nis the right one (being *much* more advanced than Lamar in the Java\nworld, I *make* Java, but don't actually *use* Java :)) ;)\n\nAs an aside, I thought Peter might find it interesting that we do have\na fairly large Java app at my work (JPL) to manage and build\nconfigurations for a fancy hard real-time system for astronomical\noptical interferometers. The app happens to use Postgres as a backend\nfor most deliveries ;) Keck Observatory will need it working with\nSybase since they long ago standardized on that...\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Tue, 2 May 2000 13:02:23 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: [HACKERS] Request for 7.0 JDBC status" }, { "msg_contents": "> Thinking about it, what's the date on the Makefile? I wasn't sure if the\n> Makefile committed last time (I accidentally overwote the one in\n> src/interfaces).\n\nJan put the old one back, and I got your out of CVS and moved it to\njdbc. It should be the one you committed.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 08:05:53 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Request for 7.0 JDBC status" }, { "msg_contents": "> > > Thinking about it, what's the date on the Makefile? I wasn't sure if the\n> > > Makefile committed last time (I accidentally overwote the one in\n> > > src/interfaces).\n> > Jan put the old one back, and I got your out of CVS and moved it to\n> > jdbc. It should be the one you committed.\n> \n> Just guessing: it is reverted to a slightly older version. As I\n> showed, it has no rule for making jar files, though it *does* make a\n> jar file automagically :(\n\nI got the file that Jan overwrote to fix Peter's overwrite and installed\nthat in the jdbc directory.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 08:59:36 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Request for 7.0 JDBC status" }, { "msg_contents": "> > Thinking about it, what's the date on the Makefile? I wasn't sure if the\n> > Makefile committed last time (I accidentally overwote the one in\n> > src/interfaces).\n> Jan put the old one back, and I got your out of CVS and moved it to\n> jdbc. It should be the one you committed.\n\nJust guessing: it is reverted to a slightly older version. As I\nshowed, it has no rule for making jar files, though it *does* make a\njar file automagically :(\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Tue, 02 May 2000 12:59:57 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Request for 7.0 JDBC status" }, { "msg_contents": "> I got the file that Jan overwrote to fix Peter's overwrite and installed\n> that in the jdbc directory.\n\nYeah, I understood that. Peter will speak up soon, but he indicated\nthat he wasn't sure that his new Makefile ever made it into CVS in the\nfirst place, if I read his mail correctly.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Tue, 02 May 2000 13:14:37 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Request for 7.0 JDBC status" } ]
[ { "msg_contents": "Hi guys\nI tried compliling JDBC 1.2 driver for postgresql7.0 .. However things didnt work out as expected..\nCan anybody please send it to me thru a personal email.. The site has a version of postgresql.jar\nbut then it was compiled for 6.5.2.. Can i use the same jar file or do i need to get a seperate one\nfor 7.0\nAny help will be appreciated\nBye\nAnand\n\n", "msg_date": "Tue, 2 May 2000 17:53:10 +0530", "msg_from": "\"Anand Raman\" <[email protected]>", "msg_from_op": true, "msg_subject": "postgresql7.0 jdbc driver" }, { "msg_contents": "[Charset iso-8859-1 unsupported, filtering to ASCII...]\n> Hi guys I tried compliling JDBC 1.2 driver for postgresql7.0 ..\n> However things didnt work out as expected.. Can anybody please\n> send it to me thru a personal email.. The site has a version of\n> postgresql.jar but then it was compiled for 6.5.2.. Can i use\n> the same jar file or do i need to get a seperate one for 7.0\n> Any help will be appreciated Bye Anand\n> \n> \n\nWe were discussing it just today. We hope to have the web site updated\nsoon. Can you describe the problem you are having?\n\n--\n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 09:19:32 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: postgresql7.0 jdbc driver" }, { "msg_contents": "On Tue, 2 May 2000, Anand Raman wrote:\n\n> Hi guys\n> I tried compliling JDBC 1.2 driver for postgresql7.0 .. However things didnt work out as expected..\n\nHmmm, a descriptive type. _What_ went wrong?\n\n> Can anybody please send it to me thru a personal email.. The site has a version of postgresql.jar\n> but then it was compiled for 6.5.2.. Can i use the same jar file or do i need to get a seperate one\n> for 7.0\n> Any help will be appreciated\n> Bye\n> Anand\n> \n> \n\n--\nTom Cook - Software Engineer\n\n\"Never criticize a man until you've walked a mile in his shoes; that way,\nwhen you criticize him, you're a mile away and have his shoes.\"\n\t- A froggy bloke on a news group.\n\nLISAcorp - www.lisa.com.au\n\n--------------------------------------------------\n38 Greenhill Rd. Level 3, 228 Pitt Street\nWayville, SA, 5034 Sydney, NSW, 2000\n\nPhone: +61 8 8272 1555 Phone: +61 2 9283 0877\nFax: +61 8 8271 1199 Fax: +61 2 9283 0866\n--------------------------------------------------\n\n", "msg_date": "Wed, 3 May 2000 08:54:59 +0930 (CST)", "msg_from": "Tom Cook <[email protected]>", "msg_from_op": false, "msg_subject": "Re: postgresql7.0 jdbc driver" }, { "msg_contents": "HI guys\nThanx for the quick reply.. \n\nWhen i tried compiling jdbc for postgresql700 I encounter the following error\n\npostgres@localhost > make jdbc1\n(echo \"package postgresql;\" ;\\\n echo \"public class DriverClass {\" ;\\\n echo \"public static String connectClass=\\\"postgresql.jdbc1.Connection\\\";\" ;\\\n echo \"}\" \\\n) >postgresql/DriverClass.java\nmake[1]: Entering directory `/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\njavac -g postgresql/DriverClass.java\njavac -g postgresql/Connection.java\npostgresql/Connection.java:447: Wrong number of arguments in constructor.\n fields[i] = new Field(this, typname, typid, typlen, typmod);\n ^\n1 error\nmake[1]: *** [postgresql/Connection.class] Error 1\nmake[1]: Leaving directory `/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\nmake: *** [jdbc1] Error 2\n\nsame is the case with $ make jdbc2\n\nThanx for the assitance\nAnand Raman\n\n\n\n----- Original Message ----- \nFrom: Bruce Momjian <[email protected]>\nTo: Anand Raman <[email protected]>\nCc: <[email protected]>\nSent: Tuesday, May 02, 2000 6:49 PM\nSubject: Re: [GENERAL] postgresql7.0 jdbc driver\n\n\n> [Charset iso-8859-1 unsupported, filtering to ASCII...]\n> > Hi guys I tried compliling JDBC 1.2 driver for postgresql7.0 ..\n> > However things didnt work out as expected.. Can anybody please\n> > send it to me thru a personal email.. The site has a version of\n> > postgresql.jar but then it was compiled for 6.5.2.. Can i use\n> > the same jar file or do i need to get a seperate one for 7.0\n> > Any help will be appreciated Bye Anand\n> > \n> > \n> \n> We were discussing it just today. We hope to have the web site updated\n> soon. Can you describe the problem you are having?\n> \n\n", "msg_date": "Wed, 3 May 2000 09:23:36 +0530", "msg_from": "\"Anand Raman\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: postgresql7.0 jdbc driver" }, { "msg_contents": "[Charset iso-8859-1 unsupported, filtering to ASCII...]\n> HI guys\n> Thanx for the quick reply.. \n> \n> When i tried compiling jdbc for postgresql700 I encounter the following error\n> \n> postgres@localhost > make jdbc1\n> (echo \"package postgresql;\" ;\\\n> echo \"public class DriverClass {\" ;\\\n> echo \"public static String connectClass=\\\"postgresql.jdbc1.Connection\\\";\" ;\\\n> echo \"}\" \\\n> ) >postgresql/DriverClass.java\n> make[1]: Entering directory `/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\n> javac -g postgresql/DriverClass.java\n> javac -g postgresql/Connection.java\n> postgresql/Connection.java:447: Wrong number of arguments in constructor.\n> fields[i] = new Field(this, typname, typid, typlen, typmod);\n> ^\n> 1 error\n> make[1]: *** [postgresql/Connection.class] Error 1\n> make[1]: Leaving directory `/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\n> make: *** [jdbc1] Error 2\n> \n> same is the case with $ make jdbc2\n\nWhat java are you using?\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 23:53:56 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [GENERAL] postgresql7.0 jdbc driver" }, { "msg_contents": "Hi Bruce\nI am using jdk1.2.2 \njava version \"1.2.2-RC2\"\nClassic VM (build 1.2.2-RC2-K, green threads, javacomp) \nBye\nAnand Raman\n----- Original Message ----- \nFrom: Bruce Momjian <[email protected]>\nTo: Anand Raman <[email protected]>\nCc: PostgreSQL-development <[email protected]>\nSent: Wednesday, May 03, 2000 9:23 AM\nSubject: Re: [GENERAL] postgresql7.0 jdbc driver\n\n\n> [Charset iso-8859-1 unsupported, filtering to ASCII...]\n> > HI guys\n> > Thanx for the quick reply.. \n> > \n> > When i tried compiling jdbc for postgresql700 I encounter the following error\n> > \n> > postgres@localhost > make jdbc1\n> > (echo \"package postgresql;\" ;\\\n> > echo \"public class DriverClass {\" ;\\\n> > echo \"public static String connectClass=\\\"postgresql.jdbc1.Connection\\\";\" ;\\\n> > echo \"}\" \\\n> > ) >postgresql/DriverClass.java\n> > make[1]: Entering directory `/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\n> > javac -g postgresql/DriverClass.java\n> > javac -g postgresql/Connection.java\n> > postgresql/Connection.java:447: Wrong number of arguments in constructor.\n> > fields[i] = new Field(this, typname, typid, typlen, typmod);\n> > ^\n> > 1 error\n> > make[1]: *** [postgresql/Connection.class] Error 1\n> > make[1]: Leaving directory `/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\n> > make: *** [jdbc1] Error 2\n> > \n> > same is the case with $ make jdbc2\n> \n> What java are you using?\n> \n> -- \n> Bruce Momjian | http://www.op.net/~candle\n> [email protected] | (610) 853-3000\n> + If your life is a hard drive, | 830 Blythe Avenue\n> + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n> \n\n", "msg_date": "Wed, 3 May 2000 09:47:28 +0530", "msg_from": "\"Anand Raman\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [GENERAL] postgresql7.0 jdbc driver" } ]
[ { "msg_contents": "> > The java IRC channel says kaffe isn't very good, so maybe I shouldn't\n> be\n> > worried about it. They also said mutually-referencing java files are\n> > not a good either.\n> > \n> > PM: This is strange, because mutually referenced java files are quite\n> > common. In fact, some of the javax.swing classes do this, and I've\n> been\n> > doing it since 1.0.2 :-) Anyhow, kaffe was taken over by M$ a few\n> months\n> > ago...\n> \n> Oh, OK, so I will not worry about the self-referencing issue. BSD/OS\n> has a java beta out, but I am too busy on the book to upgrade. I will\n> not worry about it. Seems kaffe can run the jdbc classes just fine.\n> \n> PM: I wonder if someone has told the kaffe team about it? If it runs the\n> classes, then it must be their javac that has the bug.\n\nTheir site is pretty sparse. I will send it in.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 08:27:43 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Request for 7.0 JDBC status" } ]
[ { "msg_contents": " I've ever ask my question (differently) in the other lists but no\nresponse , so i think you are my last chance ....\n\nI have the following table in my PostgreSQL Database :\n\ncreate table one ( i int4 , j int4) ;\n\ncreate table two ( o one , id int4 ) ;\n\ninsert into one values (10, 20) ;\n\ncreate function fct() returns one as '\nselect i as i , j as j from one ; '\nlanguage 'sql';\n\ninsert into two (select fct() , 1 ) ;\n\nSo when i do : select * from two\n\n o i d\n136801144 1\n\n--------------------------------------------------\nWhat is the first number ? I 've succeed with insert a new type ( one)\ninto my base ?\nBut i can't access to the information into o ?\n\nPlease , if you have any information about this problem , please contact\nme\n\n [email protected]\n\n\nthanks\n\n\nloic\n\n", "msg_date": "Tue, 02 May 2000 14:31:51 +0200", "msg_from": "=?iso-8859-1?Q?Lo=EFc=20TREGOU=CBT?= <[email protected]>", "msg_from_op": true, "msg_subject": "insert new type (object ?)" }, { "msg_contents": "Looc TREGOUKT wrote:\n> I've ever ask my question (differently) in the other lists but no\n> response , so i think you are my last chance ....\n>\n> I have the following table in my PostgreSQL Database :\n>\n> create table one ( i int4 , j int4) ;\n>\n> create table two ( o one , id int4 ) ;\n>\n> insert into one values (10, 20) ;\n>\n> create function fct() returns one as '\n> select i as i , j as j from one ; '\n> language 'sql';\n>\n> insert into two (select fct() , 1 ) ;\n>\n> So when i do : select * from two\n>\n> o i d\n> 136801144 1\n>\n> --------------------------------------------------\n> What is the first number ? I 've succeed with insert a new type ( one)\n> into my base ?\n> But i can't access to the information into o ?\n>\n> Please , if you have any information about this problem , please contact\n> me\n\n IIRC it should be the in memory address of the tuple table\n slot returnd by the function fct() at the INSERT time. At\n least, nothing useful.\n\n This is definitely broken and for now you should stay away\n from functions returning tuples or SETs.\n\n\nJan\n\n--\n\n#======================================================================#\n# It's easier to get forgiveness for being wrong than for being right. #\n# Let's break this rule - forgive me. #\n#================================================== [email protected] #\n\n\n", "msg_date": "Tue, 2 May 2000 16:11:45 +0200 (MEST)", "msg_from": "[email protected] (Jan Wieck)", "msg_from_op": false, "msg_subject": "Re: insert new type (object ?)" } ]
[ { "msg_contents": "\nOn Sat, 29 Apr 2000, Tom Lane wrote:\n\n> Background\n> ----------\n> \n> We already do most of our memory allocation in \"memory contexts\", which\n> are usually AllocSets as implemented by backend/utils/mmgr/aset.c.\n> (Is there any value in allowing for other memory context types? We could\n\n I have \"aset\" variant, that allow create and work with memory context in\na shared memory. \n\n> save some cycles by getting rid of a level of indirection here.) What\n> we need to do is create more contexts and define proper rules about when\n> they can be freed.\n> \n> The basic operations on a memory context are:\n> \n> * create a context\n\n A questuon, need we really any name for context? I mean an example\n\"CreateGlobalMemory(char *name)\". Global memory routines expect that\na context name is static. It is a litle problem if contexts are created\ndynamic. I suggest change it and allocate context name in context memory. \n\nAbout blocks deallocation, now if context is destroyed for all blocks are\ncall free(). And if some context needs new block the aset.c call malloc(). \nWhat create a \"BlockFreeList\" with limited size (and allow set size for \nthis pool as new postmaster command line switch), and instead call the free()\nfor each block, remove a block (standard block, not a large) to this \nBlockFreeList and instead the malloc() try first look at to this list? \n \n> in that context. The MemoryContextSwitchTo() operation selects a new\n> current context (and returns the previous context, so that the caller can\n> restore the previous context before exiting).\n> \n> Note: there is no really good reason for pfree() to be tied to the current\n> memory context; it ought to be possible to pfree() a chunk of memory no\n> matter which context it was allocated from. Currently we cannot do that\n\n I not sure if I understent here. \n\nWhat the chunk->aset pointer in all chunks? It is pointer to a setData and \nthe AllocSetFree() need this pointer only. The AllocSetFree() not use full \ncontext struct. \n\n IMHO is very easy implement pfree() and repalloc() independent on \nCurrentMemoryContext setting. The MemoryContextSwitchTo() needs palloc() \nonly. Or not?\n\n\n> because of the possibility that there is more than one kind of memory\n> context. If they were all AllocSets then the problem goes away, which is\n> one reason I'd like to eliminate the provision for other kinds of\n> contexts.\n\n\n> Additions to the memory-context mechanism\n> -----------------------------------------\n> \n> If we are going to have more contexts, we need more mechanism for keeping\n> track of them; else we risk leaking whole contexts under error conditions.\n> We can do this as follows:\n> \n> 1. There will be two kinds of contexts, \"permanent\" and \"temporary\".\n> Permanent contexts are never reset or deleted except by explicit caller\n> command (in practice, they probably won't ever be, period). There will\n> not be very many of these --- perhaps only the existing TopMemoryContext\n> and CacheMemoryContext. We should avoid having very much code run with\n> CurrentMemoryContext pointing at a permanent context, since any forgotten\n> palloc() represents a permanent memory leak.\n\n And what you mean about total persistent contexts in shared memory? \nI create for the QueryCache specific top context that is stored in the \nQueryCache pool (shmem) and is independent on standard TopMemoryContext. \n\nWe probably don't know what we will need in future save to shared memory.\nIMHO is good create some common mechanism for shmem, that allow use current\nroutines (an example copyObject()) for a work with shmem.\n\n\n> 2. Temporary contexts are remembered by the context manager and are\n> guaranteed to be deleted at transaction end. (If we ever have nested\n> transactions, we'd probably want to tie each temporary context to a\n> particular transaction, but for now that's not necessary.) Most activity\n> will happen in temporary contexts.\n\nWhat is the \"context manager\"?\n\n\n Your suggestion/planns are very interesting. I agree that more contexts\n(for error, query, transactions, ..etc.) is a good idea. \n\n\t\t\t\t\t\t\tKarel\n\n", "msg_date": "Tue, 2 May 2000 14:54:24 +0200 (CEST)", "msg_from": "Karel Zak <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Proposal for fixing intra-query memory leaks" }, { "msg_contents": "Karel Zak <[email protected]> writes:\n>> (Is there any value in allowing for other memory context types? We could\n\n> I have \"aset\" variant, that allow create and work with memory context in\n> a shared memory. \n\nHmm. Well, maybe nailing things down to a single kind of context is\npushing it too far. What I mainly want is to be able to free a palloc'd\nchunk without assuming that it came from the currently active context.\nWith AllocSets as aset.c does them, this is possible because every chunk\nhas a back-link to its owning context. We could still make it work with\nmultiple context types if we require that they all have the same kind of\nback-link in the same place. Essentially, the overhead data for an\nallocated chunk would have to be the same for all context types. But\nwe could still have different context types with different allocation\nmethods for each type. pfree macro would get the back-link from 8 bytes\nbefore the given chunk address, verify that it points at something with\nthe right node type to be a memory context header, and then call through\na function pointer in the context header to get to the routine that\nactually knows how to free a chunk of that context type.\n\n> A questuon, need we really any name for context? I mean an example\n> \"CreateGlobalMemory(char *name)\". Global memory routines expect that\n> a context name is static. It is a litle problem if contexts are created\n> dynamic. I suggest change it and allocate context name in context memory. \n\nGood point. I don't believe that contexts have names at all at the\nmoment (portals do, but not contexts). But it seems like it would be\nhelpful for debugging to have some kind of name for each context. It\nwouldn't have to be unique or anything, but when you were trying to\nfigure out where your memory leak is, being able to see which context\nhas gotten bloated would be useful...\n\n> About blocks deallocation, now if context is destroyed for all blocks are\n> call free(). And if some context needs new block the aset.c call malloc(). \n> What create a \"BlockFreeList\" with limited size (and allow set size for \n> this pool as new postmaster command line switch), and instead call the free()\n> for each block, remove a block (standard block, not a large) to this \n> BlockFreeList and instead the malloc() try first look at to this list? \n\nI think this is going in the wrong direction. We are not trying to\nwrite a better malloc than malloc. What we are trying to do is make\nallocation of small chunks very fast and make it possible to release a\nwhole bunch of related chunks without keeping track of them individually.\nI don't believe that we need to improve on malloc at the level of\ngrabbing or releasing whole blocks.\n\n> IMHO is very easy implement pfree() and repalloc() independent on \n> CurrentMemoryContext setting. The MemoryContextSwitchTo() needs palloc() \n> only. Or not?\n\nYes, but *only if the chunk you are being asked to pfree came from an\nAllocSet-style context*. Currently it could have come from a different\nkind of context that isn't based on AllocSets. (I think we have some\ncontexts where palloc is just a direct malloc, for example.)\n\n> And what you mean about total persistent contexts in shared memory? \n> I create for the QueryCache specific top context that is stored in the \n> QueryCache pool (shmem) and is independent on standard TopMemoryContext. \n\nQueryCache would probably be a permanent context ...\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 02 May 2000 12:25:51 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Proposal for fixing intra-query memory leaks " }, { "msg_contents": "\n\nOn Tue, 2 May 2000, Tom Lane wrote:\n\n> Karel Zak <[email protected]> writes:\n> >> (Is there any value in allowing for other memory context types? We could\n> \n> > I have \"aset\" variant, that allow create and work with memory context in\n> > a shared memory. \n> \n> Hmm. Well, maybe nailing things down to a single kind of context is\n> pushing it too far. What I mainly want is to be able to free a palloc'd\n> chunk without assuming that it came from the currently active context.\n\n With my QueryCache contexts it will possible too. I use same AllocSet \nstructs - different is only a block spring (not from malloc, but from \nQueryCache shmem pool). Change chunks headers will easy if it will need. \n\n A problem will, how select right method for free/realloc. This information\nis only in context struct, but not in a chunk header or in AllocSet struct\n(now).\n\n> With AllocSets as aset.c does them, this is possible because every chunk\n> has a back-link to its owning context. We could still make it work with\n> multiple context types if we require that they all have the same kind of\n> back-link in the same place. Essentially, the overhead data for an\n> allocated chunk would have to be the same for all context types. But\n> we could still have different context types with different allocation\n> methods for each type. pfree macro would get the back-link from 8 bytes\n> before the given chunk address, verify that it points at something with\n\n OK. You need in chunk header chunk-size too, not the back-to-context-link \nonly.\n\n> the right node type to be a memory context header, and then call through\n> a function pointer in the context header to get to the routine that\n> actually knows how to free a chunk of that context type.\n\n The idea it is very good, because if we will work with more context and\nallocations types we need identify chunks. \n\n The chunk header must be relevant and same for all allocation methods and\nmust be independent on AllocSel (aset.c) code. Now, it is not. Am I right?\n\n \n> Good point. I don't believe that contexts have names at all at the\n> moment (portals do, but not contexts). But it seems like it would be\n> helpful for debugging to have some kind of name for each context. It\n> wouldn't have to be unique or anything, but when you were trying to\n> figure out where your memory leak is, being able to see which context\n> has gotten bloated would be useful...\n\n Well, but not expect that header must be static string, better will\n_allocate_ it in a CreateContext() function.\n\n\n\t\t\t\t\t\tKarel\n\n", "msg_date": "Tue, 2 May 2000 19:23:38 +0200 (CEST)", "msg_from": "Karel Zak <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Proposal for fixing intra-query memory leaks " }, { "msg_contents": "\nOn Tue, 2 May 2000, Tom Lane wrote:\n\n> Karel Zak <[email protected]> writes:\n> > The chunk header must be relevant and same for all allocation methods and\n> > must be independent on AllocSel (aset.c) code. Now, it is not. Am I right?\n> \n> Right. Actually it would work to have additional data before the\n> standard link-to-context-plus-chunk-size fields, if a particular method\n> really needed more per-chunk data. But I doubt we'd ever need that.\n\n The chunk:\n\n +--------------------+----------------------+-------------------+\n | depend-header | standard-header | data............. | \n +--------------------+----------------------+-------------------+\n ^ ^ ^\n | | |\n | | pointer to chunk \n | |\n | begin of standard chunk header \n |\n particular method header, begin of \n this header is unknown for common routines. \n\n\n IMHO in standard chunk header not must be chunk size. If something needs\nchunk size it cat use depend-header. \n\n It will very nice :-)\n\n\t\t\t\t\t\t\tKarel\n\n", "msg_date": "Tue, 2 May 2000 23:22:17 +0200 (CEST)", "msg_from": "Karel Zak <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Proposal for fixing intra-query memory leaks " }, { "msg_contents": "Karel Zak <[email protected]> writes:\n> The chunk header must be relevant and same for all allocation methods and\n> must be independent on AllocSel (aset.c) code. Now, it is not. Am I right?\n\nRight. Actually it would work to have additional data before the\nstandard link-to-context-plus-chunk-size fields, if a particular method\nreally needed more per-chunk data. But I doubt we'd ever need that.\n\nAnd, as you saw, the links to the pfree and prealloc routines would need\nto be present in standard places in the context header.\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 02 May 2000 17:26:09 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Proposal for fixing intra-query memory leaks " }, { "msg_contents": "Thanks for the timely introduction to memory contexts btw. :)\n\n> 1. There will be two kinds of contexts, \"permanent\" and \"temporary\".\n\nRather than making this an explicit distinction you could simply (hah)\nmake the transaction initiating command create a memory context under Top\nand store a pointer to it in a global variable. Then per tuple contexts,\netc. are created as a child thereof. The transaction ending commands would\nthen destroy that context again. I guess this is sort of what you were\nplanning anyway but I just wanted to throw in that specially treating this\n\"everything lives and dies with the transaction\" attitude is not the\nbe-all-end-all, IMHO. (\"Statement\" would be better than \"transaction\" in\nmany cases anyway.)\n\n> Functions that return pass-by-reference values will be required always\n> to palloc the returned space in the caller's memory context (ie, the\n> context that was CurrentMemoryContext at the time of call). It is not\n> OK to pass back an input pointer, even if we are returning an input value\n> verbatim, because we do not know the lifespan of the context the input\n> pointer points to.\n\nISTM that you can have the compiler help you here if you separate input\nand output values in the function manager design. E.g., if you define the\nfunction signature like\n\n\tvoid my_func(const fmgr_in_t * in, fmgr_out_t * out);\n\nthen you establish the fact that copying is required.\n\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Tue, 2 May 2000 23:29:06 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Proposal for fixing intra-query memory leaks" }, { "msg_contents": "Peter Eisentraut <[email protected]> writes:\n>> 1. There will be two kinds of contexts, \"permanent\" and \"temporary\".\n\n> Rather than making this an explicit distinction you could simply (hah)\n> make the transaction initiating command create a memory context under Top\n> and store a pointer to it in a global variable. Then per tuple contexts,\n> etc. are created as a child thereof. The transaction ending commands would\n> then destroy that context again. I guess this is sort of what you were\n> planning anyway\n\nYes, it was. You're right that the lifespan of a context will be\ndetermined by usage; there's not any real distinction between permanent\nand temporary contexts as far as the mechanism goes. I thought it would\nbe clearer to describe it that way, but maybe not.\n\nAlso, yes, the topmost contexts in the tree of contexts will be\nreferenced via pointers in global variables. An alternative approach\nwould be to provide some kind of lookup-by-name facility (like portals\nhave) but I think that'd likely be overkill. We've gotten along fine\nwith pointers for TopMemoryContext, CacheMemoryContext, etc, so it seems\nthat's good enough.\n\n>> Functions that return pass-by-reference values will be required always\n>> to palloc the returned space in the caller's memory context (ie, the\n>> context that was CurrentMemoryContext at the time of call). It is not\n>> OK to pass back an input pointer, even if we are returning an input value\n>> verbatim, because we do not know the lifespan of the context the input\n>> pointer points to.\n\n> ISTM that you can have the compiler help you here if you separate input\n> and output values in the function manager design. E.g., if you define the\n> function signature like\n> \tvoid my_func(const fmgr_in_t * in, fmgr_out_t * out);\n> then you establish the fact that copying is required.\n\nGiven the amount of casting that we do between Datum and other types,\nI don't think that const decorations would actually help much :-(.\nOn most compilers you can cast away const without noticing.\n\nJan is of the opinion that this you-must-palloc-your-result rule is\nwrongheaded anyway, so the issue may go away if he persuades me...\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 02 May 2000 17:37:55 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Proposal for fixing intra-query memory leaks " }, { "msg_contents": "Karel Zak <[email protected]> writes:\n> IMHO in standard chunk header not must be chunk size. If something needs\n> chunk size it cat use depend-header. \n\nWe might as well put the size in the standard header, though, because\n(a) all context management methods are going to need it (how you gonna\ndo repalloc otherwise?) and (b) there are alignment considerations.\nThe size of the headers has to be a multiple of MAXALIGN which is 8\non quite a few architectures. If you just make each of the\nstandard-header and depend-header a multiple of MAXALIGN then you end\nup wasting 8 bytes per alloc chunk on these machines. You could get\naround that with some notational ugliness (ie, standard header is not\ndeclared as part of depend-header but you compute the pointer to it\nseparately). But I don't see the value of working that hard to keep\nthe size out of the standard header.\n\nAlso, since aset.c is going to be our standard memory allocator for\nthe foreseeable future, there's no good reason to make its life more\ndifficult by having to work with both a standard-header and a\ndepend-header. If it can get along with only a standard-header,\nwhy not let it do so?\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 02 May 2000 18:01:03 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Proposal for fixing intra-query memory leaks " }, { "msg_contents": "FYI, Tom, is this still relivant?\n\n> This issue seems to have been on the back burner for a while,\n> but I think we need to put it on the front burner again for 7.1.\n> Here is a think-piece I just did. I'd appreciate comments,\n> particularly about possible interactions with TOAST --- Jan,\n> did you have any particular plan in mind for freeing datums created\n> by de-TOASTing?\n> \n> \t\t\tregards, tom lane\n> \n> \n> Proposal for memory allocation fixes\t\t\t29-Apr-2000\n> ------------------------------------\n> \n> We know that Postgres has serious problems with memory leakage during\n> large queries that process a lot of pass-by-reference data. There is\n> no provision for recycling memory until end of query. This needs to be\n> fixed, even more so with the advent of TOAST which will allow very\n> large chunks of data to be passed around in the system. Furthermore,\n> 7.1 is an ideal time for fixing it since TOAST and the function-manager\n> interface changes will require visiting a lot of the same code that needs\n> to be cleaned up. So, here is a proposal.\n> \n> \n> Background\n> ----------\n> \n> We already do most of our memory allocation in \"memory contexts\", which\n> are usually AllocSets as implemented by backend/utils/mmgr/aset.c.\n> (Is there any value in allowing for other memory context types? We could\n> save some cycles by getting rid of a level of indirection here.) What\n> we need to do is create more contexts and define proper rules about when\n> they can be freed.\n> \n> The basic operations on a memory context are:\n> \n> * create a context\n> \n> * delete a context (including freeing all the memory allocated therein)\n> \n> * reset a context (free all memory allocated in the context, but not the\n> context object itself)\n> \n> Given a context, one can allocate a chunk of memory within it, free a\n> previously allocated chunk, or realloc a previously allocated chunk larger\n> or smaller. (These operations correspond directly to standard C's\n> malloc(), free(), and realloc() routines.) At all times there is a\n> \"current\" context denoted by the CurrentMemoryContext global variable.\n> The backend macros palloc(), pfree(), prealloc() implicitly allocate space\n> in that context. The MemoryContextSwitchTo() operation selects a new\n> current context (and returns the previous context, so that the caller can\n> restore the previous context before exiting).\n> \n> Note: there is no really good reason for pfree() to be tied to the current\n> memory context; it ought to be possible to pfree() a chunk of memory no\n> matter which context it was allocated from. Currently we cannot do that\n> because of the possibility that there is more than one kind of memory\n> context. If they were all AllocSets then the problem goes away, which is\n> one reason I'd like to eliminate the provision for other kinds of\n> contexts.\n> \n> The main advantage of memory contexts over plain use of malloc/free is\n> that the entire contents of a memory context can be freed easily, without\n> having to request freeing of each individual chunk within it. This is\n> both faster and more reliable than per-chunk bookkeeping. We already use\n> this fact to clean up at transaction end: by resetting all the active\n> contexts, we reclaim all memory. What we need are additional contexts\n> that can be reset or deleted at strategic times within a query, such as\n> after each tuple.\n> \n> \n> Additions to the memory-context mechanism\n> -----------------------------------------\n> \n> If we are going to have more contexts, we need more mechanism for keeping\n> track of them; else we risk leaking whole contexts under error conditions.\n> We can do this as follows:\n> \n> 1. There will be two kinds of contexts, \"permanent\" and \"temporary\".\n> Permanent contexts are never reset or deleted except by explicit caller\n> command (in practice, they probably won't ever be, period). There will\n> not be very many of these --- perhaps only the existing TopMemoryContext\n> and CacheMemoryContext. We should avoid having very much code run with\n> CurrentMemoryContext pointing at a permanent context, since any forgotten\n> palloc() represents a permanent memory leak.\n> \n> 2. Temporary contexts are remembered by the context manager and are\n> guaranteed to be deleted at transaction end. (If we ever have nested\n> transactions, we'd probably want to tie each temporary context to a\n> particular transaction, but for now that's not necessary.) Most activity\n> will happen in temporary contexts.\n> \n> 3. When a context is created, an existing context can be specified as its\n> parent; thus a tree of contexts is created. Resetting or deleting any\n> particular context resets or deletes all its direct and indirect children\n> as well. This feature allows us to manage a lot of contexts without fear\n> that some will be leaked; we just have to make sure everything descends\n> from one context that we remember to zap at transaction end.\n> \n> In practice, point #2 doesn't require any special support in the context\n> manager as long as it supports point #3. We simply start a new context\n> for each transaction and delete it at transaction end. All temporary\n> contexts created within the transaction must be direct or indirect\n> children of this \"transaction top context\".\n> \n> Note: it would probably be possible to adapt the existing \"portal\" memory\n> management mechanism to do what we need. I am instead proposing setting\n> up a totally new mechanism, because the portal code strikes me as\n> extremely crufty and unwieldy. It may be that we can eventually remove\n> portals entirely, or perhaps reimplement them with this mechanism\n> underneath.\n> \n> \n> Top-level (permanent) memory contexts\n> -------------------------------------\n> \n> We currently have TopMemoryContext and CacheMemoryContext as permanent\n> memory contexts. The existing usages of these are probably OK, although\n> it might be a good idea to examine usages of TopMemoryContext to see if\n> they should go somewhere else.\n> \n> It might also be a good idea to set up a permanent ErrorMemoryContext that\n> elog() can switch into for processing an error; this would ensure that\n> there is at least ~8K of memory available for error processing, even if\n> we've run out otherwise. (ErrorMemoryContext could be reset, but not\n> deleted, after each successful error recovery.)\n> \n> We will also create a global variable TransactionTopMemoryContext, which\n> is valid at all times. Memory recovery at end of transaction is done by\n> deleting and immediately recreating this context. All transaction-local\n> contexts are created as children of TransactionTopMemoryContext, so that\n> they go away at transaction end too. (If we implement nested\n> transactions, it could be that TransactionTopMemoryContext will itself be\n> a child of some outer transaction's top context, but that's beyond the\n> scope of this proposal.)\n> \n> \n> Transaction-local memory contexts\n> ---------------------------------\n> \n> Relatively little stuff should get allocated directly in\n> TransactionTopMemoryContext; the bulk of the action should happen in\n> sub-contexts. I propose the following:\n> \n> QueryTopMemoryContext: this child of TransactionTopMemoryContext is\n> created at the start of each query cycle and deleted upon successful\n> completion. (On error, of course, it goes away because it is a child of\n> TransactionTopMemoryContext.) The query input buffer is allocated in this\n> context, as well as anything else that should live just till end of query.\n> \n> ParsePlanMemoryContext: this child of QueryTopMemoryContext is working\n> space for the parse/rewrite/plan/optimize pipeline. After completion\n> of planning, the final query plan is copied via copyObject() back into\n> QueryTopMemoryContext, and then the ParsePlanMemoryContext can be deleted.\n> This allows us to recycle the (perhaps large) amount of memory used by\n> planning before actual query execution starts.\n> \n> Execution per-run memory contexts: at startup, the executor will create a\n> child of QueryTopMemoryContext to hold data that should live until\n> ExecEndPlan; an example is the plan-node-local execution state. Some plan\n> node types may want to create shorter-lived contexts that are children of\n> their parent's per-run context. For example, a subplan node would create\n> its own \"per run\" context so that memory could be freed at completion of\n> each invocation of the subplan.\n> \n> Execution per-tuple memory contexts: each per-run context will have a\n> child context that the executor will reset (not delete) each time through\n> the node's per-tuple loop. This per-tuple context will be the active\n> CurrentMemoryContext most of the time during execution.\n> \n> By resetting the per-tuple context, we will be able to free memory after\n> each tuple is processed, rather than only after the whole plan is\n> processed. This should solve our memory leakage problems pretty well;\n> yet we do not need to add very much new bookkeeping logic to do it.\n> In particular, we do *not* need to try to keep track of individual values\n> palloc'd during expression evaluation.\n> \n> Note we assume that resetting a context is a cheap operation. This is\n> true already, and we can make it even more true with a little bit of\n> tuning in aset.c.\n> \n> \n> Coding rules required\n> ---------------------\n> \n> Functions that return pass-by-reference values will be required always\n> to palloc the returned space in the caller's memory context (ie, the\n> context that was CurrentMemoryContext at the time of call). It is not\n> OK to pass back an input pointer, even if we are returning an input value\n> verbatim, because we do not know the lifespan of the context the input\n> pointer points to. An example showing why this is necessary is provided\n> by aggregate-function execution. The aggregate function executor must\n> retain state values returned by state-transition functions from one tuple\n> to the next. Yet it does not want to keep them till end of run; that\n> would be a memory leak. The solution nodeAgg.c will use is to have two\n> per-tuple memory contexts that are used alternately. At each tuple,\n> an old state value existing in one context is passed to the state\n> transition function, which will return its result in the other context\n> (since that'll be where CurrentMemoryContext points). Then the first\n> context is reset and used as the target for the next cycle. This solution\n> works as long as the transition function always returns a newly palloc'd\n> datum, and never simply returns a pointer to its input data.\n> \n> Thus, a function must use the passed-in CurrentMemoryContext for\n> allocating its result data, and can use it for any temporary storage it\n> needs as well. pfree'ing such temporary data before return is possible\n> but not essential.\n> \n> Executor routines that switch the active CurrentMemoryContext may need\n> to copy data into their caller's current memory context before returning.\n> I think there will be relatively little need for that, if we use a\n> convention of resetting the per-tuple context at the *start* of an\n> execution cycle rather than at its end. With that rule, an execution\n> node can return a tuple that is palloc'd in its per-tuple context, and\n> the tuple will remain good until the node is called for another tuple\n> or told to end execution. This is pretty much the same state of affairs\n> that exists now, since a scan node can return a direct pointer to a tuple\n> in a disk buffer that is only guaranteed to remain good that long.\n> \n> A more common reason for copying data will be to transfer a result from\n> per-tuple context to per-run context; for example, a Unique node will\n> save the last distinct tuple value in its per-run context, requiring a\n> copy step. (Actually, Unique could use the same trick with two per-tuple\n> contexts as described above for Agg, but there will probably be other\n> cases where doing an extra copy step is the right thing.)\n> \n> \n> Other notes\n> -----------\n> \n> It might be that the executor per-run contexts described above should\n> be tied directly to executor \"EState\" nodes, that is, one context per\n> EState. I'm not real clear on the lifespan of EStates or the situations\n> where we have just one or more than one, so I'm not sure. Comments?\n> \n> With so many contexts running around, I think it will be almost essential\n> to allow pfree() to work on chunks belonging to contexts other than the\n> current one. If we don't get rid of the notion of multiple allocation\n> context types then some other work will have to be expended to make this\n> possible. Also, should we allow prealloc() to work on a chunk not\n> belonging to the current context? I'm less excited about allowing that,\n> but it may prove useful.\n> \n\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Mon, 12 Jun 2000 20:15:01 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Proposal for fixing intra-query memory leaks" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n> FYI, Tom, is this still relivant?\n\nYes, and I'll probably do something about it as soon as I can come up\nfor air from the fmgr fixes. Man, we have got a *lot* of built-in\nfunctions.\n\n\t\t\tregards, tom lane\n", "msg_date": "Mon, 12 Jun 2000 22:30:20 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Proposal for fixing intra-query memory leaks " } ]
[ { "msg_contents": "By the sounds of it, it did get in (because the earlier one wouldn't\nhave known about the org change).\n\nPeter\n\n-- \nPeter Mount\nEnterprise Support\nMaidstone Borough Council\nAny views stated are my own, and not those of Maidstone Borough Council.\n\n\n-----Original Message-----\nFrom: Thomas Lockhart [mailto:[email protected]]\nSent: Tuesday, May 02, 2000 2:15 PM\nTo: Bruce Momjian\nCc: Peter Mount; Lamar Owen; PostgreSQL-development;\nPostgreSQL-interfaces\nSubject: Re: [HACKERS] Request for 7.0 JDBC status\n\n\n> I got the file that Jan overwrote to fix Peter's overwrite and\ninstalled\n> that in the jdbc directory.\n\nYeah, I understood that. Peter will speak up soon, but he indicated\nthat he wasn't sure that his new Makefile ever made it into CVS in the\nfirst place, if I read his mail correctly.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Tue, 2 May 2000 14:25:35 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: [HACKERS] Request for 7.0 JDBC status" } ]
[ { "msg_contents": "> How do I go about submitting a patch to the tree? I've\n> done the work to get libpq running on BeOS, although it looks\n> like psql has some curses problems (I can pass a query on the\n> command line and have it work). It isn't much of a patch--mostly\n> Makefiles and a hand-written getprotobyname and a few places\n> where I have twiddled with set/get sockopt.\n\nWe had heard earlier that getting the server-side part of the code\nported to BeOS was not likely to be possible, due to differences in\nPosix compliance and threading models. Is that still the case, and you\nare only planning the client-side libraries for now? I'd like to\nmention it as a possibility in the \"Unsupported Platforms\" list in the\nupcoming release...\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Tue, 02 May 2000 13:40:43 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Patch submission" }, { "msg_contents": "On Tue, May 02, 2000 at 01:40:43PM +0000, Thomas Lockhart wrote:\n> > How do I go about submitting a patch to the tree? I've\n> > done the work to get libpq running on BeOS, although it looks\n> > like psql has some curses problems (I can pass a query on the\n> > command line and have it work). It isn't much of a patch--mostly\n> > Makefiles and a hand-written getprotobyname and a few places\n> > where I have twiddled with set/get sockopt.\n> \n> We had heard earlier that getting the server-side part of the code\n> ported to BeOS was not likely to be possible, due to differences in\n> Posix compliance and threading models. Is that still the case, and you\n> are only planning the client-side libraries for now? I'd like to\n> mention it as a possibility in the \"Unsupported Platforms\" list in the\n> upcoming release...\n\n\tThe server-side requires mmap() support, which BeOS does not\ncurrently have. Other then that, PostgreSQL only uses fork()/exec()\nAFAIK, so it should work. There are also networking issues, since\nsockets are not file descriptors in BeOS for at least another release.\nThe network stack is being rewritten and will soon be in Beta. I've\ndone quick&dirty ports of the client-side before, but this is the first\ntime I'm doing it in ways that don't break everything else.\n\n\tI'll have to find some time to sort out the reason that psql\nis exiting as soon as it starts and bundle my patches up. I should\nbe able to get this done within the week (although I said that last\nweek). You could mention BeOS in the Platforms list as \"client support\npending\" I guess. Server support will be somewhat pointless until the\nnew network stack is released and even then will require some work\nto get the shared memory/IPC working.\n\n-- \nAdam Haberlach |\"You have to understand that the\[email protected] | entire 'Net is based on people with\nhttp://www.newsnipple.com/ | too much free time on their hands.\"\n", "msg_date": "Tue, 2 May 2000 08:45:11 -0700", "msg_from": "Adam Haberlach <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Patch submission" } ]
[ { "msg_contents": "I'm planning on uploading the hardcopy docs and man pages to\npostgresql.org in an hour or two. Will confirm that it happened when I\nreturn home from work this evening (in 8-10 hours).\n\nThe docs ToDo list for release is (afaicr):\n\n1) Generate the INSTALL text file and commit.\n2) Modify the release tarball builder (scrappy?) to\n - pick up the usual hardcopy, man pages, and html tarballs\n - pick up additional new hardcopy files in A4 format\n (additional distro tarball?)\n3) If there is time:\n - fix missing URL links within the chapter on ecpg in user.ps\n - do minor formatting cleanup in user.ps reference pages\n\nThe A4-formatted files should be more usable for our non-US\ncolleagues.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Tue, 02 May 2000 15:56:14 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": true, "msg_subject": "Hardcopy docs about ready" }, { "msg_contents": "OK, the docs were uploaded a few hours ago. Look in\n\n http://postgresql.org/users-lounge/7.0/docs/\n\nfor some gzipped .ps and .tar files. Apparently scrappy has already\nbuilt a release candidate with these files included.\n\nMarc, how did you handle the A4 format files? Are they included with\neverything else, or are (some of) the docs split into separate\ntarballs for distribution?\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Wed, 03 May 2000 04:25:43 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Hardcopy docs about ready" }, { "msg_contents": "On Wed, 3 May 2000, Thomas Lockhart wrote:\n\n> OK, the docs were uploaded a few hours ago. Look in\n> \n> http://postgresql.org/users-lounge/7.0/docs/\n> \n> for some gzipped .ps and .tar files. Apparently scrappy has already\n> built a release candidate with these files included.\n> \n> Marc, how did you handle the A4 format files? Are they included with\n> everything else, or are (some of) the docs split into separate\n> tarballs for distribution?\n\nDamn damn damn ... okay, I only included the .tar.gz files in the\ndistribution :( I'll change it to include all the .gz files, and do\na quick 'docs fix' RC4 over the next day or so, once we have this all\nsorted out ...\n\nAs things are now, there is one big tar file that has everything, and then\nsmaller tar files that split up the distribution into more manageable\nchunks, docs being one of them ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 3 May 2000 01:34:01 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Hardcopy docs about ready" } ]
[ { "msg_contents": "Ben Adida of the OpenACS project has written a nice summary of\nwhy MySQL sucks for serious work (such as our toolkit). He's\nwritten it in response to the endless stream of questions we get\nfrom folks asking why we're not basing our work on MySQL.\n\nI think you'll enjoy it.\n\nhttp://openacs.org/doc/acspg/why-not-mysql.html\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Tue, 02 May 2000 10:03:50 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [Acs-pg-dev] another milestone!" } ]
[ { "msg_contents": "\n>Actually, I'm changing the link\n>\n>http://openacs.org/why-not-mysql.html\n\nMoments after forwarding the link to Ben's piece on why\nMySQL sucks to this list, he e-mailed me the above note.\n\nSorry for any inconvenience...\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Tue, 02 May 2000 10:19:53 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": true, "msg_subject": "Why Not MySQL?" }, { "msg_contents": "> \n> >Actually, I'm changing the link\n> >\n> >http://openacs.org/why-not-mysql.html\n> \n> Moments after forwarding the link to Ben's piece on why\n> MySQL sucks to this list, he e-mailed me the above note.\n> \n> Sorry for any inconvenience...\n\nI am adding this to the FAQ.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 17:55:06 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "A very, very good article. I love the comment about MySQL being a filesystem\nwith an SQL interface :-)\n\nHowever.. I'm faced with a huge dilemma.\n\nWe use PostgreSQL for a fairly large application I wrote, the database is\nstill pretty small, it carries info on about 25-30,000 people and about\n5,000 jobs. Recently we've had huge trouble with PostgreSQL -- it seems that\nevery month I stump someone with the obscure things that happen to our data\n:-)\n\n From corrupted indexes to corrupted system tables, it's almost always\nunrecoverable. Luckily I always have a backup to restore from and the world\ngoes on... We've only recently started to notice that the backend is slowing\ndown. It seems that with every additional applicant added it get\nexponentially slower... So, sadly I have to go find another backend for this\napplication -- a commercial one too so we can get \"commercial support\"\n(yuck)..\n\nSo, could you guys suggest some other backends I might look into? I know\nit's an odd place for me to ask but the flat truth is that I think *I* am to\nblame for my Postgres troubles and even taking all of the problems into\naccount I think PG is the best damn free RDBMS out there. It's functionality\nis superior to everyone else's, it's developers are no less than amazing and\nwell -- I trust you guys to give me some honest opinions.. The functionality\nI need is basically what PG has.. Transactions are a must as well as some\nsort of sequence -- stability over performance but performance is very\nimportant too. It also needs to run native on FreeBSD..\n\nOracle is out as we use FreeBSD and someone out there decided that they\nwouldn't support FreeBSD (in the license as well as in the code!)..\n\nThanks guys, especially to all who tried to help in private (Don, Tom --\nmany others)..\n\n-Mitch\n\n----- Original Message -----\nFrom: Bruce Momjian <[email protected]>\nTo: Don Baccus <[email protected]>\nCc: <[email protected]>\nSent: Tuesday, May 02, 2000 5:55 PM\nSubject: Re: [HACKERS] Why Not MySQL?\n\n\n> >\n> > >Actually, I'm changing the link\n> > >\n> > >http://openacs.org/why-not-mysql.html\n> >\n> > Moments after forwarding the link to Ben's piece on why\n> > MySQL sucks to this list, he e-mailed me the above note.\n> >\n> > Sorry for any inconvenience...\n>\n> I am adding this to the FAQ.\n>\n> --\n> Bruce Momjian | http://www.op.net/~candle\n> [email protected] | (610) 853-3000\n> + If your life is a hard drive, | 830 Blythe Avenue\n> + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n>\n\n", "msg_date": "Tue, 2 May 2000 18:28:31 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "At 06:28 PM 5/2/00 -0400, Mitch Vincent wrote:\n\n>So, could you guys suggest some other backends I might look into? I know\n>it's an odd place for me to ask but the flat truth is that I think *I* am to\n>blame for my Postgres troubles and even taking all of the problems into\n>account I think PG is the best damn free RDBMS out there. It's functionality\n>is superior to everyone else's, it's developers are no less than amazing and\n>well -- I trust you guys to give me some honest opinions.. The functionality\n>I need is basically what PG has.. Transactions are a must as well as some\n>sort of sequence -- stability over performance but performance is very\n>important too. It also needs to run native on FreeBSD..\n\nFirst, have you been having the same problems with PG 7.0? I recall that\nyou had it up on a test system but nothing more. \n\nIt's a pity that you've reached this point, because PG is so much better\nthan it was 18 months ago (and before, of course, I mention that timeframe\nbecause that's roughly when I first investigated its suitability for\nthe web toolkit project) and the trajectory is definitely in the right\ndirection.\n\nIt's also a loss to the development effort, as people with bugs in many\nways are more useful than people who have no problems (though of course\nhaving no bugs for users to stumble across is the best situation!)\n\nStill, I understand the need to solve your problems today, not tomorrow.\n\nInterbase is a possible solution. They have a pretty good reputation,\nand their \"super server\" (threaded with connections sharing a buffer\ncache) should scale well. My rough estimate is that they're at about\nthe place PG will be when 7.1 comes out. I don't know if they support\nFreeBSD, though. Any reason you can't just put up a box with Linux?\n\nThere's an older version of Sybase available at no charge, again\nonly for Linux, though.\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Tue, 02 May 2000 15:59:39 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "> exponentially slower... So, sadly I have to go find another backend for this\n> application -- a commercial one too so we can get \"commercial support\"\n> (yuck)..\n\nActually you might want to give Interbase a try. Version 6 is now in\nbeta and is going to be open sourced. It's been around a while and seems\npretty solid. There will be a commercial entity to buy support\ncontracts from and the newsgroups are very helpful. As a bonus there is\na realatively large installed user base already and very very nice\nclient side tools available. See http://www.interbase.com/ or\nhttp://www.interbase2000.com/ for further details.\n\nIf I can't get my questions answered about case sensitivity issues here\n(no help so far) I will most likely to use it myself. \n\n> I need is basically what PG has.. Transactions are a must as well as some\n> sort of sequence -- stability over performance but performance is very\n> important too. It also needs to run native on FreeBSD..\n\nIB supports transactions and sequences. It's very stable and pretty\nfast. There was a problem with shared memory in the early beta and\nearlier releases but it's fixed now. I am pretty sure it runs on FreeBSD\nbut I am not sure if it runs natively or under linux emulation.\n", "msg_date": "Tue, 02 May 2000 17:00:45 -0600", "msg_from": "Tim Uckun <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "On Tue, 2 May 2000, Tim Uckun wrote:\n\n> If I can't get my questions answered about case sensitivity issues here\n> (no help so far) I will most likely to use it myself. \n\nWhat questions? *raised eyebrow* \n\n\n", "msg_date": "Tue, 2 May 2000 22:19:49 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "\nAs Don asks, what happened with the v7.0 trials you were doing? Corrupted\nindices, I've seen occasionally in older versions, but I can't recall ever\nseeing corrupt system tables ...\n\nI don't have a GUI browser right, so searching the archives is kinda tough\nfor me :( Can you refresh my memory for me? There has to be something\nlogical to this, as to what the cause for the corruption is :(\n\n From Don's comment, I take it you are using FreeBSD? Version? Stability\nof the machine? Never crashes?\n\nVersion of PostgreSQL? Compile/configure options? Do you have any core\nfiles in your data/base/* hierarchy that would be the result of a backend\ncrashing? \n\nI know you are looking at alternatives, but I'm terrible at letting go of\nproblems :(\n\n\nOn Tue, 2 May 2000, Mitch Vincent wrote:\n\n> A very, very good article. I love the comment about MySQL being a filesystem\n> with an SQL interface :-)\n> \n> However.. I'm faced with a huge dilemma.\n> \n> We use PostgreSQL for a fairly large application I wrote, the database is\n> still pretty small, it carries info on about 25-30,000 people and about\n> 5,000 jobs. Recently we've had huge trouble with PostgreSQL -- it seems that\n> every month I stump someone with the obscure things that happen to our data\n> :-)\n> \n> >From corrupted indexes to corrupted system tables, it's almost always\n> unrecoverable. Luckily I always have a backup to restore from and the world\n> goes on... We've only recently started to notice that the backend is slowing\n> down. It seems that with every additional applicant added it get\n> exponentially slower... So, sadly I have to go find another backend for this\n> application -- a commercial one too so we can get \"commercial support\"\n> (yuck)..\n> \n> So, could you guys suggest some other backends I might look into? I know\n> it's an odd place for me to ask but the flat truth is that I think *I* am to\n> blame for my Postgres troubles and even taking all of the problems into\n> account I think PG is the best damn free RDBMS out there. It's functionality\n> is superior to everyone else's, it's developers are no less than amazing and\n> well -- I trust you guys to give me some honest opinions.. The functionality\n> I need is basically what PG has.. Transactions are a must as well as some\n> sort of sequence -- stability over performance but performance is very\n> important too. It also needs to run native on FreeBSD..\n> \n> Oracle is out as we use FreeBSD and someone out there decided that they\n> wouldn't support FreeBSD (in the license as well as in the code!)..\n> \n> Thanks guys, especially to all who tried to help in private (Don, Tom --\n> many others)..\n> \n> -Mitch\n> \n> ----- Original Message -----\n> From: Bruce Momjian <[email protected]>\n> To: Don Baccus <[email protected]>\n> Cc: <[email protected]>\n> Sent: Tuesday, May 02, 2000 5:55 PM\n> Subject: Re: [HACKERS] Why Not MySQL?\n> \n> \n> > >\n> > > >Actually, I'm changing the link\n> > > >\n> > > >http://openacs.org/why-not-mysql.html\n> > >\n> > > Moments after forwarding the link to Ben's piece on why\n> > > MySQL sucks to this list, he e-mailed me the above note.\n> > >\n> > > Sorry for any inconvenience...\n> >\n> > I am adding this to the FAQ.\n> >\n> > --\n> > Bruce Momjian | http://www.op.net/~candle\n> > [email protected] | (610) 853-3000\n> > + If your life is a hard drive, | 830 Blythe Avenue\n> > + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n> >\n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n\n", "msg_date": "Tue, 2 May 2000 22:36:32 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Corruption (Was: Re: Why Not MySQL?)" }, { "msg_contents": "> > If I can't get my questions answered about case sensitivity issues here\n> > (no help so far) I will most likely to use it myself.\n\nMy recollection is that it involved needing non-standard\ncase-insensitive LIKE comparisons to get transparent behavior with an\nexisting M$ Access app. So far, we were too polite to ask why one is\nworking so hard to maintain compatibility with a non-standard\ninterface, rather than writing the app to be portable. But I'll ask\nnow. Tim?\n\n - Thomas\n\nbtw, it seems to be the case that problems such as these, which might\nbe interesting during slow times (from a theoretical standpoint at\nleast), are decidely less so during the final stages of a release\ncycle.\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Wed, 03 May 2000 04:12:37 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "Mitch Vincent wrote:\n> \n> A very, very good article. I love the comment about MySQL being a filesystem\n> with an SQL interface :-)\n> \n> However.. I'm faced with a huge dilemma.\n> \n> We use PostgreSQL for a fairly large application I wrote, the database is\n> still pretty small, it carries info on about 25-30,000 people and about\n> 5,000 jobs. Recently we've had huge trouble with PostgreSQL -- it seems that\n> every month I stump someone with the obscure things that happen to our data\n> :-)\n\nWhat version are you using ?\n\n> >From corrupted indexes to corrupted system tables, it's almost always\n> unrecoverable. Luckily I always have a backup to restore from and the world\n> goes on... We've only recently started to notice that the backend is slowing\n> down. It seems that with every additional applicant added it get\n> exponentially slower... So, sadly I have to go find another backend for this\n> application -- a commercial one too so we can get \"commercial support\"\n> (yuck)..\n\nCould you be a little more specific on your performance issues ?\n\nThe usual way to deal wih them is tuning your db structure and/or\nqueries or \nsetting backend options to use more memory for stuff or other such\nthings. \n\nIf there is something wrong with the structure or queries, then a\ndatabase \nswitch will help you very little, unless your front-end tool has some\nspecial\nsupport for _some_ databases and not for others.\n\n> So, could you guys suggest some other backends I might look into?\n\nThe usual - Oracle, Interbase, Informix, DB2, Sybase, Solid \n\nThe website is usually obtained by putting www inf front and com at the\nend ;)\n\nAnd let us know of your results.\n\n> I know\n> it's an odd place for me to ask but the flat truth is that I think *I* am to\n> blame for my Postgres troubles and even taking all of the problems into\n> account I think PG is the best damn free RDBMS out there. It's functionality\n> is superior to everyone else's, it's developers are no less than amazing and\n> well -- I trust you guys to give me some honest opinions.. The functionality\n> I need is basically what PG has.. Transactions are a must as well as some\n> sort of sequence -- stability over performance but performance is very\n> important too. It also needs to run native on FreeBSD..\n> \n> Oracle is out as we use FreeBSD and someone out there decided that they\n> wouldn't support FreeBSD (in the license as well as in the code!)..\n\nIs FreeBSD a religious issue there or can it be negotiated ?\n\n-------------\nHannu\n", "msg_date": "Wed, 03 May 2000 07:12:53 +0300", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "On Tue, 2 May 2000, The Hermit Hacker wrote:\n\n> \n> As Don asks, what happened with the v7.0 trials you were doing? Corrupted\n> indices, I've seen occasionally in older versions, but I can't recall ever\n> seeing corrupt system tables ...\n> \n> I don't have a GUI browser right, so searching the archives is kinda tough\n> for me :( Can you refresh my memory for me? There has to be something\n> logical to this, as to what the cause for the corruption is :(\n> \n> >From Don's comment, I take it you are using FreeBSD? Version? Stability\n> of the machine? Never crashes?\n> \n> Version of PostgreSQL? Compile/configure options? Do you have any core\n> files in your data/base/* hierarchy that would be the result of a backend\n> crashing? \n> \n> I know you are looking at alternatives, but I'm terrible at letting go of\n> problems :(\n\nHis description of table corruption and the system running slower and\nslower sounds like a disk going bad. I've seen it hundreds of times\non news machines. Constant retries while trying to write to the disk\nwill give slowdowns. Having data on a spot of the disk that's unreliable\nwill certainly cause data integrity problems. \n\nMitch, have you thoroughly checked the hardware? \n\nVince.\n\n\n> \n> \n> On Tue, 2 May 2000, Mitch Vincent wrote:\n> \n> > A very, very good article. I love the comment about MySQL being a filesystem\n> > with an SQL interface :-)\n> > \n> > However.. I'm faced with a huge dilemma.\n> > \n> > We use PostgreSQL for a fairly large application I wrote, the database is\n> > still pretty small, it carries info on about 25-30,000 people and about\n> > 5,000 jobs. Recently we've had huge trouble with PostgreSQL -- it seems that\n> > every month I stump someone with the obscure things that happen to our data\n> > :-)\n> > \n> > >From corrupted indexes to corrupted system tables, it's almost always\n> > unrecoverable. Luckily I always have a backup to restore from and the world\n> > goes on... We've only recently started to notice that the backend is slowing\n> > down. It seems that with every additional applicant added it get\n> > exponentially slower... So, sadly I have to go find another backend for this\n> > application -- a commercial one too so we can get \"commercial support\"\n> > (yuck)..\n> > \n> > So, could you guys suggest some other backends I might look into? I know\n> > it's an odd place for me to ask but the flat truth is that I think *I* am to\n> > blame for my Postgres troubles and even taking all of the problems into\n> > account I think PG is the best damn free RDBMS out there. It's functionality\n> > is superior to everyone else's, it's developers are no less than amazing and\n> > well -- I trust you guys to give me some honest opinions.. The functionality\n> > I need is basically what PG has.. Transactions are a must as well as some\n> > sort of sequence -- stability over performance but performance is very\n> > important too. It also needs to run native on FreeBSD..\n> > \n> > Oracle is out as we use FreeBSD and someone out there decided that they\n> > wouldn't support FreeBSD (in the license as well as in the code!)..\n> > \n> > Thanks guys, especially to all who tried to help in private (Don, Tom --\n> > many others)..\n> > \n> > -Mitch\n> > \n> > ----- Original Message -----\n> > From: Bruce Momjian <[email protected]>\n> > To: Don Baccus <[email protected]>\n> > Cc: <[email protected]>\n> > Sent: Tuesday, May 02, 2000 5:55 PM\n> > Subject: Re: [HACKERS] Why Not MySQL?\n> > \n> > \n> > > >\n> > > > >Actually, I'm changing the link\n> > > > >\n> > > > >http://openacs.org/why-not-mysql.html\n> > > >\n> > > > Moments after forwarding the link to Ben's piece on why\n> > > > MySQL sucks to this list, he e-mailed me the above note.\n> > > >\n> > > > Sorry for any inconvenience...\n> > >\n> > > I am adding this to the FAQ.\n> > >\n> > > --\n> > > Bruce Momjian | http://www.op.net/~candle\n> > > [email protected] | (610) 853-3000\n> > > + If your life is a hard drive, | 830 Blythe Avenue\n> > > + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n> > >\n> > \n> \n> Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy\n> Systems Administrator @ hub.org \n> primary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n> \n> \n> \n\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Wed, 3 May 2000 05:30:32 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Corruption (Was: Re: Why Not MySQL?)" }, { "msg_contents": "On Wed, 3 May 2000, Vince Vielhaber wrote:\n\n> On Tue, 2 May 2000, The Hermit Hacker wrote:\n> \n> > \n> > As Don asks, what happened with the v7.0 trials you were doing? Corrupted\n> > indices, I've seen occasionally in older versions, but I can't recall ever\n> > seeing corrupt system tables ...\n> > \n> > I don't have a GUI browser right, so searching the archives is kinda tough\n> > for me :( Can you refresh my memory for me? There has to be something\n> > logical to this, as to what the cause for the corruption is :(\n> > \n> > >From Don's comment, I take it you are using FreeBSD? Version? Stability\n> > of the machine? Never crashes?\n> > \n> > Version of PostgreSQL? Compile/configure options? Do you have any core\n> > files in your data/base/* hierarchy that would be the result of a backend\n> > crashing? \n> > \n> > I know you are looking at alternatives, but I'm terrible at letting go of\n> > problems :(\n> \n> His description of table corruption and the system running slower and\n> slower sounds like a disk going bad. I've seen it hundreds of times\n> on news machines. Constant retries while trying to write to the disk\n> will give slowdowns. Having data on a spot of the disk that's unreliable\n> will certainly cause data integrity problems. \n\nThat was one thing I was thinking ... the other was the possibility that\nhe's mount'd async and his machine is rebooting ... *or* he has memory\nproblems causing the shared memory to corrupt, dump the postmaster process\nwhich is corrupting his tables ...\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 3 May 2000 09:30:07 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Corruption (Was: Re: Why Not MySQL?)" }, { "msg_contents": "Thomas Lockhart <[email protected]> el d�a Wed, 03 May 2000 \n04:12:37 +0000, escribi�:\n\n>> > If I can't get my questions answered about case sensitivity issues here\n>> > (no help so far) I will most likely to use it myself.\n>\n>My recollection is that it involved needing non-standard\n>case-insensitive LIKE comparisons to get transparent behavior with an\n>existing M$ Access app. So far, we were too polite to ask why one is\n>working so hard to maintain compatibility with a non-standard\n>interface, rather than writing the app to be portable. But I'll ask\n>now. Tim?\n\nif tim want a LIKE to be done case-insensitive, why not doing:\n\nselect foo from table1 where upper(foo) like \"%BAR%\" ??\n\nsergio\n\n", "msg_date": "Wed, 3 May 2000 10:15:50 -0300", "msg_from": "\"Sergio A. Kessler\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "Hi Don, thanks for your reply...\n\n> First, have you been having the same problems with PG 7.0? I recall that\n> you had it up on a test system but nothing more.\n\nNo, I was afraid to run 7.0 beta on the production server. I do have it on\nmy development server however and haven't had any problems with it (of\ncourse the devel server is only used by me, the production server is used by\nabout 600 people)...\n\n > It's a pity that you've reached this point, because PG is so much better\n> than it was 18 months ago (and before, of course, I mention that timeframe\n> because that's roughly when I first investigated its suitability for\n> the web toolkit project) and the trajectory is definitely in the right\n> direction.\n\nWell, we've started to look into it. My boss is worried about the stability\nand speed of Postgres in the long run, personally I love PG, I would like to\nstay with it until at least 7.1, if the problems still continue then maybe\nlook elsewhere.\n\n> It's also a loss to the development effort, as people with bugs in many\n> ways are more useful than people who have no problems (though of course\n> having no bugs for users to stumble across is the best situation!)\n> Still, I understand the need to solve your problems today, not tomorrow.\n\n\n> Interbase is a possible solution. They have a pretty good reputation,\n> and their \"super server\" (threaded with connections sharing a buffer\n> cache) should scale well. My rough estimate is that they're at about\n> the place PG will be when 7.1 comes out. I don't know if they support\n> FreeBSD, though. Any reason you can't just put up a box with Linux?\n\nOoooo. Mitch hates Linux. It's a long, boring story but lets just say that\nLinux and I use to be friends, now we're mortal enemies. :-)\n\n-Mitch Vincent\n\n\n\n\n\n", "msg_date": "Wed, 3 May 2000 10:18:36 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "> As Don asks, what happened with the v7.0 trials you were doing? Corrupted\n> indices, I've seen occasionally in older versions, but I can't recall ever\n> seeing corrupt system tables ...\n\nI couldn't run the 7.0 beta on our production server. It was forbidden from\n\"higher up\"..\n\n> I don't have a GUI browser right, so searching the archives is kinda tough\n> for me :( Can you refresh my memory for me? There has to be something\n> logical to this, as to what the cause for the corruption is :(\n\nOk, the latest thing was \"cannot find attribute 15 of relation pg_am\" -- I\ngot that when I tried to do an query.\n\n > >From Don's comment, I take it you are using FreeBSD? Version?\nStability\n> of the machine? Never crashes?\n\nFreeBSD 4.0-R\n\nThe machine is brand new (we built it because we thought it was a hardware\nproblem before)..\n\nUltra 160 SCSI Drives, 512 megs of ECC RAM, PIII 500 processor (soon to be\nupgraded).\n\n> Version of PostgreSQL? Compile/configure options? Do you have any core\n> files in your data/base/* hierarchy that would be the result of a backend\n> crashing?\n\nPG 6.5.3, no core files (this latest time at least, in the past there have\nbeen).\n\nAs far as configure options, nothing, just the default configuration...\n\n> I know you are looking at alternatives, but I'm terrible at letting go of\n> problems :(\n\nMe too, that's why I've stayed with PG for 6 monthes with these problems..\n\nI wish I had more to tell you now, however I had to restore the data from a\nbackup.\n\n Thanks!!\n\n-Mitch\n\n", "msg_date": "Wed, 3 May 2000 10:27:50 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Corruption (Was: Re: Why Not MySQL?)" }, { "msg_contents": "> > We use PostgreSQL for a fairly large application I wrote, the database\nis\n> > still pretty small, it carries info on about 25-30,000 people and about\n> > 5,000 jobs. Recently we've had huge trouble with PostgreSQL -- it seems\nthat\n> > every month I stump someone with the obscure things that happen to our\ndata\n> > :-)\n>\n> What version are you using ?\n\n6.5.3 :-)\n\n> > >From corrupted indexes to corrupted system tables, it's almost always\n> > unrecoverable. Luckily I always have a backup to restore from and the\nworld\n> > goes on... We've only recently started to notice that the backend is\nslowing\n> > down. It seems that with every additional applicant added it get\n> > exponentially slower... So, sadly I have to go find another backend for\nthis\n> > application -- a commercial one too so we can get \"commercial support\"\n> > (yuck)..\n>\n> Could you be a little more specific on your performance issues ?\n\nWell, I'm just noticing that simple select queries are taking 3-5 seconds -\non a table with 63 fields, 10000ish rows of data. The ID fields are\nindexed, as well as several always-searched varchar() fields.\n\nHere are some typical queries my application might generate. Please, let me\nknow if you see anything that can be improved!\n\nselect * from applicants as a where a.created::date = '05-01-2000' and\na.firstname ~* '^mitch' limit 10 offset 0\n\nselect * from applicants as a,applicants_states as s where a.firstname ~*\n'^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10 offset 0\n\n.... There are 63 fields in the 'applicants' table, all of which are\nsearchable. Would it be a good or bad thing to index all fields that are\nsearchable?\n\n> The usual way to deal wih them is tuning your db structure and/or\n> queries or\n> setting backend options to use more memory for stuff or other such\n> things.\n\nI'd love some pointers! This machine has lots-n-lots of memory. I'd love to\nmake postgre use more than normal if it would get me better speed!\n\n> If there is something wrong with the structure or queries, then a\n> database\n> switch will help you very little, unless your front-end tool has some\n> special\n> support for _some_ databases and not for others.\n\nPHP/C is what I use to access PostgreSQL.\n\n> > So, could you guys suggest some other backends I might look into?\n>\n> The usual - Oracle, Interbase, Informix, DB2, Sybase, Solid\n>\n> The website is usually obtained by putting www inf front and com at the\n> end ;)\n>\n> And let us know of your results.\n>\n> > I know\n> > it's an odd place for me to ask but the flat truth is that I think *I*\nam to\n> > blame for my Postgres troubles and even taking all of the problems into\n> > account I think PG is the best damn free RDBMS out there. It's\nfunctionality\n> > is superior to everyone else's, it's developers are no less than amazing\nand\n> > well -- I trust you guys to give me some honest opinions.. The\nfunctionality\n> > I need is basically what PG has.. Transactions are a must as well as\nsome\n> > sort of sequence -- stability over performance but performance is very\n> > important too. It also needs to run native on FreeBSD..\n> >\n> > Oracle is out as we use FreeBSD and someone out there decided that they\n> > wouldn't support FreeBSD (in the license as well as in the code!)..\n>\n> Is FreeBSD a religious issue there or can it be negotiated ?\n\nNot religious, though I love that OS like I love my right arm.. I am stuck\nwith x86 hardware -- that's pretty much it (and eliminates Solaris and\nseveral other as a possible OS I suppose)..\n\nTHANKS!!\n\n-Mitch Vincent\n\n\n\n", "msg_date": "Wed, 3 May 2000 10:39:36 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "> His description of table corruption and the system running slower and\n> slower sounds like a disk going bad. I've seen it hundreds of times\n> on news machines. Constant retries while trying to write to the disk\n> will give slowdowns. Having data on a spot of the disk that's unreliable\n> will certainly cause data integrity problems.\n>\n> Mitch, have you thoroughly checked the hardware?\n\nChecked and replaced twice. We're using Ultra 160 SCSI drives now so the\nspeed there isn't a problem I hope. :-)\n\n\n\n\n", "msg_date": "Wed, 3 May 2000 10:44:28 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Corruption (Was: Re: Why Not MySQL?)" }, { "msg_contents": "On Wed, 3 May 2000, Mitch Vincent wrote:\n\n> Hi Don, thanks for your reply...\n> \n> > First, have you been having the same problems with PG 7.0? I recall that\n> > you had it up on a test system but nothing more.\n> \n> No, I was afraid to run 7.0 beta on the production server. I do have it on\n> my development server however and haven't had any problems with it (of\n> course the devel server is only used by me, the production server is used by\n> about 600 people)...\n\nOkay, its no longer beta :) run it, run it :)\n\nMy experience so far is that it was basically a 'plug-n-play' sort of\nthing ... dump your database, upgrade and reload ... the only problem I\nhad was one script that I did something like:\n\nSELECT field as field\n\nwithout realizing it, and v7.0 won't allow that (field == field) ... other\nthen that, *much* more stable, and appears faster then the old ...\n\n> Ooooo. Mitch hates Linux. It's a long, boring story but lets just say that\n> Linux and I use to be friends, now we're mortal enemies. :-)\n\nI like you :)\n\n\n", "msg_date": "Wed, 3 May 2000 11:44:42 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "Mitch Vincent wrote:\n> \n> > As Don asks, what happened with the v7.0 trials you were doing? Corrupted\n> > indices, I've seen occasionally in older versions, but I can't recall ever\n> > seeing corrupt system tables ...\n> \n> I couldn't run the 7.0 beta on our production server. It was forbidden from\n> \"higher up\"..\n\nHmmm. I wonder what would be the reaction if you showed your \"higher ups\"\nthe list of bug-fixes between your release and 7.0. It is a *very long*\nlist.\n\nI loathe unplanned/forced upgrades, especially when due to reliability\nproblems. I was put in that position with pg 6.5.2 problems. But I have\nbeen quite pleased with 7.0 so far.\n\nRegards,\nEd Loehr\n", "msg_date": "Wed, 03 May 2000 09:46:29 -0500", "msg_from": "Ed Loehr <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Corruption (Was: Re: Why Not MySQL?)" }, { "msg_contents": "On Wed, 3 May 2000, Mitch Vincent wrote:\n\n> > I don't have a GUI browser right, so searching the archives is kinda tough\n> > for me :( Can you refresh my memory for me? There has to be something\n> > logical to this, as to what the cause for the corruption is :(\n> \n> Ok, the latest thing was \"cannot find attribute 15 of relation pg_am\" -- I\n> got that when I tried to do an query.\n\nSomeone recently posted similar, and I swore he answered himself with a\n'vacuuming fixed the problem' ... but I could be mis-quoting ...\n\n> > Version of PostgreSQL? Compile/configure options? Do you have any core\n> > files in your data/base/* hierarchy that would be the result of a backend\n> > crashing?\n> \n> PG 6.5.3, no core files (this latest time at least, in the past there have\n> been).\n> \n> As far as configure options, nothing, just the default configuration...\n\nOkay, with v7.0, I'd recommend adding --enable-debug, so that if a core\ndoes creep in, we can analyze it ...\n\nMy first and foremost recommendation is to upgrade to v7.0 first ... take\nyour test machine and make sure you have no problem with the dump/reload,\nbut v7.0 is, once more, leaps and bounds ahead of v6.5.3 ... no guarantees\nit will make a difference, but at least it gets you into a release that\nwe're going to be focusing on debugging intensely over the next little\nwhile ...\n\n", "msg_date": "Wed, 3 May 2000 11:48:03 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Corruption (Was: Re: Why Not MySQL?)" }, { "msg_contents": "\"Mitch Vincent\" <[email protected]> writes:\n>> First, have you been having the same problems with PG 7.0? I recall that\n>> you had it up on a test system but nothing more.\n\n> No, I was afraid to run 7.0 beta on the production server. I do have it on\n> my development server however and haven't had any problems with it (of\n> course the devel server is only used by me, the production server is used by\n> about 600 people)...\n\nFWIW, we've fixed a huge number of bugs since 6.5.*. Even the beta\nversions of 7.0 are more stable than any prior release IMHO (and we've\nseen no beta test reports that would contradict that). I'd really like\nto see you try 7.0 before walking away...\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 11:21:47 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "Oh, I'm downloading it to the development server as I type this..\n\nI didn't know RC3 (virtually the release) was out. I plan on starting to use\nit today if everything works on the development server.\n\n- Mitch\n\n----- Original Message -----\nFrom: Tom Lane <[email protected]>\nTo: Mitch Vincent <[email protected]>\nCc: <[email protected]>; Don Baccus <[email protected]>\nSent: Wednesday, May 03, 2000 11:21 AM\nSubject: Re: [HACKERS] Why Not MySQL?\n\n\n> \"Mitch Vincent\" <[email protected]> writes:\n> >> First, have you been having the same problems with PG 7.0? I recall\nthat\n> >> you had it up on a test system but nothing more.\n>\n> > No, I was afraid to run 7.0 beta on the production server. I do have it\non\n> > my development server however and haven't had any problems with it (of\n> > course the devel server is only used by me, the production server is\nused by\n> > about 600 people)...\n>\n> FWIW, we've fixed a huge number of bugs since 6.5.*. Even the beta\n> versions of 7.0 are more stable than any prior release IMHO (and we've\n> seen no beta test reports that would contradict that). I'd really like\n> to see you try 7.0 before walking away...\n>\n> regards, tom lane\n>\n\n", "msg_date": "Wed, 3 May 2000 11:25:42 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "\"Mitch Vincent\" <[email protected]> writes:\n>> Could you be a little more specific on your performance issues ?\n\n> Well, I'm just noticing that simple select queries are taking 3-5 seconds -\n> on a table with 63 fields, 10000ish rows of data. The ID fields are\n> indexed, as well as several always-searched varchar() fields.\n\nHmm. What does EXPLAIN show for the query plan? You might also try\nturning on execution stats (run psql with PGOPTIONS=\"-d2 -s\" for\nstarters) to see what getrusage() can tell. The results will be in the\npostmaster log and might look like this:\n\nStartTransactionCommand\nquery: SELECT usename, relname, relkind, relhasrules FROM pg_class, pg_user WHERE usesysid = relowner and ( relkind = 'r' OR relkind = 'i' OR relkind = 'S') and relname !~ '^pg_' and (relkind != 'i' OR relname !~ '^xinx') ORDER BY relname \nProcessQuery\n! system usage stats:\n!\t0.083256 elapsed 0.040000 user 0.000000 system sec\n!\t[0.080000 user 0.020000 sys total]\n!\t12/1 [46/11] filesystem blocks in/out\n!\t0/0 [1/2] page faults/reclaims, 0 [0] swaps\n!\t0 [0] signals rcvd, 0/0 [2/2] messages rcvd/sent\n!\t8/5 [29/10] voluntary/involuntary context switches\n! postgres usage stats:\n!\tShared blocks: 18 read, 0 written, buffer hit rate = 94.29%\n!\tLocal blocks: 0 read, 0 written, buffer hit rate = 0.00%\n!\tDirect blocks: 0 read, 0 written\nCommitTransactionCommand\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 11:28:51 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "On Wed, 3 May 2000, Mitch Vincent wrote:\n\n> Here are some typical queries my application might generate. Please, let me\n> know if you see anything that can be improved!\n\nFirst comment ... Tom Lane always jumps on me on this ... if you are going\nto send a QUERY to get recommendations on, send in an EXPLAIN on that\nquery also, so that we can see what the backend 'thinks\" its going to do\n...\n\n> select * from applicants as a where a.created::date = '05-01-2000' and\n> a.firstname ~* '^mitch' limit 10 offset 0\n\nFirst comment, that Tom can clarify in case I'm wrong ... when I ran\nUDMSearch under v6.5.3, there was a problem where a LIKE query was causing\na query to take forever to complete ... Tom, at the time, got me to change\nthe query so that instead of:\n\nurl LIKE '%s'\n\nit was:\n\n(url || '') LIKE '%s'\n\nNow, this was in an earlier RC of v7.0 that I had to do this, and Tom made\nsome changes to the following one to 'fix the problem', but my performance\nwent from several *minutes* to several *seconds* of time to complete the\nexact same query ...\n\n> > The usual way to deal wih them is tuning your db structure and/or\n> > queries or\n> > setting backend options to use more memory for stuff or other such\n> > things.\n> \n> I'd love some pointers! This machine has lots-n-lots of memory. I'd love to\n> make postgre use more than normal if it would get me better speed!\n\non my machine (FreeBSD 4.0-STABLE), I'm currently running with a kernel\nof:\n\noptions SYSVSHM\noptions SHMMAXPGS=262144\noptions SHMSEG=32\n\noptions SYSVSEM\noptions SEMMNI=40\noptions SEMMNS=240\noptions SEMMNU=120\noptions SEMMAP=120\n\noptions SYSVMSG\n\nand a -B set to 4096 and -o ' -S 16384 ' ... the -B deals with teh amoun\ntof shared memory, the -S I'm using only affects stuff like ORDER BY and\nGROUP BY (allocates up to how much RAM to use on a sort before going to\ndisk ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 3 May 2000 12:29:31 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "\nOkay, single or dual processor machine? I'm running Dual myself, and for\nany largish DB, I would highly recommend that regardless of OS ... at\nleast if a query starts to hog CPU, you have a second one to use ...\n\nOn Wed, 3 May 2000, Mitch Vincent wrote:\n\n> > > We use PostgreSQL for a fairly large application I wrote, the database\n> is\n> > > still pretty small, it carries info on about 25-30,000 people and about\n> > > 5,000 jobs. Recently we've had huge trouble with PostgreSQL -- it seems\n> that\n> > > every month I stump someone with the obscure things that happen to our\n> data\n> > > :-)\n> >\n> > What version are you using ?\n> \n> 6.5.3 :-)\n> \n> > > >From corrupted indexes to corrupted system tables, it's almost always\n> > > unrecoverable. Luckily I always have a backup to restore from and the\n> world\n> > > goes on... We've only recently started to notice that the backend is\n> slowing\n> > > down. It seems that with every additional applicant added it get\n> > > exponentially slower... So, sadly I have to go find another backend for\n> this\n> > > application -- a commercial one too so we can get \"commercial support\"\n> > > (yuck)..\n> >\n> > Could you be a little more specific on your performance issues ?\n> \n> Well, I'm just noticing that simple select queries are taking 3-5 seconds -\n> on a table with 63 fields, 10000ish rows of data. The ID fields are\n> indexed, as well as several always-searched varchar() fields.\n> \n> Here are some typical queries my application might generate. Please, let me\n> know if you see anything that can be improved!\n> \n> select * from applicants as a where a.created::date = '05-01-2000' and\n> a.firstname ~* '^mitch' limit 10 offset 0\n> \n> select * from applicants as a,applicants_states as s where a.firstname ~*\n> '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10 offset 0\n> \n> .... There are 63 fields in the 'applicants' table, all of which are\n> searchable. Would it be a good or bad thing to index all fields that are\n> searchable?\n> \n> > The usual way to deal wih them is tuning your db structure and/or\n> > queries or\n> > setting backend options to use more memory for stuff or other such\n> > things.\n> \n> I'd love some pointers! This machine has lots-n-lots of memory. I'd love to\n> make postgre use more than normal if it would get me better speed!\n> \n> > If there is something wrong with the structure or queries, then a\n> > database\n> > switch will help you very little, unless your front-end tool has some\n> > special\n> > support for _some_ databases and not for others.\n> \n> PHP/C is what I use to access PostgreSQL.\n> \n> > > So, could you guys suggest some other backends I might look into?\n> >\n> > The usual - Oracle, Interbase, Informix, DB2, Sybase, Solid\n> >\n> > The website is usually obtained by putting www inf front and com at the\n> > end ;)\n> >\n> > And let us know of your results.\n> >\n> > > I know\n> > > it's an odd place for me to ask but the flat truth is that I think *I*\n> am to\n> > > blame for my Postgres troubles and even taking all of the problems into\n> > > account I think PG is the best damn free RDBMS out there. It's\n> functionality\n> > > is superior to everyone else's, it's developers are no less than amazing\n> and\n> > > well -- I trust you guys to give me some honest opinions.. The\n> functionality\n> > > I need is basically what PG has.. Transactions are a must as well as\n> some\n> > > sort of sequence -- stability over performance but performance is very\n> > > important too. It also needs to run native on FreeBSD..\n> > >\n> > > Oracle is out as we use FreeBSD and someone out there decided that they\n> > > wouldn't support FreeBSD (in the license as well as in the code!)..\n> >\n> > Is FreeBSD a religious issue there or can it be negotiated ?\n> \n> Not religious, though I love that OS like I love my right arm.. I am stuck\n> with x86 hardware -- that's pretty much it (and eliminates Solaris and\n> several other as a possible OS I suppose)..\n> \n> THANKS!!\n> \n> -Mitch Vincent\n> \n> \n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 3 May 2000 12:30:25 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "At 10:18 AM 5/3/00 -0400, Mitch Vincent wrote:\n\n>No, I was afraid to run 7.0 beta on the production server. I do have it on\n>my development server however and haven't had any problems with it (of\n>course the devel server is only used by me, the production server is used by\n>about 600 people)...\n\nIt's being run at http://community.aolserver.com and http://openacs.org,\nand it seems to be solid.\n\n...\n\n>> Interbase is a possible solution. They have a pretty good reputation,\n>> and their \"super server\" (threaded with connections sharing a buffer\n>> cache) should scale well. My rough estimate is that they're at about\n>> the place PG will be when 7.1 comes out. I don't know if they support\n>> FreeBSD, though. Any reason you can't just put up a box with Linux?\n\n>Ooooo. Mitch hates Linux. It's a long, boring story but lets just say that\n>Linux and I use to be friends, now we're mortal enemies. :-)\n\nI love it when personal religon gets in the way of technical decision\nmaking! FreeBSD's great, so is Linux. I personally use Linux, but if\na key component of a business of mine would be better served by software\nonly available on FreeBSD, I'd have a server up in a matter of hours.\n\nOh, well...to each their own.\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Wed, 03 May 2000 09:25:03 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "At 11:44 AM 5/3/00 -0300, The Hermit Hacker wrote:\n\n>My experience so far is that it was basically a 'plug-n-play' sort of\n>thing ... dump your database, upgrade and reload ... the only problem I\n>had was one script that I did something like:\n>\n>SELECT field as field\n\nI was able to dump my birdnotes.net database and reload it without change,\nif another datapoint will help your boss's confidence level.\n\n>without realizing it, and v7.0 won't allow that (field == field) ... other\n>then that, *much* more stable, and appears faster then the old ...\n\nMy system had one query in particular that suffered from a poor\nplan (a very bad nested loop), the changes to the optimizer have\nresulted in a much better plan in 7.0 which just flies. I've been\nvery happy with 7.0.\n\nTell your boss we're smarter than he is and switch :)\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Wed, 03 May 2000 09:38:41 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "\"Mitch Vincent\" <[email protected]> writes:\n> Here are some typical queries my application might generate. Please, let me\n> know if you see anything that can be improved!\n\n> select * from applicants as a where a.created::date = '05-01-2000' and\n> a.firstname ~* '^mitch' limit 10 offset 0\n\nNeither of these WHERE clauses can be used with a plain-vanilla index\n(I'm assuming a.created is of time datetime?), so you're getting a\nsimple sequential scan over the whole table --- unless the LIMIT stops\nit sooner. If the table is large then you could get better performance\nby arranging for an indexscan using whichever clause is likely to be\nmore selective (I'd be inclined to go for the date, I think, unless your\ncreation dates come in bunches).\n\nThe trick for the date test would be to have a functional index on\ndate(a.created). I'm not sure how bright 6.5.* is about this, but\nit definitely works in 7.0:\n\ncreate table foo (f1 datetime);\n\n-- a straight index on f1 is no help:\ncreate index foof1 on foo(f1);\nexplain select * from foo where f1::date = '05-01-2000';\nNOTICE: QUERY PLAN:\n\nSeq Scan on foo (cost=0.00..25.00 rows=10 width=8)\n\n-- but an index on date(f1) is:\ncreate index foof1date on foo(date(f1));\nexplain select * from foo where f1::date = '05-01-2000';\nNOTICE: QUERY PLAN:\n\nIndex Scan using foof1date on foo (cost=0.00..8.16 rows=10 width=8)\n\nIf you wanted to make the scan on firstname indexable, you'd need to\nmake an index on lower(firstname) and then change the query to read\n\t... lower(a.firstname) ~ '^mitch'\nor possibly\n\t... lower(a.firstname) ~ lower('^mitch')\nif you don't want to assume the given pattern is lowercase to begin\nwith. (The second example will fail to be indexed under 6.5, but should\nbe just fine in 7.0.) ~* can't use an index under any circumstance,\nbut ~ can if the pattern has a left-anchored fixed prefix.\n\n> select * from applicants as a,applicants_states as s where a.firstname ~*\n> '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10 offset 0\n\nAgain, the ~* clause is not indexable as-is, but the rstate clause\nwould be if you have an index on s.rstate --- however, I imagine that\nit wouldn't be very selective, either, so it might not be worth the\ntrouble. Changing the query to make the firstname part be indexable\ncould be a win. You also need to look at how the join between a and s\nis being done. How big are these tables, anyway?\n\n> .... There are 63 fields in the 'applicants' table, all of which are\n> searchable. Would it be a good or bad thing to index all fields that are\n> searchable?\n\nA lot of indexes will hurt your insert/update/delete times, so I\nwouldn't recommend having a whole bunch of indexes unless searches are\nfar more frequent than changes. What you want is a few well-chosen\nindexes that match the commonly used kinds of WHERE clauses in your\nquery mix.\n\n> I'd love some pointers! This machine has lots-n-lots of memory. I'd love to\n> make postgre use more than normal if it would get me better speed!\n\nIncrease postmaster's -B and -S settings ...\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 13:31:52 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "> The trick for the date test would be to have a functional index on\n> date(a.created). I'm not sure how bright 6.5.* is about this, but\n> it definitely works in 7.0:\n>\n> create table foo (f1 datetime);\n>\n> -- a straight index on f1 is no help:\n> create index foof1 on foo(f1);\n> explain select * from foo where f1::date = '05-01-2000';\n> NOTICE: QUERY PLAN:\n>\n> Seq Scan on foo (cost=0.00..25.00 rows=10 width=8)\n>\n> -- but an index on date(f1) is:\n> create index foof1date on foo(date(f1));\n> explain select * from foo where f1::date = '05-01-2000';\n> NOTICE: QUERY PLAN:\n>\n> Index Scan using foof1date on foo (cost=0.00..8.16 rows=10 width=8)\n\nThanks!.\n\n> > select * from applicants as a,applicants_states as s where a.firstname\n~*\n> > '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10 offset 0\n>\n> Again, the ~* clause is not indexable as-is, but the rstate clause\n> would be if you have an index on s.rstate --- however, I imagine that\n> it wouldn't be very selective, either, so it might not be worth the\n> trouble. Changing the query to make the firstname part be indexable\n> could be a win. You also need to look at how the join between a and s\n> is being done. How big are these tables, anyway?\n\nipa=> select count(app_id) from applicants_states;\n count\n------\n244367\n\nipa=> select count(app_id) from applicants;\ncount\n-----\n 9791\n\n> > .... There are 63 fields in the 'applicants' table, all of which are\n> > searchable. Would it be a good or bad thing to index all fields that are\n> > searchable?\n>\n> A lot of indexes will hurt your insert/update/delete times, so I\n> wouldn't recommend having a whole bunch of indexes unless searches are\n> far more frequent than changes. What you want is a few well-chosen\n> indexes that match the commonly used kinds of WHERE clauses in your\n> query mix.\n\nIt's basically a search engine so yes, searching is FAR more frequently done\nthan inserts/updates/deletes\n\n> Increase postmaster's -B and -S settings ...\n\nI will. Thanks!\n\n-Mitch Vincent\n\n", "msg_date": "Wed, 3 May 2000 13:44:21 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "\"Mitch Vincent\" <[email protected]> writes:\n>> You also need to look at how the join between a and s\n>> is being done. How big are these tables, anyway?\n\n> ipa=> select count(app_id) from applicants_states;\n> count\n> ------\n> 244367\n\n> ipa=> select count(app_id) from applicants;\n> count\n> -----\n> 9791\n\nNow I'm confused --- what's the data model here? I guess each applicants\nrow must match many entries in applicants_states?\n\nAnyway, I suspect you definitely want to avoid a nested-loop join :-).\nIt'd be fairly reasonable for the system to use either hash or merge\njoin, I think. What does EXPLAIN show that the system is actually\ndoing with this query?\n\n>>>> .... There are 63 fields in the 'applicants' table, all of which are\n>>>> searchable. Would it be a good or bad thing to index all fields that are\n>>>> searchable?\n>> \n>> A lot of indexes will hurt your insert/update/delete times, so I\n>> wouldn't recommend having a whole bunch of indexes unless searches are\n>> far more frequent than changes. What you want is a few well-chosen\n>> indexes that match the commonly used kinds of WHERE clauses in your\n>> query mix.\n\n> It's basically a search engine so yes, searching is FAR more frequently done\n> than inserts/updates/deletes\n\nWell, there's still a cost to having a lot of seldom-used indexes,\nbecause the planner has to sit there and consider whether to use each\none for each query. So I'd still recommend looking at your mix of\nqueries and only creating indexes that match reasonably commonly-used\nWHERE clauses.\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 13:53:37 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "> \"Mitch Vincent\" <[email protected]> writes:\n> \n> Well, there's still a cost to having a lot of seldom-used indexes,\n> because the planner has to sit there and consider whether to use each\n> one for each query. So I'd still recommend looking at your mix of\n> queries and only creating indexes that match reasonably commonly-used\n> WHERE clauses.\n> \n\n When doing insert/updates on larger tables (>500.000 entries) these\nindexes are also time consuming !\n\n For our vertical attribute object storage systems we noticed, that\nthe time for insert/updates are the critical part - they behave very\nlinear in our test suite and they seem to be the limiting factor in\nour system.\n\n\n Marten\n\n\n", "msg_date": "Wed, 3 May 2000 19:57:30 +0200 (CEST)", "msg_from": "Marten Feldtmann <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "> > ipa=> select count(app_id) from applicants_states;\n> > count\n> > ------\n> > 244367\n>\n> > ipa=> select count(app_id) from applicants;\n> > count\n> > -----\n> > 9791\n>\n> Now I'm confused --- what's the data model here? I guess each applicants\n> row must match many entries in applicants_states?\n\nWell, that's one possible search a person could do.\n\napplicants is the 63 field table that hold general info about the person.\n\napplicants_states is a table having only two fields --> app_id int4, rstate\nvarchar(2) -- this holds all the state abbreviations of the states that an\napplicant will relocate too. It was either break it out into a different\ntable or make a ver large varchar() field in the applicant table that would\nmost of the time be totally blank but would have to be able to have every\nstate abbreviation in there, including a delimiter (comma or something)\nbetween each one.. We brokw it out into another table so each applicant can\nhave virtually unlimited number of states (or other countries) in the\ndatabase.\n\nSo for each applicant there could be 53 records in the applicants_states\ntable.. (there are 53 different abbreviations that are valid in this\napplication)..\n\nClear as mud? :-)\n\nLooking back I think that it would have almost been better to make a 150-200\ncharacter varchar field -- perhaps not though..\n\n> Anyway, I suspect you definitely want to avoid a nested-loop join :-).\n\n*cough cough cough* I use to have a subselect there -- in fact you smacked\nme around and told me to change it!\n\n> It'd be fairly reasonable for the system to use either hash or merge\n> join, I think. What does EXPLAIN show that the system is actually\n> doing with this query?\n\n6.5.3 :\n\nipa=> explain select * from applicants as a,applicants_states as s where\na.firstname ~*\nipa-> '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10 offset 0;\nNOTICE: QUERY PLAN:\n\nNested Loop (cost=1693.76 rows=6 width=615)\n -> Seq Scan on applicants a (cost=1554.71 rows=50 width=599)\n -> Index Scan using applicants_states_app_id on applicants_states s\n(cost=2.78 rows=1023 width=16)\n\n7.0RC3 (with the exact same data) :\n\nipa=# explain select * from applicants as a,applicants_states as s where\na.firstname ~*\nipa-# '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10 offset 0;\nNOTICE: QUERY PLAN:\n\nMerge Join (cost=0.00..29675.86 rows=2397 width=615)\n -> Index Scan using applicants_states_app_id on applicants_states s\n(cost=0.00..23062.15 rows=2445 width=16)\n -> Index Scan using applicants_app_id on applicants a\n(cost=0.00..6581.91 rows=98 width=599)\n\nNOTICE: QUERY PLAN:\n\nMerge Join (cost=0.00..29675.86 rows=2397 width=615)\n -> Index Scan using applicants_states_app_id on applicants_states s\n(cost=0.00..23062.15 rows=2445 width=16)\n -> Index Scan using applicants_app_id on applicants a\n(cost=0.00..6581.91 rows=98 width=599)\n\nI did get two errors importing data from the 6.5.3 database into the 7.0\ndatabase :\n\nERROR: DefineIndex: opclass \"date_ops\" does not accept datatype \"timestamp\"\nERROR: DefineIndex: opclass \"date_ops\" does not accept datatype \"timestamp\"\n\nAnd I have several fields of type 'datetime' in 6.5.3 which seem to get\ntranslated to 'timestamp' in 7.0 -- then I try to index them using\ndate_ops..\n\n\n-Mitch\n\n\n\n\n", "msg_date": "Wed, 3 May 2000 14:34:14 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "\"Mitch Vincent\" <[email protected]> writes:\n> applicants_states is a table having only two fields --> app_id int4, rstate\n> varchar(2) -- this holds all the state abbreviations of the states that an\n> applicant will relocate too.\n\nAh, got it. If we had better search capabilities on arrays, you could\nhave stored this within the applicants table as an array of char(2) ...\nbut as is, I suspect you did the right thing to make it a second table.\n\n\n>> It'd be fairly reasonable for the system to use either hash or merge\n>> join, I think. What does EXPLAIN show that the system is actually\n>> doing with this query?\n\n> 6.5.3 : [ nested loop ]\n> 7.0RC3 (with the exact same data) : [ merge join ]\n\nSo, may I have the envelope please? What's the timings?\n\n\n> I did get two errors importing data from the 6.5.3 database into the 7.0\n> database :\n\n> ERROR: DefineIndex: opclass \"date_ops\" does not accept datatype \"timestamp\"\n> ERROR: DefineIndex: opclass \"date_ops\" does not accept datatype \"timestamp\"\n\n> And I have several fields of type 'datetime' in 6.5.3 which seem to get\n> translated to 'timestamp' in 7.0 -- then I try to index them using\n> date_ops..\n\nOh, that's interesting. I doubt that date_ops will work very well on\ntimestamp data (or on its predecessor datetime). But 7.0 is the first\nversion that actually checks whether your requested index operators are\ncompatible with the column datatype --- previous versions would blindly\ndo what you told them to, and very possibly coredump depending on what\nthe datatypes in question where. I wonder if that mistake was causing\nsome of the instability you had with 6.5?\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 14:44:45 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "> > 6.5.3 : [ nested loop ]\n> > 7.0RC3 (with the exact same data) : [ merge join ]\n>\n> So, may I have the envelope please? What's the timings?\n\nEh'? I cut and pasted everything that was printed...\n\nHere it is again, with both the beginning and ending prompts :-)\n\n7.0 :\nipa=# explain select * from applicants as a,applicants_states as s where\na.firstname ~* '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10\noffset 0;\nNOTICE: QUERY PLAN:\n\nHash Join (cost=1355.82..5943.73 rows=17 width=615)\n -> Seq Scan on applicants_states s (cost=0.00..4492.54 rows=2350\nwidth=16)\n -> Hash (cost=1355.54..1355.54 rows=112 width=599)\n -> Seq Scan on applicants a (cost=0.00..1355.54 rows=112\nwidth=599)\n\nEXPLAIN\nipa=#\n\n6.5.3 :\n\nipa=> explain select * from applicants as a,applicants_states as s where\na.firstname ~* '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10\noffset 0;\nNOTICE: QUERY PLAN:\n\nNested Loop (cost=1693.76 rows=6 width=615)\n -> Seq Scan on applicants a (cost=1554.71 rows=50 width=599)\n -> Index Scan using applicants_states_app_id on applicants_states s\n(cost=2.78 rows=1023 width=16)\n\nEXPLAIN\nipa=>\n\n\n> Oh, that's interesting. I doubt that date_ops will work very well on\n> timestamp data (or on its predecessor datetime). But 7.0 is the first\n> version that actually checks whether your requested index operators are\n> compatible with the column datatype --- previous versions would blindly\n> do what you told them to, and very possibly coredump depending on what\n> the datatypes in question where. I wonder if that mistake was causing\n> some of the instability you had with 6.5?\n\nIt's very likely that had to do with the stability problems, I indexed all\nthe datetime fields like that..\n\nI index the datetime fields as you mentioned previously in your email and\nWOW, the speed improvement was crazy. It's damn near instant if you're\nsearching just by date created (as many of my lovely users do!)..\n\n-Mitch\n\n\n", "msg_date": "Wed, 3 May 2000 14:54:11 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "Hmm, something else that I see that might break some code between 6.5.* and\n7.0 (it did mine) is the fact that dates and date times are returned the\nreverse that they use to be.\n\nI make comparisions of the literal string in a few places, it didn't like\n2000-03-03 20:20:02-05 as a date time :-)\n\nNo big deal but just out of curiosity, why the change?\n\n- Mitch\n\n", "msg_date": "Wed, 3 May 2000 15:17:05 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "On Wed, 3 May 2000, Mitch Vincent wrote:\n\n> > > 6.5.3 : [ nested loop ]\n> > > 7.0RC3 (with the exact same data) : [ merge join ]\n> >\n> > So, may I have the envelope please? What's the timings?\n> \n> Eh'? I cut and pasted everything that was printed...\n\nExplain tells how the system will do things ... if you run it without the\nExPLAIn, how long does it take to run? :)\n\n\n", "msg_date": "Wed, 3 May 2000 16:34:30 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "> So, may I have the envelope please? What's the timings?\n\n6.5.3:\n\nStartTransactionCommand\nquery: select * from applicants as a,applicants_states as s where\na.firstname ~* '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10\noffset 0;\nProcessQuery\n! system usage stats:\n! 0.436792 elapsed 0.275139 user 0.157033 system sec\n! [0.283135 user 0.173026 sys total]\n! 0/0 [0/0] filesystem blocks in/out\n! 0/149 [0/332] page faults/reclaims, 0 [0] swaps\n! 0 [0] signals rcvd, 0/0 [2/2] messages rcvd/sent\n! 0/8 [2/9] voluntary/involuntary context switches\n! postgres usage stats:\n! Shared blocks: 1403 read, 0 written, buffer hit rate\n= 51.22%\n! Local blocks: 0 read, 0 written, buffer hit rate\n= 0.00%\n! Direct blocks: 0 read, 0 written\nCommitTransactionCommand\nproc_exit(0) [#0]\nshmem_exit(0) [#0]\nexit(0)\n\n\n______________________________________________________________________\n\n7.0 :\n\nStartTransactionCommand\nquery: select * from applicants as a,applicants_states as s where\na.firstname ~*\n'^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10 offset 0;\nProcessQuery\n! system usage stats:\n! 1.461997 elapsed 1.224377 user 0.234618 system sec\n! [1.238219 user 0.255382 sys total]\n! 0/12 [0/12] filesystem blocks in/out\n! 0/60 [0/318] page faults/reclaims, 0 [0] swaps\n! 0 [0] signals rcvd, 0/0 [2/2] messages rcvd/sent\n! 0/22 [1/24] voluntary/involuntary context switches\n! postgres usage stats:\n! Shared blocks: 2713 read, 0 written, buffer hit rate\n= 25.34%\n! Local blocks: 0 read, 0 written, buffer hit rate\n= 0.00%\n! Direct blocks: 0 read, 0 written\nCommitTransactionCommand\nproc_exit(0)\nshmem_exit(0)\nexit(0)\n/usr/local/pgsql/bin/postmaster: reaping dead processes...\n/usr/local/pgsql/bin/postmaster: CleanupProc: pid 60606 exited with status 0\n\n\n\nSorry, I didn't get what you wanted at first. I'm down to my last brain cell\ntoday.\n\n\n\n-Mitch\n\n", "msg_date": "Wed, 3 May 2000 16:29:56 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "\nMitch, one question ... what is the configuration (RAM, CPU, etc) of the\nv6.5.3 machine vs v7.0 machine? Also, how is your postmaster started\nup? What options?\n\nOn Wed, 3 May 2000, Mitch Vincent wrote:\n\n> > So, may I have the envelope please? What's the timings?\n> \n> 6.5.3:\n> \n> StartTransactionCommand\n> query: select * from applicants as a,applicants_states as s where\n> a.firstname ~* '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10\n> offset 0;\n> ProcessQuery\n> ! system usage stats:\n> ! 0.436792 elapsed 0.275139 user 0.157033 system sec\n> ! [0.283135 user 0.173026 sys total]\n> ! 0/0 [0/0] filesystem blocks in/out\n> ! 0/149 [0/332] page faults/reclaims, 0 [0] swaps\n> ! 0 [0] signals rcvd, 0/0 [2/2] messages rcvd/sent\n> ! 0/8 [2/9] voluntary/involuntary context switches\n> ! postgres usage stats:\n> ! Shared blocks: 1403 read, 0 written, buffer hit rate\n> = 51.22%\n> ! Local blocks: 0 read, 0 written, buffer hit rate\n> = 0.00%\n> ! Direct blocks: 0 read, 0 written\n> CommitTransactionCommand\n> proc_exit(0) [#0]\n> shmem_exit(0) [#0]\n> exit(0)\n> \n> \n> ______________________________________________________________________\n> \n> 7.0 :\n> \n> StartTransactionCommand\n> query: select * from applicants as a,applicants_states as s where\n> a.firstname ~*\n> '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10 offset 0;\n> ProcessQuery\n> ! system usage stats:\n> ! 1.461997 elapsed 1.224377 user 0.234618 system sec\n> ! [1.238219 user 0.255382 sys total]\n> ! 0/12 [0/12] filesystem blocks in/out\n> ! 0/60 [0/318] page faults/reclaims, 0 [0] swaps\n> ! 0 [0] signals rcvd, 0/0 [2/2] messages rcvd/sent\n> ! 0/22 [1/24] voluntary/involuntary context switches\n> ! postgres usage stats:\n> ! Shared blocks: 2713 read, 0 written, buffer hit rate\n> = 25.34%\n> ! Local blocks: 0 read, 0 written, buffer hit rate\n> = 0.00%\n> ! Direct blocks: 0 read, 0 written\n> CommitTransactionCommand\n> proc_exit(0)\n> shmem_exit(0)\n> exit(0)\n> /usr/local/pgsql/bin/postmaster: reaping dead processes...\n> /usr/local/pgsql/bin/postmaster: CleanupProc: pid 60606 exited with status 0\n> \n> \n> \n> Sorry, I didn't get what you wanted at first. I'm down to my last brain cell\n> today.\n> \n> \n> \n> -Mitch\n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 3 May 2000 18:00:49 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "\"Mitch Vincent\" <[email protected]> writes:\n> Hmm, something else that I see that might break some code between 6.5.* and\n> 7.0 (it did mine) is the fact that dates and date times are returned the\n> reverse that they use to be.\n\nISO format to be exact... not just the reverse order, but different layout.\n\nIt's always been possible to break unsuspecting apps by changing the\nDATESTYLE; I think it's good practice for an app to set DATESTYLE for\nitself, if it's dependent on a particular setting.\n\n> No big deal but just out of curiosity, why the change?\n\nISO and Y2K political correctness ;-). If you don't like it, set\nDATESTYLE to the old default ('Postgres' I think). It's also possible\nto change the system-wide default with a suitable postmaster switch,\nbut I forget the details.\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 17:01:38 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "\"Mitch Vincent\" <[email protected]> writes:\n>> So, may I have the envelope please? What's the timings?\n\n> 6.5.3:\n> ! system usage stats:\n> ! 0.436792 elapsed 0.275139 user 0.157033 system sec\n> ! [0.283135 user 0.173026 sys total]\n> ! 0/0 [0/0] filesystem blocks in/out\n> ! 0/149 [0/332] page faults/reclaims, 0 [0] swaps\n> ! 0 [0] signals rcvd, 0/0 [2/2] messages rcvd/sent\n> ! 0/8 [2/9] voluntary/involuntary context switches\n> ! postgres usage stats:\n> ! Shared blocks: 1403 read, 0 written, buffer hit rate\n> = 51.22%\n> ! Local blocks: 0 read, 0 written, buffer hit rate\n> = 0.00%\n> ! Direct blocks: 0 read, 0 written\n\n> 7.0 :\n> ! system usage stats:\n> ! 1.461997 elapsed 1.224377 user 0.234618 system sec\n> ! [1.238219 user 0.255382 sys total]\n> ! 0/12 [0/12] filesystem blocks in/out\n> ! 0/60 [0/318] page faults/reclaims, 0 [0] swaps\n> ! 0 [0] signals rcvd, 0/0 [2/2] messages rcvd/sent\n> ! 0/22 [1/24] voluntary/involuntary context switches\n> ! postgres usage stats:\n> ! Shared blocks: 2713 read, 0 written, buffer hit rate\n> = 25.34%\n> ! Local blocks: 0 read, 0 written, buffer hit rate\n> = 0.00%\n> ! Direct blocks: 0 read, 0 written\n\nWell, drat. Looks like 7.0's query plan is slower :-(. There's\nsomething fishy about the numbers for 6.5.3 though --- how could it have\ndone that query with zero blocks read? Are you sure you are comparing\napples to apples here? I wonder whether the 6.5 system already had the\ntables cached in kernel disk buffers while 7.0 was working from a\nstanding start and had to physically go to the disk. Also, did both\nversions have the same -B and -S settings?\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 18:26:40 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "Mitch Vincent wrote:\n> \n> 7.0 :\n> \n> StartTransactionCommand\n> query: select * from applicants as a,applicants_states as s where\n> a.firstname ~*\n> '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10 offset 0;\n> ProcessQuery\n> ! system usage stats:\n\nWith the numbers of records in the applicants file (and the probable\ndistribution of firstnames) a most efficient query under 7.0 will work\nheaps better if you have that index on lower(a.firstname) and stop using\n~* (i.e. just using ~).\n\nI think this will be especially the case with your '63 fields, ~10,000\nrecords. I'm guessing that a significant portion of those fields are\nTEXT or VARCHAR, so record size will be creeping up. The best way to\nsee/show all of the information on this table is to:\n\tVACUUM VERBOSE ANALYZE applicants;\nrather than to just:\n\tSELECT COUNT(*) FROM applicants;\nbecause you/we will get to see the average record size as well.\n\nAlso, I believe I once read that putting all of the fixed length fields\nat the start of the record will make for faster access, especially when\na scan is being done against those fields. (Can someone confirm this\none? :-)\n\nDo you keep statistics regarding what fields people actually _use_ for\ntheir query matching? If you can construct indexes to support those\nfrequent queries then you will find huge speed improvements. These\nspeed improvements won't degrade as you add more records too (at least\nnot to the same extent). You'll probably also find that people will use\nthose query terms more often once they twig to how much more quickly the\nresults come back to them!\n\nAnother point: 7.0 will much more frequently choose indexes when you use\nthe LIMIT clause, as you do.\n\nCheers,\n\t\t\t\t\tAndrew McMillan.\n-- \n_____________________________________________________________________\n Andrew McMillan, e-mail: [email protected]\nCatalyst IT Ltd, PO Box 10-225, Level 22, 105 The Terrace, Wellington\nMe: +64 (21) 635 694, Fax: +64 (4) 499 5596, Office: +64 (4) 499 2267\n", "msg_date": "Thu, 04 May 2000 09:53:39 +1000", "msg_from": "Andrew McMillan <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "On Wed, 3 May 2000, Mitch Vincent wrote:\n\n> > So, may I have the envelope please? What's the timings?\n> \n> 6.5.3:\n> \n> StartTransactionCommand\n> query: select * from applicants as a,applicants_states as s where\n> a.firstname ~* '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10\n> offset 0;\n> ProcessQuery\n> ! system usage stats:\n> ! 0.436792 elapsed 0.275139 user 0.157033 system sec\n> ! [0.283135 user 0.173026 sys total]\n> ! 0/0 [0/0] filesystem blocks in/out\n> ! 0/149 [0/332] page faults/reclaims, 0 [0] swaps\n> ! 0 [0] signals rcvd, 0/0 [2/2] messages rcvd/sent\n> ! 0/8 [2/9] voluntary/involuntary context switches\n\nHow is this to be read? I'm looking at it, and reading it as:\n\n 0 - voluntary\n 8 - involuntary\n\nBut what about the [2/9]?\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n\n", "msg_date": "Thu, 4 May 2000 02:18:10 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "system usage stats (Was: Re: Why Not MySQL? )" }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n>> ! system usage stats:\n>> ! 0.436792 elapsed 0.275139 user 0.157033 system sec\n>> ! [0.283135 user 0.173026 sys total]\n>> ! 0/0 [0/0] filesystem blocks in/out\n>> ! 0/149 [0/332] page faults/reclaims, 0 [0] swaps\n>> ! 0 [0] signals rcvd, 0/0 [2/2] messages rcvd/sent\n>> ! 0/8 [2/9] voluntary/involuntary context switches\n\n> How is this to be read? I'm looking at it, and reading it as:\n\n> 0 - voluntary\n> 8 - involuntary\n\n> But what about the [2/9]?\n\nI believe the numbers outside brackets are for the particular query\ncycle, and the ones in brackets are total for the process (ie, total\nsince backend start).\n\nI didn't design the printout format ;-) ... not real sure what the\npoint is of printing the total-since-start numbers ...\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 01:24:49 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "On Thu, 4 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> >> ! system usage stats:\n> >> ! 0.436792 elapsed 0.275139 user 0.157033 system sec\n> >> ! [0.283135 user 0.173026 sys total]\n> >> ! 0/0 [0/0] filesystem blocks in/out\n> >> ! 0/149 [0/332] page faults/reclaims, 0 [0] swaps\n> >> ! 0 [0] signals rcvd, 0/0 [2/2] messages rcvd/sent\n> >> ! 0/8 [2/9] voluntary/involuntary context switches\n> \n> > How is this to be read? I'm looking at it, and reading it as:\n> \n> > 0 - voluntary\n> > 8 - involuntary\n> \n> > But what about the [2/9]?\n> \n> I believe the numbers outside brackets are for the particular query\n> cycle, and the ones in brackets are total for the process (ie, total\n> since backend start).\n> \n> I didn't design the printout format ;-) ... not real sure what the\n> point is of printing the total-since-start numbers ...\n\nOkay, that explains that :)\n\nNow, Mitch's results for v7.0 showed something like:\n\n0/12 filesystem blocks in/out\n\nYou intepreted that as 12 reads from the file system ... 'out' I would\nhave interpreted as writes to the file system, which made zero sense\n... do we have our 'in/out's backwards here?\n\nOne thing that would be nice (who wrote these stats?) would be some way to\nbe able to determine a suitable setting for -S from this ... someway to\nknow that an ORDER BY needed to swap to disk because it needed 32Meg when\nonly 16Meg was allocated for it ... would help give an indication where\nperformance could be improved by either just raising -S (in Mitch's case,\nwhere lots of RAM is available) or more RAM should be added ...\n\n\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 02:36:11 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> Now, Mitch's results for v7.0 showed something like:\n> 0/12 filesystem blocks in/out\n> You intepreted that as 12 reads from the file system ... 'out' I would\n> have interpreted as writes to the file system, which made zero sense\n> ... do we have our 'in/out's backwards here?\n\nGood point. Writes from a SELECT are certainly possible --- the SELECT\ncould be writing tuple status-flag updates, if it was the first\ntransaction to verify commit status of tuples created by a prior\ntransaction. But that again raises the issue of whether we've got\na fair comparison. The 6.5 test apparently only saw already-marked-\ncommitted tuples ...\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 01:47:32 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "On Thu, 4 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> > Now, Mitch's results for v7.0 showed something like:\n> > 0/12 filesystem blocks in/out\n> > You intepreted that as 12 reads from the file system ... 'out' I would\n> > have interpreted as writes to the file system, which made zero sense\n> > ... do we have our 'in/out's backwards here?\n> \n> Good point. Writes from a SELECT are certainly possible --- the SELECT\n> could be writing tuple status-flag updates, if it was the first\n> transaction to verify commit status of tuples created by a prior\n> transaction. But that again raises the issue of whether we've got\n> a fair comparison. The 6.5 test apparently only saw already-marked-\n> committed tuples ...\n\nI was hoping that Mitch would have spoken up by now about it, but an email\nI saw from him stated that the v7.0 machine (development) wasn't as\npowerful as the v6.5.3 machine (production) ... that might account for it,\nI just don't know how much different the two machines are ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 02:51:20 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "At 02:36 AM 5/4/00 -0300, The Hermit Hacker wrote:\n\n>One thing that would be nice (who wrote these stats?) would be some way to\n>be able to determine a suitable setting for -S from this ... someway to\n>know that an ORDER BY needed to swap to disk because it needed 32Meg when\n>only 16Meg was allocated for it ... would help give an indication where\n>performance could be improved by either just raising -S (in Mitch's case,\n>where lots of RAM is available) or more RAM should be added ...\n\nIt would also be nice to be able to get at these via SQL, ala Oracle.\nThen toolkits like OpenACS could easily generate administration pages\nthat present the stats nicely to webmasters, including perhaps\nputting up links to help page. If sorting is going to disk,\na link to a short pages dicussing raising -S could be put up.\n\nACS Classic, the Oracle version, has admin pages (without help,\nit points you to a bookshelf of Oracle DBA books instead) which\ndisplay stats, etc and it is very useful.\n\nA lot of folks using toolkits like this will simply customize\nlook and feel of the web pages and at first, at least, won't\nknow much or anything about SQL or Postgres and need all the\nhelp we can give them.\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Thu, 04 May 2000 05:45:07 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": true, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "Ok, the production server is a Celeron 433, 512 MEgs of PC100 ECC RAM, 2 18\nGig Ultra 160 SCSI drives (only running at 80 megs since we dono't have a\n64-bit PCI slot).\n\nThere is a big upgrade planned for this box when the motherboard we're\nwaiting for comes out..\n\nThe development server is a PII450, 128 Megs of RAM and Ultra 2 SCSI\ndrives.. However it's running several other things other than the database\nand webserver so it has a small load.\n\nSorry for not replying sooner, had a small crisis yesterday evening :-)\n\n- Mitch\n\n----- Original Message -----\nFrom: The Hermit Hacker <[email protected]>\nTo: Tom Lane <[email protected]>\nCc: Mitch Vincent <[email protected]>; <[email protected]>\nSent: Thursday, May 04, 2000 1:51 AM\nSubject: Re: system usage stats (Was: Re: [HACKERS] Why Not MySQL? )\n\n\n> On Thu, 4 May 2000, Tom Lane wrote:\n>\n> > The Hermit Hacker <[email protected]> writes:\n> > > Now, Mitch's results for v7.0 showed something like:\n> > > 0/12 filesystem blocks in/out\n> > > You intepreted that as 12 reads from the file system ... 'out' I would\n> > > have interpreted as writes to the file system, which made zero sense\n> > > ... do we have our 'in/out's backwards here?\n> >\n> > Good point. Writes from a SELECT are certainly possible --- the SELECT\n> > could be writing tuple status-flag updates, if it was the first\n> > transaction to verify commit status of tuples created by a prior\n> > transaction. But that again raises the issue of whether we've got\n> > a fair comparison. The 6.5 test apparently only saw already-marked-\n> > committed tuples ...\n>\n> I was hoping that Mitch would have spoken up by now about it, but an email\n> I saw from him stated that the v7.0 machine (development) wasn't as\n> powerful as the v6.5.3 machine (production) ... that might account for it,\n> I just don't know how much different the two machines are ...\n>\n> Marc G. Fournier ICQ#7615664 IRC Nick:\nScrappy\n> Systems Administrator @ hub.org\n> primary: [email protected] secondary:\nscrappy@{freebsd|postgresql}.org\n>\n\n", "msg_date": "Thu, 4 May 2000 09:18:40 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "On Thu, 4 May 2000, Mitch Vincent wrote:\n\n> Ok, the production server is a Celeron 433, 512 MEgs of PC100 ECC RAM, 2 18\n> Gig Ultra 160 SCSI drives (only running at 80 megs since we dono't have a\n> 64-bit PCI slot).\n> \n> There is a big upgrade planned for this box when the motherboard we're\n> waiting for comes out..\n> \n> The development server is a PII450, 128 Megs of RAM and Ultra 2 SCSI\n> drives.. However it's running several other things other than the database\n> and webserver so it has a small load.\n\nWait, correct me if I'm wrong, but the more powerful CPU is in your\ndevelopment server? \n\nMy understanding is that a Celeron is a chop'd up PII ... my first\nrecommendation here is that if you are running a *server*, get rid of that\nCeleron ... from what I've been told about the difference, Celeron is a\ngreat, cheap chip for using in a desktop environment (its what I use at\nhome), but shy away from it in a server environment, as the speed\nreduction of the reduced cache alone will hurt things ...\n\n", "msg_date": "Thu, 4 May 2000 10:33:44 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "> > Ok, the production server is a Celeron 433, 512 MEgs of PC100 ECC RAM, 2\n18\n> > Gig Ultra 160 SCSI drives (only running at 80 megs since we dono't have\na\n> > 64-bit PCI slot).\n> >\n> > There is a big upgrade planned for this box when the motherboard we're\n> > waiting for comes out..\n> >\n> > The development server is a PII450, 128 Megs of RAM and Ultra 2 SCSI\n> > drives.. However it's running several other things other than the\ndatabase\n> > and webserver so it has a small load.\n>\n> Wait, correct me if I'm wrong, but the more powerful CPU is in your\n> development server?\n>\n> My understanding is that a Celeron is a chop'd up PII ... my first\n> recommendation here is that if you are running a *server*, get rid of that\n> Celeron ... from what I've been told about the difference, Celeron is a\n> great, cheap chip for using in a desktop environment (its what I use at\n> home), but shy away from it in a server environment, as the speed\n> reduction of the reduced cache alone will hurt things ...\n\nOoooooooooh you're preaching to the choir. I know, I'm argueing with someone\nabout this as we speak.\n\nA Celeron is basically a PII with 128k of full-speed cache. NOT a server\nprocessor, I know but sadly I can't do much about it at this point.. It's my\nunderstanding that \"we\" want to wait for an AMD board that has a 64-bit PCI\nslot because \"we\" don't like the i840 chipset for some reason \"we\" can't\nunderstand.\n\nAs you can tell, I'm a bit upset about the whole thing..\n\n-Mitch\n\n\n", "msg_date": "Thu, 4 May 2000 09:44:25 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "On Thu, 4 May 2000, Mitch Vincent wrote:\n\n> > > Ok, the production server is a Celeron 433, 512 MEgs of PC100 ECC RAM, 2\n> 18\n> > > Gig Ultra 160 SCSI drives (only running at 80 megs since we dono't have\n> a\n> > > 64-bit PCI slot).\n> > >\n> > > There is a big upgrade planned for this box when the motherboard we're\n> > > waiting for comes out..\n> > >\n> > > The development server is a PII450, 128 Megs of RAM and Ultra 2 SCSI\n> > > drives.. However it's running several other things other than the\n> database\n> > > and webserver so it has a small load.\n> >\n> > Wait, correct me if I'm wrong, but the more powerful CPU is in your\n> > development server?\n> >\n> > My understanding is that a Celeron is a chop'd up PII ... my first\n> > recommendation here is that if you are running a *server*, get rid of that\n> > Celeron ... from what I've been told about the difference, Celeron is a\n> > great, cheap chip for using in a desktop environment (its what I use at\n> > home), but shy away from it in a server environment, as the speed\n> > reduction of the reduced cache alone will hurt things ...\n> \n> Ooooooooooh you're preaching to the choir. I know, I'm argueing with someone\n> about this as we speak.\n> \n> A Celeron is basically a PII with 128k of full-speed cache. NOT a\n> server processor, I know but sadly I can't do much about it at this\n> point.. It's my understanding that \"we\" want to wait for an AMD board\n> that has a 64-bit PCI slot because \"we\" don't like the i840 chipset\n> for some reason \"we\" can't understand.\n\nCan someone out there that understands CPUs help me out here? My\nunderstanding is that Intel vs AMD has benefits depending on\nuse. Unfortunately, I don't recall how it goes ... as a server, Intel is\nfaster, and for graphics processing, AMD is ... or something like that?\n\n\n", "msg_date": "Thu, 4 May 2000 10:54:23 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "At 10:33 AM 5/4/00 -0300, The Hermit Hacker wrote:\n\n>Wait, correct me if I'm wrong, but the more powerful CPU is in your\n>development server? \n>\n>My understanding is that a Celeron is a chop'd up PII ... my first\n>recommendation here is that if you are running a *server*, get rid of that\n>Celeron ... from what I've been told about the difference, Celeron is a\n>great, cheap chip for using in a desktop environment (its what I use at\n>home), but shy away from it in a server environment, as the speed\n>reduction of the reduced cache alone will hurt things ...\n\nCelerons have a smaller L2 cache (128K) than PIIs (512K), but it runs\nfull-speed rather than 1/2 speed like the PII cache. Current models\naren't \"chopped up\" in any sense, they're the same core with a smaller\nbut faster cache.\n\nSo, applications that have a high cache hit rate can actually run faster\non the Celeron.\n\nNew Coppermine PIII's (those that end in E or are > 600 MHz) have\n256K full-speed cache, the Coppermine-based Celeron II's 128K\nfull-speed. Yes, they cut the cache size in half compared to\nPII's and non-E PIII's (Katmai cores) but it's full-speed, which\nturns out to be a win for nearly all applications. Other than\ncache size and FSB/memory bus speed the new Celerons and PIII's\nare identical.\n\nAll Celerons run with 66 MHz FSB and RAM, current Coppermines with\n100 MHz RAM (even those with a 133MHz front-side bus) or spendy\nRDRAM which almost no one is buying.\n\nSo, what's the bottom line? The numbers don't tell us much,\nthough I still think Tom's right that the PG7.0 one is really\nslower. You just can't say if how MUCH slower.\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Thu, 04 May 2000 06:55:44 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": true, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "Well well. Mitch gets his dual PIII board/processors -- I guess I sold the\nidea to the boss-man :-)\n\n\n- Mitch\n\n----- Original Message -----\nFrom: Don Baccus <[email protected]>\nTo: The Hermit Hacker <[email protected]>; Mitch Vincent\n<[email protected]>\nCc: <[email protected]>\nSent: Thursday, May 04, 2000 9:55 AM\nSubject: Re: system usage stats (Was: Re: [HACKERS] Why Not MySQL? )\n\n\n> At 10:33 AM 5/4/00 -0300, The Hermit Hacker wrote:\n>\n> >Wait, correct me if I'm wrong, but the more powerful CPU is in your\n> >development server?\n> >\n> >My understanding is that a Celeron is a chop'd up PII ... my first\n> >recommendation here is that if you are running a *server*, get rid of\nthat\n> >Celeron ... from what I've been told about the difference, Celeron is a\n> >great, cheap chip for using in a desktop environment (its what I use at\n> >home), but shy away from it in a server environment, as the speed\n> >reduction of the reduced cache alone will hurt things ...\n>\n> Celerons have a smaller L2 cache (128K) than PIIs (512K), but it runs\n> full-speed rather than 1/2 speed like the PII cache. Current models\n> aren't \"chopped up\" in any sense, they're the same core with a smaller\n> but faster cache.\n>\n> So, applications that have a high cache hit rate can actually run faster\n> on the Celeron.\n>\n> New Coppermine PIII's (those that end in E or are > 600 MHz) have\n> 256K full-speed cache, the Coppermine-based Celeron II's 128K\n> full-speed. Yes, they cut the cache size in half compared to\n> PII's and non-E PIII's (Katmai cores) but it's full-speed, which\n> turns out to be a win for nearly all applications. Other than\n> cache size and FSB/memory bus speed the new Celerons and PIII's\n> are identical.\n>\n> All Celerons run with 66 MHz FSB and RAM, current Coppermines with\n> 100 MHz RAM (even those with a 133MHz front-side bus) or spendy\n> RDRAM which almost no one is buying.\n>\n> So, what's the bottom line? The numbers don't tell us much,\n> though I still think Tom's right that the PG7.0 one is really\n> slower. You just can't say if how MUCH slower.\n>\n>\n>\n> - Don Baccus, Portland OR <[email protected]>\n> Nature photos, on-line guides, Pacific Northwest\n> Rare Bird Alert Service and other goodies at\n> http://donb.photo.net.\n>\n\n", "msg_date": "Thu, 4 May 2000 10:22:24 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "At 10:54 AM 5/4/00 -0300, The Hermit Hacker wrote:\n\n>Can someone out there that understands CPUs help me out here? My\n>understanding is that Intel vs AMD has benefits depending on\n>use. Unfortunately, I don't recall how it goes ... as a server, Intel is\n>faster, and for graphics processing, AMD is ... or something like that?\n\nFirst, take a look at my earlier post (that I didn't send to the\nlist because it seemed irrelevant) about some basic issues regarding\nthe i840.\n\nFor servers, I think the bottom line at the moment is that the Athlon\nisn't available in SMP, and won't be 'til later this year. And the\nAthlon boards haven't been out long, and they're tricky to make, and\nrequire high quality power supplies. All and all, I'd look closely\nat an Athlon for a personal workstation but not a server at this\npoint. For a low-end server (say, static web pages) an i810 or\ni810E with on-board video is a compact solution that fits\nnicely in 2U rack cases. A Celeron 366 does a great job for this kind\nof application, cheaply (see http://donb.photo.net for an example\nof a C366 at work). Of course, you can only buy faster ones now,\nthey'll do the job even better.\n\nFor a high-end db server, you probably want an SMP board, I'd\nguess. Even if you only put in a single processor, this gives\nthe option of adding a second one if load grows and you've got\nenough RAM, etc. That rules out the Athlon at the moment.\n\nAs far as head-to-head comparisons of current PIII coppermines\nand Athlons...the Athlon has 1/2 or 2/5 speed cache (slower speeds\nat the high end 750 MHz+ I believe), the coppermine full-speed,\non-die cache. But the Athlon has more L1 cache. And the \nAthlon has faster FPP, but more graphics stuff is optimized for\nIntel.\n\nPrice performance wise, the Athlon smokes the coppermines as\nyou can buy a much faster part for the same price. Absolute\nperformance wise, in theory a 1 GHz coppermine beats a 1 GHz\nAthlon for almost anything, but you can't get them unless \nyour name is Michael Dell, etc. For build-your-own types or\nsmall systems integrators they don't really exist.\n\nBy fall, it won't matter. The new generation Intel chips start\nshowing up, Athlon on-die full-speed cache version shows up\nmaking the current part look like a slouch, and new generation\nAMD parts start showing up. We'll all realize our current\ncomputers suck, even though they've got more power than most\nof us can figure out how to use.\n\nAnd ... maybe an Intel solution to the i820/i840 fiasco. We\ncan always hope.\n\n\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Thu, 04 May 2000 07:25:13 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": true, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "> > A Celeron is basically a PII with 128k of full-speed cache. NOT a\n> > server processor, I know but sadly I can't do much about it at this\n> > point.. It's my understanding that \"we\" want to wait for an AMD board\n> > that has a 64-bit PCI slot because \"we\" don't like the i840 chipset\n> > for some reason \"we\" can't understand.\n> Can someone out there that understands CPUs help me out here? My\n> understanding is that Intel vs AMD has benefits depending on\n> use. Unfortunately, I don't recall how it goes ... as a server, Intel is\n> faster, and for graphics processing, AMD is ... or something like that?\n\n From what I've read, the extra cache in the PII/III gives you a 5%\nboost over the Celeron (I'll guess more for some server apps). Intel\nstill sells the Xeon chips, which have a cache twice as big as the\nPII/III, but I'm not sure the clock has kept pace and it was always\noverpriced wrt performance.\n\nI don't remember which way the Intel/AMD thing goes, but most folks\nwon't notice a 5% difference in speed.\n\nNot that anyone asked, but imho the best price/performance x86 machine\nhas always been a dual processor box one or two clock jumps behind the\nfastest available. You get ~80% more performance for ~5% more cost\nthan a uniprocessor at the fastest speed. I haven't looked recently to\nsee if there are now uniprocessor machines at the low end that can\nbeat the price/performance of the dual-processor setup.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Thu, 04 May 2000 14:26:00 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? )" }, { "msg_contents": "On Thu, 4 May 2000, Thomas Lockhart wrote:\n\n> > > A Celeron is basically a PII with 128k of full-speed cache. NOT a\n> > > server processor, I know but sadly I can't do much about it at this\n> > > point.. It's my understanding that \"we\" want to wait for an AMD board\n> > > that has a 64-bit PCI slot because \"we\" don't like the i840 chipset\n> > > for some reason \"we\" can't understand.\n> > Can someone out there that understands CPUs help me out here? My\n> > understanding is that Intel vs AMD has benefits depending on\n> > use. Unfortunately, I don't recall how it goes ... as a server, Intel is\n> > faster, and for graphics processing, AMD is ... or something like that?\n> \n> >From what I've read, the extra cache in the PII/III gives you a 5%\n> boost over the Celeron (I'll guess more for some server apps). Intel\n> still sells the Xeon chips, which have a cache twice as big as the\n> PII/III, but I'm not sure the clock has kept pace and it was always\n> overpriced wrt performance.\n> \n> I don't remember which way the Intel/AMD thing goes, but most folks\n> won't notice a 5% difference in speed.\n> \n> Not that anyone asked, but imho the best price/performance x86 machine\n> has always been a dual processor box one or two clock jumps behind the\n> fastest available. You get ~80% more performance for ~5% more cost\n> than a uniprocessor at the fastest speed. I haven't looked recently to\n> see if there are now uniprocessor machines at the low end that can\n> beat the price/performance of the dual-processor setup.\n\nthis is the sort of thing I've been moving towards as well ... went a\nlittle cheaper this last time with upgrading my home machine and have a\nDual-Celeron ... quite happy with her so far ...\n\n\n", "msg_date": "Thu, 4 May 2000 11:34:53 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Hardware/CPU Thoughts (Was: Re: system usage stats )" }, { "msg_contents": "At 02:26 PM 5/4/00 +0000, Thomas Lockhart wrote:\n\n>From what I've read, the extra cache in the PII/III gives you a 5%\n>boost over the Celeron (I'll guess more for some server apps).\n\nFor a db server the 100Mhz memory bus of the PII/III probably\nwins more than 5% over the 66Mhz memory bus of the Celeron. This\nassumes you're database is reasonably big. Lots of memory transfers\ngoing on...\n\n>Intel\n>still sells the Xeon chips, which have a cache twice as big as the\n>PII/III, but I'm not sure the clock has kept pace and it was always\n>overpriced wrt performance.\n\nKatmai Xeons come with cache size ranging from 512K (the same as a PII/PIII\nKatmai) to 2MB. That cache, though, is FULL SPEED. Gets you about 10%\nover a PII/III Katmai for server-type benchmarks I've seen. But they're\nexpensive.\n\nYou can also go 4-way SMP with them, vs. 2-way with PII/III...\n\nNow the new Coppermines have changed things...the Xeon Cu and PII/III\nCu both have identical 256K full-speed cache. There's not much reason\nto buy the Xeon unless you want 4-way SMP, and Intel recognizes this\napparently because the price is only 10% higher for these new parts.\n\n>Not that anyone asked, but imho the best price/performance x86 machine\n>has always been a dual processor box one or two clock jumps behind the\n>fastest available.\n\nThat's what I did, a dual PII450. I bought them (boxed, fan) for $180\neach when PIII450s were $250 or so and PIII 500Es $299 (I bought one\nof the latter for a home workstation). So it's a PII without the\nlatest matrix instructions for graphics? How many games will I\nrun on my web/db server? :)\n\n>You get ~80% more performance for ~5% more cost\n>than a uniprocessor at the fastest speed. I haven't looked recently to\n>see if there are now uniprocessor machines at the low end that can\n>beat the price/performance of the dual-processor setup.\n\nThe Athlons do, actually ... but I wouldn't trust the mobos for a\nremote server at this point, not until they're proven stable. They're\ntricky to build and finicky about power supplies.\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Thu, 04 May 2000 07:42:16 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": true, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? )" }, { "msg_contents": "Don Baccus <[email protected]> writes:\n> So, what's the bottom line? The numbers don't tell us much,\n> though I still think Tom's right that the PG7.0 one is really\n> slower. You just can't say if how MUCH slower.\n\nActually I was a lot more concerned about disk performance than CPU\nspeed. I notice no one's said anything about the relative speed\nof Mitch's two different disk setups ...\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 11:06:20 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? ) " }, { "msg_contents": "On Thu, May 04, 2000 at 11:06:20AM -0400, Tom Lane wrote:\n> Don Baccus <[email protected]> writes:\n> > So, what's the bottom line? The numbers don't tell us much,\n> > though I still think Tom's right that the PG7.0 one is really\n> > slower. You just can't say if how MUCH slower.\n> \n> Actually I was a lot more concerned about disk performance than CPU\n> speed. I notice no one's said anything about the relative speed\n> of Mitch's two different disk setups ...\n> \n\nMitch wrote:\n> Ok, the production server is a Celeron 433, 512 MEgs of PC100 ECC RAM, 2 18\n> Gig Ultra 160 SCSI drives (only running at 80 megs since we dono't have a\n> 64-bit PCI slot).\n> \n> There is a big upgrade planned for this box when the motherboard we're\n> waiting for comes out..\n> \n> The development server is a PII450, 128 Megs of RAM and Ultra 2 SCSI\n> drives.. However it's running several other things other than the database\n> and webserver so it has a small load.\n> \n\nSo, 6.5.3 is running on Ultra 160 drives, with the controller throttled to\n80 MB/s, and 7.0 is running on Ultra 2 drives, which also has a controller\nmaximum of 80 MB/s. However, the sustained transfer speed of the drives\nthemselves are what should be limiting: if they're all relatively modern\ndrives, 20MB/s is typical, so neither config will max out the controller.\n(2 drives each, right?)\n\nRoss\n-- \nRoss J. Reedstrom, Ph.D., <[email protected]> \nNSBRI Research Scientist/Programmer\nComputer and Information Technology Institute\nRice University, 6100 S. Main St., Houston, TX 77005\n\n", "msg_date": "Thu, 4 May 2000 11:03:31 -0500", "msg_from": "\"Ross J. Reedstrom\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? )" }, { "msg_contents": "At 11:03 AM 5/4/00 -0500, Ross J. Reedstrom wrote:\n\n>So, 6.5.3 is running on Ultra 160 drives, with the controller throttled to\n>80 MB/s, and 7.0 is running on Ultra 2 drives, which also has a controller\n>maximum of 80 MB/s. However, the sustained transfer speed of the drives\n>themselves are what should be limiting: if they're all relatively modern\n>drives, 20MB/s is typical, so neither config will max out the controller.\n>(2 drives each, right?)\n\nNot to mention that seek times make it very difficult to max out \na controller even if theoretically possible with four drives, unless\nyou're striping and doing large transfers or lookaheads, etc.\n\nIf one's got 10K drives and the other 7.2K drives, you'll certainly\nsee a difference in transfer rate and seek time.\n\nSo ... what are the disk configurations?\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Thu, 04 May 2000 10:11:53 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": true, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? )" }, { "msg_contents": "Production 10k, development 7.2k RPM :-)\n\n- Mitch\n\n----- Original Message -----\nFrom: Don Baccus <[email protected]>\nTo: Ross J. Reedstrom <[email protected]>; Tom Lane\n<[email protected]>\nCc: <[email protected]>\nSent: Thursday, May 04, 2000 1:11 PM\nSubject: Re: system usage stats (Was: Re: [HACKERS] Why Not MySQL? )\n\n\n> At 11:03 AM 5/4/00 -0500, Ross J. Reedstrom wrote:\n>\n> >So, 6.5.3 is running on Ultra 160 drives, with the controller throttled\nto\n> >80 MB/s, and 7.0 is running on Ultra 2 drives, which also has a\ncontroller\n> >maximum of 80 MB/s. However, the sustained transfer speed of the drives\n> >themselves are what should be limiting: if they're all relatively modern\n> >drives, 20MB/s is typical, so neither config will max out the controller.\n> >(2 drives each, right?)\n>\n> Not to mention that seek times make it very difficult to max out\n> a controller even if theoretically possible with four drives, unless\n> you're striping and doing large transfers or lookaheads, etc.\n>\n> If one's got 10K drives and the other 7.2K drives, you'll certainly\n> see a difference in transfer rate and seek time.\n>\n> So ... what are the disk configurations?\n>\n>\n>\n> - Don Baccus, Portland OR <[email protected]>\n> Nature photos, on-line guides, Pacific Northwest\n> Rare Bird Alert Service and other goodies at\n> http://donb.photo.net.\n>\n\n", "msg_date": "Thu, 4 May 2000 13:58:09 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: system usage stats (Was: Re: Why Not MySQL? )" }, { "msg_contents": "> Well, drat. Looks like 7.0's query plan is slower :-(. There's\n> something fishy about the numbers for 6.5.3 though --- how could it have\n> done that query with zero blocks read? Are you sure you are comparing\n> apples to apples here? I wonder whether the 6.5 system already had the\n> tables cached in kernel disk buffers while 7.0 was working from a\n> standing start and had to physically go to the disk.\n\nThis is very possible as the 6.5.3 PG is running on the production server\nwhich is constantly being queried.\n\n>Also, did both\n> versions have the same -B and -S settings?\n\nI didn't specify any -B or -S settings so both are using their respective\ndefaults..\n\nThanks!\n\n", "msg_date": "Thu, 4 May 2000 18:41:53 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "On Thu, 4 May 2000, Mitch Vincent wrote:\n\n> > Well, drat. Looks like 7.0's query plan is slower :-(. There's\n> > something fishy about the numbers for 6.5.3 though --- how could it have\n> > done that query with zero blocks read? Are you sure you are comparing\n> > apples to apples here? I wonder whether the 6.5 system already had the\n> > tables cached in kernel disk buffers while 7.0 was working from a\n> > standing start and had to physically go to the disk.\n> \n> This is very possible as the 6.5.3 PG is running on the production server\n> which is constantly being queried.\n> \n> >Also, did both\n> > versions have the same -B and -S settings?\n> \n> I didn't specify any -B or -S settings so both are using their respective\n> defaults..\n\nFor you machine, go with something like '-S <32*1024>' to use 32Meg of RAM\nfor ORDER/GROUP BY ... \n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 21:21:09 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "I was just playing with some of the suggested lower() indexes and ran into a\nbit of trouble, it's no doubt from my lack of understanding but still, I\nwanted to ask..\n\nDo dum :\n\nipa=# create index applicants_firstname on applicants(lower(firstname));\nERROR: DefineIndex: function 'lower(varchar)' does not exist\n\n...that syntax is right, isn't it?\n\nThanks!\n\n- Mitch\n\n----- Original Message -----\nFrom: Tom Lane <[email protected]>\nTo: Mitch Vincent <[email protected]>\nCc: <[email protected]>\nSent: Wednesday, May 03, 2000 1:31 PM\nSubject: Re: [HACKERS] Why Not MySQL?\n\n\n> \"Mitch Vincent\" <[email protected]> writes:\n> > Here are some typical queries my application might generate. Please, let\nme\n> > know if you see anything that can be improved!\n>\n> > select * from applicants as a where a.created::date = '05-01-2000' and\n> > a.firstname ~* '^mitch' limit 10 offset 0\n>\n> Neither of these WHERE clauses can be used with a plain-vanilla index\n> (I'm assuming a.created is of time datetime?), so you're getting a\n> simple sequential scan over the whole table --- unless the LIMIT stops\n> it sooner. If the table is large then you could get better performance\n> by arranging for an indexscan using whichever clause is likely to be\n> more selective (I'd be inclined to go for the date, I think, unless your\n> creation dates come in bunches).\n>\n> The trick for the date test would be to have a functional index on\n> date(a.created). I'm not sure how bright 6.5.* is about this, but\n> it definitely works in 7.0:\n>\n> create table foo (f1 datetime);\n>\n> -- a straight index on f1 is no help:\n> create index foof1 on foo(f1);\n> explain select * from foo where f1::date = '05-01-2000';\n> NOTICE: QUERY PLAN:\n>\n> Seq Scan on foo (cost=0.00..25.00 rows=10 width=8)\n>\n> -- but an index on date(f1) is:\n> create index foof1date on foo(date(f1));\n> explain select * from foo where f1::date = '05-01-2000';\n> NOTICE: QUERY PLAN:\n>\n> Index Scan using foof1date on foo (cost=0.00..8.16 rows=10 width=8)\n>\n> If you wanted to make the scan on firstname indexable, you'd need to\n> make an index on lower(firstname) and then change the query to read\n> ... lower(a.firstname) ~ '^mitch'\n> or possibly\n> ... lower(a.firstname) ~ lower('^mitch')\n> if you don't want to assume the given pattern is lowercase to begin\n> with. (The second example will fail to be indexed under 6.5, but should\n> be just fine in 7.0.) ~* can't use an index under any circumstance,\n> but ~ can if the pattern has a left-anchored fixed prefix.\n>\n> > select * from applicants as a,applicants_states as s where a.firstname\n~*\n> > '^mitch' and s.rstate='AL' and s.app_id=a.app_id limit 10 offset 0\n>\n> Again, the ~* clause is not indexable as-is, but the rstate clause\n> would be if you have an index on s.rstate --- however, I imagine that\n> it wouldn't be very selective, either, so it might not be worth the\n> trouble. Changing the query to make the firstname part be indexable\n> could be a win. You also need to look at how the join between a and s\n> is being done. How big are these tables, anyway?\n>\n> > .... There are 63 fields in the 'applicants' table, all of which are\n> > searchable. Would it be a good or bad thing to index all fields that are\n> > searchable?\n>\n> A lot of indexes will hurt your insert/update/delete times, so I\n> wouldn't recommend having a whole bunch of indexes unless searches are\n> far more frequent than changes. What you want is a few well-chosen\n> indexes that match the commonly used kinds of WHERE clauses in your\n> query mix.\n>\n> > I'd love some pointers! This machine has lots-n-lots of memory. I'd\nlove to\n> > make postgre use more than normal if it would get me better speed!\n>\n> Increase postmaster's -B and -S settings ...\n>\n> regards, tom lane\n>\n\n", "msg_date": "Fri, 5 May 2000 10:01:55 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "\"Mitch Vincent\" <[email protected]> writes:\n> ipa=# create index applicants_firstname on applicants(lower(firstname));\n> ERROR: DefineIndex: function 'lower(varchar)' does not exist\n\n> ...that syntax is right, isn't it?\n\nHmm, that's annoying. I guess you are going to have to make that field\nbe of type text.\n\nActually, since text and varchar look the same under the hood, the\nexisting lower() code would work just fine on varchar. One fix for this\nwould be to add a pg_proc entry for lower(varchar), which you could do\nby hand if you wanted:\n\nregression=# create index f1lower on f1v (lower(f1));\nERROR: DefineIndex: function 'lower(varchar)' does not exist\n\nregression=# create function lower(varchar) returns text as 'lower'\nregression-# language 'internal' with (iscachable);\nCREATE\n\nregression=# select * from pg_proc where proname = 'lower';\n proname | proowner | prolang | proisinh | proistrusted | proiscachable | pronargs | proretset | prorettype | proargtypes | probyte_pct | properbyte_cpu | propercall_cpu | prooutin_ratio | prosrc | probin\n---------+----------+---------+----------+--------------+---------------+----------+-----------+------------+-------------+-------------+----------------+----------------+----------------+--------+--------\n lower | 256 | 11 | f | t | t | 1 | f | 25 | 25 | 100 | 0 | 0 | 100 | lower | -\n lower | 256 | 11 | f | t | t | 1 | f | 25 | 1043 | 100 | 0 | 0 | 100 | lower | -\n(2 rows)\n\n-- ok, looks like I got it right ...\n\nregression=# create index f1lower on f1v (lower(f1));\nCREATE\n\nThis will be a tiny bit slower than if the function were really truly\nbuilt-in, but it should work well enough.\n\nBut since type varchar is considered binary-compatible with type text,\nyou shouldn't have had to create the extra function entry. It looks\nlike the indexing routines do not pay attention to binary type\ncompatibility when looking up functions for functional indexes. I'm not\ngoing to try fixing that now, but it's something that should be on the\nTODO list:\n * Functional indexes should allow functions on binary-compatible types\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 10:59:09 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "Excellent, Tom. Thanks!\n\nIt went from\n\nipa=# explain select * from applicants as a where a.firstname ~* '^mitch'\nlimit 10 offset 0;\nNOTICE: QUERY PLAN:\n\nSeq Scan on applicants a (cost=0.00..1355.54 rows=98 width=599)\n\nEXPLAIN\nipa=#\n\nTo....\n\nipa=# explain select * from applicants as a where lower(a.firstname) ~\nlower('^mitch') limit 10 offset 0;\nNOTICE: QUERY PLAN:\n\nIndex Scan using applicants_firstname on applicants a (cost=0.00..228.47\nrows=98 width=599)\n\nEXPLAIN\n\nOn 7.0 RC5.\n\nCould putting that function in there even though it's not 'built-in' cause\nany problems that you can think of? (Mainly worried about any kind of index\ncorruption like I've seen before)\n\nThanks again!\n\n- Mitch\n\n\n\n", "msg_date": "Fri, 5 May 2000 11:32:11 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Indexing varchar fields with lower()" }, { "msg_contents": "\"Mitch Vincent\" <[email protected]> writes:\n> Could putting that function in there even though it's not 'built-in' cause\n> any problems that you can think of? (Mainly worried about any kind of index\n> corruption like I've seen before)\n\nNo, shouldn't be a problem. The only thing non \"built in\" about it is\nthat fmgr.c has to find the function by name rather than by OID (there's\na shortcut for the OIDs of the standard pg_proc entries). So the lookup\nis a tad slower, that's all.\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 12:33:55 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Indexing varchar fields with lower() " } ]
[ { "msg_contents": "Hi all,\n\nI am running mandrake 7.0 on an AMD450\nwhen trying to complie 7.0RC2 I get the folowing error :-\n\nIn file included from pgconnection.cc:18:\npgconnection.h:84: syntax error before `('\npgconnection.cc:116: syntax error before `::'\n...........\n\nNeed any more details ?\n\nTIA,\n Frank.\n\n\n", "msg_date": "Tue, 02 May 2000 21:10:09 -0400", "msg_from": "frank <[email protected]>", "msg_from_op": true, "msg_subject": "7.0RC2 compile error !" }, { "msg_contents": "> Hi all,\n> \n> I am running mandrake 7.0 on an AMD450\n> when trying to complie 7.0RC2 I get the folowing error :-\n> \n> In file included from pgconnection.cc:18:\n> pgconnection.h:84: syntax error before `('\n> pgconnection.cc:116: syntax error before `::'\n> ...........\n> \n\nWell, seems it is in the libpq++ compile. I am confused why you are\nhaving a problem at that point in the compile, though.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 21:14:50 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error !" } ]
[ { "msg_contents": "> > Yes:\n> >\n> > g++ -v\n> >\n> > --\n> > Bruce Momjian | http://www.op.net/~candle\n> > [email protected] | (610) 853-3000\n> > + If your life is a hard drive, | 830 Blythe Avenue\n> > + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n> \n> Reading specs from /usr/lib/gcc-lib/i586-mardrake-linux/2.95.2/specs\n> gcc version 2.95.2 19991024 (release)\n\nPretty recent. It certainly compiles under gcc version 2.7.2.1. Strange.\n\nMaybe it is a buggy g++. Just a guess.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 22:27:40 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] 7.0RC2 compile error !" }, { "msg_contents": "> Pretty recent. It certainly compiles under gcc version 2.7.2.1. Strange.\n> Maybe it is a buggy g++. Just a guess.\n\nI'm running the same distro/version and the current cvs tree (a bit\nmore recent than Frank's example afaik) compiles without errors.\n\nI'll guess that it is a configuration issue on Frank's machine, or\nthat RC2 predates the last libpq++ code fixes.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Wed, 03 May 2000 04:51:19 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] 7.0RC2 compile error !" }, { "msg_contents": "Thomas Lockhart wrote:\n\n> > Pretty recent. It certainly compiles under gcc version 2.7.2.1. Strange.\n> > Maybe it is a buggy g++. Just a guess.\n>\n> I'm running the same distro/version and the current cvs tree (a bit\n> more recent than Frank's example afaik) compiles without errors.\n>\n> I'll guess that it is a configuration issue on Frank's machine, or\n> that RC2 predates the last libpq++ code fixes.\n>\n> - Thomas\n>\n> --\n> Thomas Lockhart [email protected]\n> South Pasadena, California\n\nWell I just downloaded 7.0RC3 and it still produces\nthe same compiler errors :(\nAs far as my machine configuration, the machine I\njust compiled this on is a new install Mandrake 7.0 no\nfiddles, so I can only assume that everyone with this\ndistr can expect this problem.\nBTW Mandrake just became #1 download distro.\n\nWhere do I go from here ? (be nice ;)\n\n\n", "msg_date": "Wed, 03 May 2000 09:32:53 -0400", "msg_from": "frank <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] 7.0RC2 compile error !" }, { "msg_contents": "On Wed, 03 May 2000, frank wrote:\n> Thomas Lockhart wrote:\n> > I'm running the same distro/version and the current cvs tree (a bit\n> > more recent than Frank's example afaik) compiles without errors.\n \n> Well I just downloaded 7.0RC3 and it still produces\n> the same compiler errors :(\n> As far as my machine configuration, the machine I\n> just compiled this on is a new install Mandrake 7.0 no\n> fiddles, so I can only assume that everyone with this\n> distr can expect this problem.\n> BTW Mandrake just became #1 download distro.\n\n> Where do I go from here ? (be nice ;)\n\nThomas: rpm -qa >thomas.rpm-list\nFrank: rpm -qa >frank.rpm-list\n\nThomas, send thomas.rpm-list to Frank.\n\nFrank, diff thomas.rpm-list frank.rpm-list and see what development libraries\netc Thomas has that you don't.\n\n--\nLamar Owen\nWGCR Internet Radio\n1 Peter 4:11\n", "msg_date": "Wed, 3 May 2000 09:54:51 -0400", "msg_from": "Lamar Owen <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] 7.0RC2 compile error !" }, { "msg_contents": "On Wed, May 03, 2000 at 09:32:53AM -0400, frank wrote:\n> \n> Well I just downloaded 7.0RC3 and it still produces\n> the same compiler errors :(\n> As far as my machine configuration, the machine I\n> just compiled this on is a new install Mandrake 7.0 no\n> fiddles, so I can only assume that everyone with this\n> distr can expect this problem.\n> BTW Mandrake just became #1 download distro.\n> \n> Where do I go from here ? (be nice ;)\n> \n\nConfiguration details: did you feed ./configure any special switches?\n\nRoss\n-- \nRoss J. Reedstrom, Ph.D., <[email protected]> \nNSBRI Research Scientist/Programmer\nComputer and Information Technology Institute\nRice University, 6100 S. Main St., Houston, TX 77005\n", "msg_date": "Wed, 3 May 2000 10:17:56 -0500", "msg_from": "\"Ross J. Reedstrom\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error !" }, { "msg_contents": ">> Where do I go from here ? (be nice ;)\n\n> Configuration details: did you feed ./configure any special switches?\n\nThe output of configure would also be interesting. Also, I've forgotten\nexactly what the error messages you got were? (Time for another whine\nabout the sad state of the pghackers archives :-()\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 11:43:39 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " }, { "msg_contents": "frank <[email protected]> writes:\n>>>> Configuration details: did you feed ./configure any special switches?\n>> \n>> The output of configure would also be interesting. Also, I've forgotten\n>> exactly what the error messages you got were? (Time for another whine\n>> about the sad state of the pghackers archives :-()\n\n>> In file included from pgconnection.cc:18:\n>> pgconnection.h:84: syntax error before `('\n>> pgconnection.cc:116: syntax error before `::'\n\nOK, both of those are pointing at uses of datatype \"string\". I suspect\nthat this code near the head of pgconnection.h is failing to fire:\n\n#ifdef HAVE_CXX_STRING_HEADER\n#include <string>\n#endif\n\neither because you indeed haven't got the C++ standard <string> header\n(not to be confused with C's <string.h> --- is there a separate \"devel\"\nRPM for C++ header files? if so, do you have it?), or because configure\ngot confused and failed to define HAVE_CXX_STRING_HEADER when it should.\nCan't tell which though; the config.cache file you sent doesn't record\nanything about HAVE_CXX_STRING_HEADER.\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 12:15:04 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " }, { "msg_contents": "frank <[email protected]> writes:\n\n(on errors with Mandrake)\n\n> Well I just downloaded 7.0RC3 and it still produces\n> the same compiler errors :(\n\nIt compiles just fine on Red Hat Linux 6.2\n\nThis wouldn't be the first time Mandrake ship a bad compiler - try to\ninstall the ones from Red Hat 6.2 (and libstdc++ w/headers) and see if\nthat works.\n\n-- \nTrond Eivind Glomsr�d\nRed Hat, Inc.\n", "msg_date": "03 May 2000 12:21:01 -0400", "msg_from": "[email protected] (Trond Eivind=?iso-8859-1?q?_Glomsr=F8d?=)", "msg_from_op": false, "msg_subject": "Re: [HACKERS] 7.0RC2 compile error !" }, { "msg_contents": "On Wed, 3 May 2000, Tom Lane wrote:\n\n> >> Where do I go from here ? (be nice ;)\n> \n> > Configuration details: did you feed ./configure any special switches?\n> \n> The output of configure would also be interesting. Also, I've forgotten\n> exactly what the error messages you got were? (Time for another whine\n> about the sad state of the pghackers archives :-()\n\nwait, now I'm confused ... I just did a ... oops ... hold ... let me fix\nthat last archive file ... brb ...\n\n\n", "msg_date": "Wed, 3 May 2000 13:32:17 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " }, { "msg_contents": "\nokay, check it now ... just got the Apr stuff that was directed to the\nwrong directory parsed back in, mhonarc'd and is currently indexing ...\n\n\nOn Wed, 3 May 2000, The Hermit Hacker wrote:\n\n> On Wed, 3 May 2000, Tom Lane wrote:\n> \n> > >> Where do I go from here ? (be nice ;)\n> > \n> > > Configuration details: did you feed ./configure any special switches?\n> > \n> > The output of configure would also be interesting. Also, I've forgotten\n> > exactly what the error messages you got were? (Time for another whine\n> > about the sad state of the pghackers archives :-()\n> \n> wait, now I'm confused ... I just did a ... oops ... hold ... let me fix\n> that last archive file ... brb ...\n> \n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 3 May 2000 14:08:42 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " }, { "msg_contents": "frank <[email protected]> writes:\n> Yup your dead right, the <string> include failed in the configure.\n> Isn't configure supposed to tell the user that something failed ?,\n> I have no idea what is an acceptable configuration for this s/w !\n\n> checking for namespace std in C++... yes\n> checking for include <string> in C++... no\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\nYup, there's our problem. Your C++ setup is evidently pretty modern,\nsince it knows what namespace std is. My guess is that you don't have\nthe headers for libstdc++ installed.\n\nIt would probably be a good idea to add another configure test to see\nwhether class \"string\" is actually available, and disable building\nlibpq++ if not. (We shouldn't simply kill libpq++ if the \"include\n<string>\" test fails, since older C++ installations may have class\nstring in <string.h>. But if we can't find a header that defines class\nstring at all, then libpq++ is definitely going to fall over.)\n\nAny objections if I sneak in such a configure test? Should be a\nlow-risk change.\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 13:38:56 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " }, { "msg_contents": "On Wed, 3 May 2000, Tom Lane wrote:\n\n> frank <[email protected]> writes:\n> > Yup your dead right, the <string> include failed in the configure.\n> > Isn't configure supposed to tell the user that something failed ?,\n> > I have no idea what is an acceptable configuration for this s/w !\n> \n> > checking for namespace std in C++... yes\n> > checking for include <string> in C++... no\n> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n> \n> Yup, there's our problem. Your C++ setup is evidently pretty modern,\n> since it knows what namespace std is. My guess is that you don't have\n> the headers for libstdc++ installed.\n> \n> It would probably be a good idea to add another configure test to see\n> whether class \"string\" is actually available, and disable building\n> libpq++ if not. (We shouldn't simply kill libpq++ if the \"include\n> <string>\" test fails, since older C++ installations may have class\n> string in <string.h>. But if we can't find a header that defines class\n> string at all, then libpq++ is definitely going to fall over.)\n> \n> Any objections if I sneak in such a configure test? Should be a\n> low-risk change.\n\ngo for it, I want to do up a quick RC4 with th efixes to the docs that I\ndid the other day, so let me know when, and I'll do it then ...\n\n\n", "msg_date": "Wed, 3 May 2000 15:03:27 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n>> Any objections if I sneak in such a configure test? Should be a\n>> low-risk change.\n\n> go for it, I want to do up a quick RC4 with th efixes to the docs that I\n> did the other day, so let me know when, and I'll do it then ...\n\nOK, done.\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 14:33:19 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " }, { "msg_contents": "\ndone ... there is an RC4 there now, with just your configure changes and\nthe docs ones ... \n\nThis will be the release on Monday unless anyone has anything else major\nto add ... :)\n\n\nOn Wed, 3 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> >> Any objections if I sneak in such a configure test? Should be a\n> >> low-risk change.\n> \n> > go for it, I want to do up a quick RC4 with th efixes to the docs that I\n> > did the other day, so let me know when, and I'll do it then ...\n> \n> OK, done.\n> \n> \t\t\tregards, tom lane\n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 3 May 2000 16:35:07 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " }, { "msg_contents": "Tom Lane writes:\n\n> It would probably be a good idea to add another configure test to see\n> whether class \"string\" is actually available, and disable building\n> libpq++ if not. (We shouldn't simply kill libpq++ if the \"include\n> <string>\" test fails, since older C++ installations may have class\n> string in <string.h>. But if we can't find a header that defines class\n> string at all, then libpq++ is definitely going to fall over.)\n\nAs a short term solution, why not, it's already bad enough. But for the\nfuture I'd like to suggest the adoption of a different principle: It's not\nacceptable for parts of the tree to not be built based on the results of\nconfigure tests. There are several reasons for that, the first and\nforemost being that a configure script is not interactive. Users shouldn't\nbe required to monitor what flies by or, worse yet, deduce from cryptic\nmessages that stuff isn't going to be build at all. This is an incredible\ncan of worms for a package that interfaces to so many other software. For\nthe benefit of both users and maintainers, a configure run with the same\noptions must produce an installation that behaves the same on any\nmachine. I know this is slightly impractical in some cases, but only in\nsome.\n\nIn this particular case what ought to happen is this: When the package is\nbeing configured to build libpq++ (whether by default or explicitly) and\nsome necessary feature is missing then the build must fail hard. Silently\nignoring build errors as has been suggested is equally problematic because\nusers will not sit in front of their terminal for 20 minutes and scan the\nmake output. In practice it might be preferrable to not make the C++ build\ndefault because it's really no more special than say the Perl or Tcl\ninterface and exposes people that don't really care/know about C++ to\ngratuitous problems. Also, the current configure run will fail if you\ndon't have a C++ compiler at all.\n\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Thu, 4 May 2000 18:24:50 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " }, { "msg_contents": "Peter Eisentraut <[email protected]> writes:\n> As a short term solution, why not, it's already bad enough. But for the\n> future I'd like to suggest the adoption of a different principle: It's not\n> acceptable for parts of the tree to not be built based on the results of\n> configure tests. There are several reasons for that, the first and\n> foremost being that a configure script is not interactive. Users shouldn't\n> be required to monitor what flies by or, worse yet, deduce from cryptic\n> messages that stuff isn't going to be build at all.\n\nIt currently says:\n\n***\nDisabling build of libpq++ because we cannot find class string in the\nsystem's C++ header files.\n***\n\nToo cryptic for you?\n\nI have a different take on the matter: it's not acceptable for a default\nbuild of Postgres to fail hard because the local system's C++ compiler\nis broken, libstdc++ is missing or incomplete, etc. There are too many\nmachines that fit that description and too few people using libpq++ to\njustify treating libpq++ as an essential component.\n\nPerhaps we could agree on a compromise that libpq++ ought not be built\nat all unless specifically requested by a configure switch (eg,\n\"--with-libpq++\"). If the user actually asked for it, then failing hard\nis reasonable behavior. It's too late to make such a change for 7.0,\nI think, but we could do it for 7.1.\n\n> Silently ignoring build errors as has been suggested is equally\n> problematic because users will not sit in front of their terminal for\n> 20 minutes and scan the make output.\n\nRight, I don't like that idea either.\n\n> Also, the current configure run will fail if you\n> don't have a C++ compiler at all.\n\nFail completely? I haven't tried that lately, but from the Autoconf\ndocs I'd expect it to set CXX=gcc and then all the C++ feature tests\nwould fail because gcc isn't there (or doesn't grok C++) --- which as\nthings currently stand would end in our deciding not to build libpq++.\nSeems fairly reasonable. If configure actually falls over in that case\nthen we've blown it...\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 13:35:16 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " }, { "msg_contents": "> It would probably be a good idea to add another configure test to see\n> whether class \"string\" is actually available, and disable building\n> libpq++ if not. (We shouldn't simply kill libpq++ if the \"include\n> <string>\" test fails, since older C++ installations may have class\n> string in <string.h>. But if we can't find a header that defines class\n> string at all, then libpq++ is definitely going to fall over.)\n> \n> Any objections if I sneak in such a configure test? Should be a\n> low-risk change.\n> \n> \t\t\tregards, tom lane\n> \n\nI would like to see one other user with the problem first.\n\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Thu, 4 May 2000 23:55:52 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: 7.0RC2 compile error !" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n>> It would probably be a good idea to add another configure test to see\n>> whether class \"string\" is actually available, and disable building\n>> libpq++ if not.\n\n> I would like to see one other user with the problem first.\n\nFrank's problem was that he had only installed the runtime RPM for\nlibstdc++, not the devel RPM. Do you think he's the only such user?\n(Especially considering that he said he was running a stock Mandrake\ndistro...)\n\nAnyway, the fix is already committed, and it's the least of the\ndamage I've done today. Amazing how permissive Marc gets when a bug\nis biting him personally ;-). Do you want to argue for putting off\nthe release date so we can get more testing on these fixes?\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 00:02:24 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " }, { "msg_contents": "On Fri, 5 May 2000, Tom Lane wrote:\n\n> Bruce Momjian <[email protected]> writes:\n> >> It would probably be a good idea to add another configure test to see\n> >> whether class \"string\" is actually available, and disable building\n> >> libpq++ if not.\n> \n> > I would like to see one other user with the problem first.\n> \n> Frank's problem was that he had only installed the runtime RPM for\n> libstdc++, not the devel RPM. Do you think he's the only such user?\n> (Especially considering that he said he was running a stock Mandrake\n> distro...)\n> \n> Anyway, the fix is already committed, and it's the least of the\n> damage I've done today. Amazing how permissive Marc gets when a bug\n> is biting him personally ;-). Do you want to argue for putting off\n> the release date so we can get more testing on these fixes?\n\nI swear, no matter what software I use, if there is a bug that can be\ntweaked or triggered, I'll find a way to do it *sigh*\n\n\n", "msg_date": "Fri, 5 May 2000 01:15:55 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " }, { "msg_contents": "> Bruce Momjian <[email protected]> writes:\n> >> It would probably be a good idea to add another configure test to see\n> >> whether class \"string\" is actually available, and disable building\n> >> libpq++ if not.\n> \n> > I would like to see one other user with the problem first.\n> \n> Frank's problem was that he had only installed the runtime RPM for\n> libstdc++, not the devel RPM. Do you think he's the only such user?\n> (Especially considering that he said he was running a stock Mandrake\n> distro...)\n> \n> Anyway, the fix is already committed, and it's the least of the\n> damage I've done today. Amazing how permissive Marc gets when a bug\n> is biting him personally ;-). Do you want to argue for putting off\n> the release date so we can get more testing on these fixes?\n> \n\nI say shoot it out the door. It is not like 7.0.0 is going to be\nperfect and we aren't going to need a 7.0.1.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 01:40:35 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: 7.0RC2 compile error !" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n>> Anyway, the fix is already committed, and it's the least of the\n>> damage I've done today. Amazing how permissive Marc gets when a bug\n>> is biting him personally ;-). Do you want to argue for putting off\n>> the release date so we can get more testing on these fixes?\n\n> I say shoot it out the door. It is not like 7.0.0 is going to be\n> perfect and we aren't going to need a 7.0.1.\n\nThere is that. There will *always* be one more bug ;-). Unless we\nsee another showstopper-class bug report between now and Monday,\nI'd be happy with release on Monday.\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 02:07:29 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0RC2 compile error ! " } ]
[ { "msg_contents": "\nWell folks, we're in the last stretch here. I've just created a Release\nCandidate 3, primarily to incorporate the doc changes recently commit'd by\nThomas Lockhart ...\n\nThe Release Candidate is meant to represent what the Final Release will\nlook like, pending any minor changes between now and release. Since I'd\nprefer not to do a release on Friday, just before a weekend, unless there\nare any objections, the Full Release is schedualed to be on Monday, May\n8th, giving a few more days of testing by the developer community ...\n\nAs usual, Release Candidates are available at:\n\n\tftp://ftp.postgresql.org/pub \n\nin both single and multi tar formats ...\n\n--------\n\n- Remove derived files from CVS. \n- Remove bogus 'xid loop detected' check, which actually wasn't detecting\n loops, but just arbitrarily failing at 1000 locks.\n- Reset CurrentMemoryContext to TopMemoryContext at the beginning of error\n cleanup, ie, as soon as we have caught the longjmp. This ensures that\n current context will be a valid context throughout error cleanup. Before\n it was possible that current context was pointing at a context that would\n get deleted during cleanup, leaving any subsequent pallocs in deep\n trouble. \n- Modify getdatabaseencoding(), pg_encoding_to_char()\n pg_char_to_encoding() in multibyte disbaled case so that it does not\n throw an error, rather return HARD CODED default value (currently SQL_ASCII).\n This would solve the \"non-mb backend vs. mb-enabled frontend\" problem.\n\n\n", "msg_date": "Wed, 3 May 2000 00:01:05 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "PostgreSQL v7.0 - Release Candidate 3 " } ]
[ { "msg_contents": "Is pgtksh the same as tcl/tk wish, except with a PostgreSQL interface?\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 23:17:16 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "pgtksh" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n> Is pgtksh the same as tcl/tk wish, except with a PostgreSQL interface?\n\nRight.\n* tclsh = interactive Tcl (and nothing else).\n* wish = tclsh plus Tk library (\"wish\" = \"windowing shell\", but I think\n tksh would've been a more self-explanatory name).\n* pgtclsh is tclsh with libpgtcl preloaded.\n* pgtksh is wish with libpgtcl preloaded.\nNothin' up my sleeve...\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 02 May 2000 23:46:23 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pgtksh " }, { "msg_contents": "> Bruce Momjian <[email protected]> writes:\n> > Is pgtksh the same as tcl/tk wish, except with a PostgreSQL interface?\n> \n> Right.\n> * tclsh = interactive Tcl (and nothing else).\n> * wish = tclsh plus Tk library (\"wish\" = \"windowing shell\", but I think\n> tksh would've been a more self-explanatory name).\n\nAgreed.\n\n> * pgtclsh is tclsh with libpgtcl preloaded.\n> * pgtksh is wish with libpgtcl preloaded.\n\nThanks. Seems Jolly is still in the README as the maintainer. I bet he\nwould get a kick out of that.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 23:52:58 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pgtksh" } ]
[ { "msg_contents": "Never mind. I see in the pgtclsh README:\n\nThe pgtclsh is an enhanced version of tclsh. Similarly, pgtksh is a\nwish replacement with postgres95 bindings.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 23:21:51 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "pgtksh" } ]
[ { "msg_contents": "Here is a patch to the ksh script to that fixes the man pages for UnixWare. \nIt changes references in the man pages to other man pages in section 'l' so \nthat they reference section '1sql'.\n\n\n\n____ | Billy G. Allie | Domain....: [email protected]\n| /| | 7436 Hartwell | Compuserve: 76337,2061\n|-/-|----- | Dearborn, MI 48126| MSN.......: [email protected]\n|/ |LLIE | (313) 582-1540 |", "msg_date": "Tue, 02 May 2000 23:35:45 -0400", "msg_from": "\"Billy G. Allie\" <[email protected]>", "msg_from_op": true, "msg_subject": "Patch for FAQ_SCO" }, { "msg_contents": "Applied.\n\n-- Start of PGP signed section.\n> Here is a patch to the ksh script to that fixes the man pages for UnixWare. \n> It changes references in the man pages to other man pages in section 'l' so \n> that they reference section '1sql'.\n> \nContent-Description: uw7-20000502.patch\n\n[Attachment, skipping...]\n\n> ____ | Billy G. Allie | Domain....: [email protected]\n> | /| | 7436 Hartwell | Compuserve: 76337,2061\n> |-/-|----- | Dearborn, MI 48126| MSN.......: [email protected]\n> |/ |LLIE | (313) 582-1540 | \n-- End of PGP section, PGP failed!\n\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 2 May 2000 23:45:30 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Patch for FAQ_SCO" } ]
[ { "msg_contents": "\nharmless, just mail->news stuff ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 3 May 2000 01:19:53 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Testing something ..." }, { "msg_contents": "\nthat didn't work as hoped ... how about this?\n\nOn Wed, 3 May 2000, The Hermit Hacker wrote:\n\n> \n> harmless, just mail->news stuff ...\n> \n> Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy\n> Systems Administrator @ hub.org \n> primary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 3 May 2000 01:38:53 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Testing something ..." }, { "msg_contents": "[email protected] (The Hermit Hacker) writes:\n\n\n>that didn't work as hoped ... how about this?\n\nnext question is will it let me post back through news properly too?\n\n\n\n>On Wed, 3 May 2000, The Hermit Hacker wrote:\n\n>> \n>> harmless, just mail->news stuff ...\n>> \n>> Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy\n>> Systems Administrator @ hub.org \n>> primary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n>> \n\n>Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy\n>Systems Administrator @ hub.org \n>primary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n--\nMarc G. Fournier [email protected]\nSystems Administrator @ hub.org \nscrappy@{postgresql|isc}.org ICQ#7615664\n", "msg_date": "3 May 2000 04:53:37 GMT", "msg_from": "[email protected] (Marc G. Fournier)", "msg_from_op": false, "msg_subject": "Re: Testing something ..." } ]
[ { "msg_contents": "At , Malcontent null wrote:\n\n>The question dealt with trying to acieve case insensitive collation in\npostgres. Specifically about possibly rewriting the text_cmp or the\nvarchareq functions. I am wondering what kind of mayhem that might cause. I\nwas told by someone who tried it that it's possible to overload the ~~\n(like) operator but that dropping the = operator cripples the database so\nthat it's not possible to overload the = operator. \n>\n>As to why I might want to do this I'll answer that one in response to\nanother question :)\n\nActually, I'd suggest you state the problem you're trying to solve first,\nrather\nthan present the reasons you think PG can't handle the problem without\nshowing your\nhand. Saying, \"how can I implement the following solution to an unstated\nproblem\"\nrather than simply stating the problem seems ... well, impolite at first\nglance.\n\nI'm assuming that you actually are seeking a solution, rather than starting\nsome sort of crusade in favor of a pet peeve?\n\nDon't misunderstand ... you may be right, there may be no way to solve your\nproblem efficiently in PG. But until you tell us what you're trying to do,\nwe have no way to decide whether or not you've actually exhausted the\npossibilities.\n\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Tue, 02 May 2000 21:55:37 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "The Hermit Hacker <[email protected]> wrote:\n>\n>On Tue, 2 May 2000, Tim Uckun wrote:\n>\n>> If I can't get my questions answered about case sensitivity issues here\n>> (no help so far) I will most likely to use it myself. \n>\n>What questions? *raised eyebrow* \n>\n>\n\nThe question dealt with trying to acieve case insensitive collation in postgres. Specifically about possibly rewriting the text_cmp or the varchareq functions. I am wondering what kind of mayhem that might cause. I was told by someone who tried it that it's possible to overload the ~~ (like) operator but that dropping the = operator cripples the database so that it's not possible to overload the = operator. \n\nAs to why I might want to do this I'll answer that one in response to another question :)\n----------\nMessage To Spammers -- Game Over! Get spam-free email at http://www.MsgTo.com\n", "msg_date": "Wed May 03 00:42:27 EDT 2000", "msg_from": "Malcontent null <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" } ]
[ { "msg_contents": "> I fully understand that you guys have your own set of priorities. I also\n> appreciate the work you guys have put into making postgres into a database\n> I want to use. Having said all that I did wait 4 to 5 days without a reply\n> of any sort. It would have been perfectly fine for somebody to say \"It's not\n> possible don't waste your time\", \"Don't ask this question here\", \"we are\n> really entirely too busy to deal with this\" or even \"go away and don't ever\n> bother us ever again\".\n\nWell, none of those things are true, and it is rare that someone would\nspeak for a group this widely distributed to say \"we are too busy\". In\nmost cases, when the usual suspects are too busy someone else will\npost an answer to a question, and you are never likely to get a\ndefinitive \"I'm too busy and everyone else is too\".\n\nAt some point, someone may have time to answer *exactly* the questions\nyou asked. Another strategy to try after the first one failed is to\ncome in with the more detailed problem statement, asking for\nsuggestions on a solution. Particularly if you can phrase it so it is\nclear that it may solve problems for a larger class of user than the\none who managed to grow a M$ Access app to 300 tables and 1400 queries\nbefore deciding that Access might be a little light in performance to\nbe suitable. But that's water under the bridge, eh?\n\nAnyway, so the larger class of problem is for the Sybase/M$ user who\nrelies on case insensitive queries (which *are* available in Postgres)\nwhich are indistinguishable from the SQL92-mandated case-sensitive\nones. So we might explore the possibilities for a contrib/ module\nwhich does this, though because it touches on replacing existing\nbackend code it may not quite fly since there are some function lookup\noptimizations which may keep you from overwriting the existing\nroutines. But it would be a neat capability to have; I wonder if it\nwould work right away or if we could tweak the backend to allow this\nin the future??\n\nOf course the alternative is to just dive in and hack and slash at the\nbackend code. Look in parser/gram.y and utils/adt/like.c for\nstarters...\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Wed, 03 May 2000 05:07:56 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "> Of course the alternative is to just dive in and hack and slash at the\n> backend code. Look in parser/gram.y and utils/adt/like.c for\n> starters...\n\nThat would be my recommendation. It is open source, so you can modify\nit however you like.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Wed, 3 May 2000 09:06:57 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "Thomas Lockhart <[email protected]> wrote:\n\n>existing M$ Access app. So far, we were too polite to ask why one is\n>working so hard to maintain compatibility with a non-standard\n>interface, rather than writing the app to be portable. But I'll ask\n>now. Tim?\n\nFair enough question. I agree with you that this is non standard typical MS lock in crap. But I have an application that is written in access and has outgrown the data engine in access (which is pretty pathetic). Unfortunately this application is very large with over 300 tables and over 1400 saved queries (views). The MS solution to this problem is to upgrade to MS-SQL server (vendor lock in) which processes the queries in the exact same case insensitive manner. SQL server does not break my application. I on the other hand want to avoid upsizing to SQL server. I could use sybase which also allows for case insensitive collation (no surprise there) but I really-really want to use an upen source database server.\nSo. So right now I have a few choices.\n1) Buckle into the vendor lock and be stuck with NT and SQL server\n2) Buy sybase and spend way more then I want to.\n3) Completely rewrite all 1400 queries and write all kinds of new code make sure the SQL emitted by access gets intercepted and translated properly.\n4) Make Postgres process queries case insensitively.\n\nWell the third one is out of the question really I don't have that kind of time or money. It would take me a the rest of the year to accomplish that goal and the database would have to be taken out of commision in the meantime. \n\n>\n>btw, it seems to be the case that problems such as these, which might\n>be interesting during slow times (from a theoretical standpoint at\n>least), are decidely less so during the final stages of a release\n>cycle.\n\nI fully understand that you guys have your own set of priorities. I also appreciate the work you guys have put into making postgres into a database I want to use. Having said all that I did wait 4 to 5 days without a reply of any sort. It would have been perfectly fine for somebody to say \"It's not possible don't waste your time\", \"Don't ask this question here\", \"we are really entirely too busy to deal with this\" or even \"go away and don't ever bother us ever again\". \n----------\nMessage To Spammers -- Game Over! Get spam-free email at http://www.MsgTo.com\n", "msg_date": "Wed May 03 01:04:53 EDT 2000", "msg_from": "Malcontent null <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" } ]
[ { "msg_contents": "He's probably using the 6.5.3 driver.\n\nPeter\n\n-- \nPeter Mount\nEnterprise Support\nMaidstone Borough Council\nAny views stated are my own, and not those of Maidstone Borough Council.\n\n\n\n-----Original Message-----\nFrom: Don Baccus [mailto:[email protected]]\nSent: Tuesday, May 02, 2000 5:23 PM\nTo: Tom Lane; Thomas Lockhart\nCc: Bruce Momjian; Peter Mount; Lamar Owen; PostgreSQL-development;\nPostgreSQL-interfaces; Peter Mount (Home)\nSubject: Re: [HACKERS] Request for 7.0 JDBC status \n\n\nAt 12:02 PM 5/2/00 -0400, Tom Lane wrote:\n\n>Relevant question: how well does the JDBC code that's in CVS now\n>work with 7.0? If the answer is \"hardly at all\" then a new driver\n>is probably better even if it has lurking bugs. If the answer is\n>\"pretty well\" then again I'd be inclined to ship what we've got.\n\nOne of our OpenACS (until recently ACS/pg) crew has gotten the\nArsDigita webmail software running with PG7.0 and JDBC, apparently\nwithout problems.\n\nI don't know which beta he's running, though...\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Wed, 3 May 2000 07:36:19 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: [HACKERS] Request for 7.0 JDBC status " } ]
[ { "msg_contents": "Hmmm, interesting, especially as Field hasn't changed since 6.5.2...\n\nPeter\n\n-- \nPeter Mount\nEnterprise Support\nMaidstone Borough Council\nAny views stated are my own, and not those of Maidstone Borough Council.\n\n\n\n-----Original Message-----\nFrom: Anand Raman [mailto:[email protected]]\nSent: Wednesday, May 03, 2000 5:17 AM\nTo: Bruce Momjian\nCc: PostgreSQL-development\nSubject: [HACKERS] Re: [GENERAL] postgresql7.0 jdbc driver\n\n\nHi Bruce\nI am using jdk1.2.2 \njava version \"1.2.2-RC2\"\nClassic VM (build 1.2.2-RC2-K, green threads, javacomp) \nBye\nAnand Raman\n----- Original Message ----- \nFrom: Bruce Momjian <[email protected]>\nTo: Anand Raman <[email protected]>\nCc: PostgreSQL-development <[email protected]>\nSent: Wednesday, May 03, 2000 9:23 AM\nSubject: Re: [GENERAL] postgresql7.0 jdbc driver\n\n\n> [Charset iso-8859-1 unsupported, filtering to ASCII...]\n> > HI guys\n> > Thanx for the quick reply.. \n> > \n> > When i tried compiling jdbc for postgresql700 I encounter the\nfollowing error\n> > \n> > postgres@localhost > make jdbc1\n> > (echo \"package postgresql;\" ;\\\n> > echo \"public class DriverClass {\" ;\\\n> > echo \"public static String\nconnectClass=\\\"postgresql.jdbc1.Connection\\\";\" ;\\\n> > echo \"}\" \\\n> > ) >postgresql/DriverClass.java\n> > make[1]: Entering directory\n`/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\n> > javac -g postgresql/DriverClass.java\n> > javac -g postgresql/Connection.java\n> > postgresql/Connection.java:447: Wrong number of arguments in\nconstructor.\n> > fields[i] = new Field(this, typname, typid, typlen,\ntypmod);\n> > ^\n> > 1 error\n> > make[1]: *** [postgresql/Connection.class] Error 1\n> > make[1]: Leaving directory\n`/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\n> > make: *** [jdbc1] Error 2\n> > \n> > same is the case with $ make jdbc2\n> \n> What java are you using?\n> \n> -- \n> Bruce Momjian | http://www.op.net/~candle\n> [email protected] | (610) 853-3000\n> + If your life is a hard drive, | 830 Blythe Avenue\n> + Christ can be your backup. | Drexel Hill, Pennsylvania\n19026\n> \n", "msg_date": "Wed, 3 May 2000 07:58:53 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: Re: [GENERAL] postgresql7.0 jdbc driver" }, { "msg_contents": "Hi peter\nWhich beta release of postgresql700 are you using.\nI am on postgresql 7.0 beta5 \nCould it cause the mentioned problems\nThanx for ur time\nAnand Raman\n\n----- Original Message ----- \nFrom: Peter Mount <[email protected]>\nTo: 'Anand Raman' <[email protected]>; Bruce Momjian <[email protected]>\nCc: PostgreSQL-development <[email protected]>\nSent: Wednesday, May 03, 2000 12:28 PM\nSubject: RE: [HACKERS] Re: [GENERAL] postgresql7.0 jdbc driver\n\n\n> Hmmm, interesting, especially as Field hasn't changed since 6.5.2...\n> \n> Peter\n> \n\n\n", "msg_date": "Wed, 3 May 2000 16:23:13 +0530", "msg_from": "\"Anand Raman\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: [GENERAL] postgresql7.0 jdbc driver" } ]
[ { "msg_contents": "\n> \"In a nutshell I want to use postgres as a back end to an access\n> database. This means that all collation done by postgres musht be case\n> insensitive including like clauses.\"\n> \n> I left the all the spelling mistakes in place :)\n\nCould a national char implementation that is case insensitive be a solution\nhere ?\nMeaning: is it as simple as setting LC_COLLATE to another value and\nconfiguring\n--enable-locale ?\nHow far is Thomas with the nchar nvarchar types ?\nI think national char and national char varying are the correct datatypes\nfor \nsuch behavior. Although I think the = operator is still case sensitive for\nthat datatype.\nReplacing = or like for the char and varchar or text datatypes is probably\nnot possible, \nbecause it is used internally, but for nchar ... it should be.\n\nAndreas\n", "msg_date": "Wed, 3 May 2000 10:58:51 +0200 ", "msg_from": "Zeugswetter Andreas SB <[email protected]>", "msg_from_op": true, "msg_subject": "AW: Why Not MySQL?" }, { "msg_contents": "> How far is Thomas with the nchar nvarchar types ?\n\nNo code written, but I've been thinking about it a little. After 7.0\ncomes out and things settle down I'll get a discussion going unless\nsomeone beats me to it.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Thu, 04 May 2000 05:15:56 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: AW: Why Not MySQL?" } ]
[ { "msg_contents": "Is this the blackdown one?\n\nI've just compiled from fresh using 1.3.0RC3-Z (suns one for NT) and no\nproblems. I've just downloaded 1.2.2 from a blackdown mirror (getting\n1.1.8) for Linux, so should know the build status with blackdown\nshortly...\n\nPeter\n\n-----Original Message-----\nFrom: Anand Raman [mailto:[email protected]]\nSent: Wednesday, May 03, 2000 5:17 AM\nTo: Bruce Momjian\nCc: PostgreSQL-development\nSubject: [HACKERS] Re: [GENERAL] postgresql7.0 jdbc driver\n\n\nHi Bruce\nI am using jdk1.2.2 \njava version \"1.2.2-RC2\"\nClassic VM (build 1.2.2-RC2-K, green threads, javacomp) \nBye\nAnand Raman\n----- Original Message ----- \nFrom: Bruce Momjian <[email protected]>\nTo: Anand Raman <[email protected]>\nCc: PostgreSQL-development <[email protected]>\nSent: Wednesday, May 03, 2000 9:23 AM\nSubject: Re: [GENERAL] postgresql7.0 jdbc driver\n\n\n> [Charset iso-8859-1 unsupported, filtering to ASCII...]\n> > HI guys\n> > Thanx for the quick reply.. \n> > \n> > When i tried compiling jdbc for postgresql700 I encounter the\nfollowing error\n> > \n> > postgres@localhost > make jdbc1\n> > (echo \"package postgresql;\" ;\\\n> > echo \"public class DriverClass {\" ;\\\n> > echo \"public static String\nconnectClass=\\\"postgresql.jdbc1.Connection\\\";\" ;\\\n> > echo \"}\" \\\n> > ) >postgresql/DriverClass.java\n> > make[1]: Entering directory\n`/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\n> > javac -g postgresql/DriverClass.java\n> > javac -g postgresql/Connection.java\n> > postgresql/Connection.java:447: Wrong number of arguments in\nconstructor.\n> > fields[i] = new Field(this, typname, typid, typlen,\ntypmod);\n> > ^\n> > 1 error\n> > make[1]: *** [postgresql/Connection.class] Error 1\n> > make[1]: Leaving directory\n`/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\n> > make: *** [jdbc1] Error 2\n> > \n> > same is the case with $ make jdbc2\n> \n> What java are you using?\n> \n> -- \n> Bruce Momjian | http://www.op.net/~candle\n> [email protected] | (610) 853-3000\n> + If your life is a hard drive, | 830 Blythe Avenue\n> + Christ can be your backup. | Drexel Hill, Pennsylvania\n19026\n> \n", "msg_date": "Wed, 3 May 2000 10:07:46 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: Re: [GENERAL] postgresql7.0 jdbc driver" }, { "msg_contents": "yes peter\nU are right,.. The java compiler is a blackdown port..\nWhat i do from here.. I am running SuSE 6.2 with jdk1.2.2. from blackdown\nThanx and bye\nAnand Raman\n\n----- Original Message ----- \nFrom: Peter Mount <[email protected]>\nTo: 'Anand Raman' <[email protected]>; Bruce Momjian <[email protected]>\nCc: PostgreSQL-development <[email protected]>\nSent: Wednesday, May 03, 2000 2:37 PM\nSubject: RE: [HACKERS] Re: [GENERAL] postgresql7.0 jdbc driver\n\n\n> Is this the blackdown one?\n> \n> I've just compiled from fresh using 1.3.0RC3-Z (suns one for NT) and no\n> problems. I've just downloaded 1.2.2 from a blackdown mirror (getting\n> 1.1.8) for Linux, so should know the build status with blackdown\n> shortly...\n> \n> Peter\n> \n> -----Original Message-----\n> From: Anand Raman [mailto:[email protected]]\n> Sent: Wednesday, May 03, 2000 5:17 AM\n> To: Bruce Momjian\n> Cc: PostgreSQL-development\n> Subject: [HACKERS] Re: [GENERAL] postgresql7.0 jdbc driver\n> \n> \n> Hi Bruce\n> I am using jdk1.2.2 \n> java version \"1.2.2-RC2\"\n> Classic VM (build 1.2.2-RC2-K, green threads, javacomp) \n> Bye\n> Anand Raman\n> ----- Original Message ----- \n> From: Bruce Momjian <[email protected]>\n> To: Anand Raman <[email protected]>\n> Cc: PostgreSQL-development <[email protected]>\n> Sent: Wednesday, May 03, 2000 9:23 AM\n> Subject: Re: [GENERAL] postgresql7.0 jdbc driver\n> \n> \n> > [Charset iso-8859-1 unsupported, filtering to ASCII...]\n> > > HI guys\n> > > Thanx for the quick reply.. \n> > > \n> > > When i tried compiling jdbc for postgresql700 I encounter the\n> following error\n> > > \n> > > postgres@localhost > make jdbc1\n> > > (echo \"package postgresql;\" ;\\\n> > > echo \"public class DriverClass {\" ;\\\n> > > echo \"public static String\n> connectClass=\\\"postgresql.jdbc1.Connection\\\";\" ;\\\n> > > echo \"}\" \\\n> > > ) >postgresql/DriverClass.java\n> > > make[1]: Entering directory\n> `/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\n> > > javac -g postgresql/DriverClass.java\n> > > javac -g postgresql/Connection.java\n> > > postgresql/Connection.java:447: Wrong number of arguments in\n> constructor.\n> > > fields[i] = new Field(this, typname, typid, typlen,\n> typmod);\n> > > ^\n> > > 1 error\n> > > make[1]: *** [postgresql/Connection.class] Error 1\n> > > make[1]: Leaving directory\n> `/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\n> > > make: *** [jdbc1] Error 2\n> > > \n> > > same is the case with $ make jdbc2\n> > \n> > What java are you using?\n> > \n> > -- \n> > Bruce Momjian | http://www.op.net/~candle\n> > [email protected] | (610) 853-3000\n> > + If your life is a hard drive, | 830 Blythe Avenue\n> > + Christ can be your backup. | Drexel Hill, Pennsylvania\n> 19026\n> > \n> \n\n", "msg_date": "Wed, 3 May 2000 15:05:22 +0530", "msg_from": "\"Anand Raman\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: [GENERAL] postgresql7.0 jdbc driver" } ]
[ { "msg_contents": "That's weird, as that's the same platform what I'm using (SuSE 6.2,\nJDK1_2_2):\n\nmake[1]: Entering directory\n`/var/lib/pgsql/pgsql/pgsql/src/interfaces/jdbc'\njavac -g org/postgresql/DriverClass.java\njavac -g org/postgresql/Connection.java\njavac -g org/postgresql/geometric/PGbox.java\njavac -g org/postgresql/geometric/PGcircle.java\njavac -g org/postgresql/geometric/PGline.java\njavac -g org/postgresql/geometric/PGlseg.java\njavac -g org/postgresql/geometric/PGpath.java\njavac -g org/postgresql/geometric/PGpolygon.java\njavac -g org/postgresql/util/PGmoney.java\njavac -g org/postgresql/jdbc2/ResultSet.java\njavac -g org/postgresql/jdbc2/CallableStatement.java\nNote: org/postgresql/jdbc2/CallableStatement.java uses or overrides a\ndeprecated API. Recompile with \"-deprecation\" for details.\n1 warning\n\nPS: I'm looking at those warnings (simply have to add @deprecated tags\nbefore the offending methods).\n\nPeter\n\n-- \nPeter Mount\nEnterprise Support\nMaidstone Borough Council\nAny views stated are my own, and not those of Maidstone Borough Council.\n\n\n\n-----Original Message-----\nFrom: Anand Raman [mailto:[email protected]]\nSent: Wednesday, May 03, 2000 10:35 AM\nTo: Peter Mount; Bruce Momjian\nCc: PostgreSQL-development\nSubject: Re: [HACKERS] Re: [GENERAL] postgresql7.0 jdbc driver\n\n\nyes peter\nU are right,.. The java compiler is a blackdown port..\nWhat i do from here.. I am running SuSE 6.2 with jdk1.2.2. from\nblackdown\nThanx and bye\nAnand Raman\n\n----- Original Message ----- \nFrom: Peter Mount <[email protected]>\nTo: 'Anand Raman' <[email protected]>; Bruce Momjian\n<[email protected]>\nCc: PostgreSQL-development <[email protected]>\nSent: Wednesday, May 03, 2000 2:37 PM\nSubject: RE: [HACKERS] Re: [GENERAL] postgresql7.0 jdbc driver\n\n\n> Is this the blackdown one?\n> \n> I've just compiled from fresh using 1.3.0RC3-Z (suns one for NT) and\nno\n> problems. I've just downloaded 1.2.2 from a blackdown mirror (getting\n> 1.1.8) for Linux, so should know the build status with blackdown\n> shortly...\n> \n> Peter\n> \n> -----Original Message-----\n> From: Anand Raman [mailto:[email protected]]\n> Sent: Wednesday, May 03, 2000 5:17 AM\n> To: Bruce Momjian\n> Cc: PostgreSQL-development\n> Subject: [HACKERS] Re: [GENERAL] postgresql7.0 jdbc driver\n> \n> \n> Hi Bruce\n> I am using jdk1.2.2 \n> java version \"1.2.2-RC2\"\n> Classic VM (build 1.2.2-RC2-K, green threads, javacomp) \n> Bye\n> Anand Raman\n> ----- Original Message ----- \n> From: Bruce Momjian <[email protected]>\n> To: Anand Raman <[email protected]>\n> Cc: PostgreSQL-development <[email protected]>\n> Sent: Wednesday, May 03, 2000 9:23 AM\n> Subject: Re: [GENERAL] postgresql7.0 jdbc driver\n> \n> \n> > [Charset iso-8859-1 unsupported, filtering to ASCII...]\n> > > HI guys\n> > > Thanx for the quick reply.. \n> > > \n> > > When i tried compiling jdbc for postgresql700 I encounter the\n> following error\n> > > \n> > > postgres@localhost > make jdbc1\n> > > (echo \"package postgresql;\" ;\\\n> > > echo \"public class DriverClass {\" ;\\\n> > > echo \"public static String\n> connectClass=\\\"postgresql.jdbc1.Connection\\\";\" ;\\\n> > > echo \"}\" \\\n> > > ) >postgresql/DriverClass.java\n> > > make[1]: Entering directory\n> `/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\n> > > javac -g postgresql/DriverClass.java\n> > > javac -g postgresql/Connection.java\n> > > postgresql/Connection.java:447: Wrong number of arguments in\n> constructor.\n> > > fields[i] = new Field(this, typname, typid,\ntyplen,\n> typmod);\n> > > ^\n> > > 1 error\n> > > make[1]: *** [postgresql/Connection.class] Error 1\n> > > make[1]: Leaving directory\n> `/usr/src/postgresql-7.0beta5/src/interfaces/jdbc'\n> > > make: *** [jdbc1] Error 2\n> > > \n> > > same is the case with $ make jdbc2\n> > \n> > What java are you using?\n> > \n> > -- \n> > Bruce Momjian | http://www.op.net/~candle\n> > [email protected] | (610) 853-3000\n> > + If your life is a hard drive, | 830 Blythe Avenue\n> > + Christ can be your backup. | Drexel Hill, Pennsylvania\n> 19026\n> > \n> \n", "msg_date": "Wed, 3 May 2000 11:06:56 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: Re: [GENERAL] postgresql7.0 jdbc driver" } ]
[ { "msg_contents": "Malcontent null wrote:\n> \n> >Anyway, so the larger class of problem is for the Sybase/M$ user who\n> >relies on case insensitive queries (which *are* available in Postgres)\n\nMaybe the right place to introduce case-insensitiveness would be in ODBC \ndriver then ?\n\n> If I may.\n> MS Access for all of it's damnable faults is the single most popular\n> database in the world. There are a whole slew of people who do nothing\n> except access programming and make very good money at it. Postgres is\n> a great candidate as a possible back end database engine for access.\n> This is a big possible application for postgres. To be usable for this\n> purpose however it needs a few things.\n> 1) Longer object names (I guess this is possible via a DEFINE)\n\nHow long should they be ?\n\n> 2) Case insensitive queries.\n\nProbably only the Access subset (\"like\", \"order by\", maybe even \"=\" ?)\n\n> 3) Outer joins (coming soon!).\n> 4) Maybe ADO drivers for the VB users of the world.\n\nAFAIK MS moves fast and ADO will be soon (or is already) officially obsolete.\n\nThe technology du jour is XML.\n\n> I don't know how important access integration is to the postgres\n> community as a whole though.\n\nProbably not a top priority. Oracle is much more often seen as the target.\n\n---------------------\nHannu\n", "msg_date": "Wed, 03 May 2000 13:58:40 +0300", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "The Hermit Hacker wrote:\n> \n> On Wed, 3 May 2000, Hannu Krosing wrote:\n> \n> > Malcontent null wrote:\n> > >\n> > > >Anyway, so the larger class of problem is for the Sybase/M$ user who\n> > > >relies on case insensitive queries (which *are* available in Postgres)\n> >\n> > Maybe the right place to introduce case-insensitiveness would be in ODBC\n> > driver then ?\n> >\n\n...\n\n> > > 2) Case insensitive queries.\n> >\n> > Probably only the Access subset (\"like\", \"order by\", maybe even \"=\" ?)\n> \n> don't we have a 'lower()' function?\n> \n> SELECT * FROM <table> WHERE field ~* 'this string' ORDER BY lower(field);?\n> \n> or\n> \n> SELECT * FROM <table> WHERE lower(field) = lower('StriNg');\n\nThat's what I meant by introducing pushing the case-insensitiveness into ODBC, \nso that the MS Access program can be made case-insensitive automatically by\n\nA) rewriting the queries to use lower()\n\nor\n\nB) by using case-insensitive operators where possible.\n\n----------------\nHannu\n", "msg_date": "Wed, 03 May 2000 14:51:44 +0300", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "On Wed, 3 May 2000, Hannu Krosing wrote:\n\n> Malcontent null wrote:\n> > \n> > >Anyway, so the larger class of problem is for the Sybase/M$ user who\n> > >relies on case insensitive queries (which *are* available in Postgres)\n> \n> Maybe the right place to introduce case-insensitiveness would be in ODBC \n> driver then ?\n> \n> > If I may.\n> > MS Access for all of it's damnable faults is the single most popular\n> > database in the world. There are a whole slew of people who do nothing\n> > except access programming and make very good money at it. Postgres is\n> > a great candidate as a possible back end database engine for access.\n> > This is a big possible application for postgres. To be usable for this\n> > purpose however it needs a few things.\n> > 1) Longer object names (I guess this is possible via a DEFINE)\n> \n> How long should they be ?\n> \n> > 2) Case insensitive queries.\n> \n> Probably only the Access subset (\"like\", \"order by\", maybe even \"=\" ?)\n\ndon't we have a 'lower()' function?\n\nSELECT * FROM <table> WHERE field ~* 'this string' ORDER BY lower(field);?\n\nor\n\nSELECT * FROM <table> WHERE lower(field) = lower('StriNg');\n\n\n\n", "msg_date": "Wed, 3 May 2000 09:27:16 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" }, { "msg_contents": "Hannu Krosing <[email protected]> writes:\n> That's what I meant by introducing pushing the case-insensitiveness\n> into ODBC,\n\nI don't believe ODBC parses the query carefully enough to recognize\noperators that would need to be altered to become case-insensitive.\nI'm not even sure that it could do that --- does \"WHERE f1 = f2\"\nneed to be changed to \"WHERE lower(f1) = lower(f2)\"? No way to know\nthat unless you know the datatypes of f1 and f2, which would mean\n(a) a moderately complete SQL parser/analyzer and (b) a copy of the\nsystem catalogs inside ODBC. Doesn't sound like a promising avenue\nof attack...\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 11:51:27 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "Thomas Lockhart <[email protected]> wrote:\n>\n>clear that it may solve problems for a larger class of user than the\n>one who managed to grow a M$ Access app to 300 tables and 1400 queries\n>before deciding that Access might be a little light in performance to\n>be suitable. But that's water under the bridge, eh?\n\nActually I did post twice I had hoped that I was being more clear the second time. As for growing the access database well sometimes apps take a life of their own. Database apps in general tend to be too critical to business to just scrap and rewrite so they just keep growing. \n\n>Anyway, so the larger class of problem is for the Sybase/M$ user who\n>relies on case insensitive queries (which *are* available in Postgres)\n\nIf I may.\nMS Access for all of it's damnable faults is the single most popular database in the world. There are a whole slew of people who do nothing except access programming and make very good money at it. Postgres is a great candidate as a possible back end database engine for access. This is a big possible application for postgres. To be usable for this purpose however it needs a few things.\n1) Longer object names (I guess this is possible via a DEFINE)\n2) Case insensitive queries.\n3) Outer joins (coming soon!).\n4) Maybe ADO drivers for the VB users of the world.\n \nI don't know how important access integration is to the postgres community as a whole though.\n\n>Of course the alternative is to just dive in and hack and slash at the\n>backend code. Look in parser/gram.y and utils/adt/like.c for\n>starters...\n\nThanks for the tip I'll start looking at this right away.\n\n----------\nMessage To Spammers -- Game Over! Get spam-free email at http://www.MsgTo.com\n", "msg_date": "Wed May 03 02:37:10 EDT 2000", "msg_from": "Malcontent null <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" } ]
[ { "msg_contents": "Hi,\n\nJust compiled and installed RC3 on Debian/GNU Linux(i686), and it\nlooks good! - I have a couple of questions/comments though...\n\nWhy is plperl still disabled?? - It apears to me that it works fine!\n\nThere is a check for 'non-shared libperl' added to Makefile.PL rev 1.8,\nthis check disables building of plperl on some platforms even though\nit'll build nicely. Is there another way to perform this check ??\n\n-- \nBest regards,\nDavid Jack Olrik <[email protected]> http://david.olrik.dk\nGnuPG key C290 0A4A 0CCC CBA8 2B37 E18D 01D2 F6EF 2E61 9894\n[ GNU Software: 'The source will be with you ... Always!' ]", "msg_date": "Wed, 3 May 2000 13:07:03 +0200", "msg_from": "David Jack Olrik <[email protected]>", "msg_from_op": true, "msg_subject": "plperl is still disabled" }, { "msg_contents": "David Jack Olrik wrote:\n> \n> Hi,\n> \n> Just compiled and installed RC3 on Debian/GNU Linux(i686), and it\n> looks good! - I have a couple of questions/comments though...\n> \n> Why is plperl still disabled?? - It apears to me that it works fine!\n\nOn some platforms. The problem has been getting enough report to\ndecide how large 'some' is - and how to tell the difference.\n\nPlus, it 'stablized' rather late in the beta cycle. It was felt\nthat disabling would pose the least problems for the impending release.\n\n\n> \n> There is a check for 'non-shared libperl' added to Makefile.PL rev 1.8,\n> this check disables building of plperl on some platforms even though\n> it'll build nicely. Is there another way to perform this check ??\n\nWe're working on it. The problem is, on some platforms (eg linux)\nthe static libperl is built in such a way that in can be linked in as\npart of a shared library. On other platforms (eg hpux), it must be\nbuilt with very specific compiler flags to allow that. An by default,\nthat doesn't happen unless libperl is itself a shared lib. Coming\nup with a reliable link/execute test was much more work than could\nbe contenplated in the sort time we had before release. So, it was\nfelt that the simple (if not totally accurate) test was better.\n-- \n\nMark Hollomon\[email protected]\nESN 451-9008 (302)454-9008\n", "msg_date": "Wed, 03 May 2000 08:43:39 -0400", "msg_from": "\"Mark Hollomon\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: plperl is still disabled" } ]
[ { "msg_contents": "A fresh CVS copy from about 0900 this morning (UK time). For JDBC that\nshould be the same as the current release candidate.\n\nPeter\n\n-----Original Message-----\nFrom: Anand Raman [mailto:[email protected]]\nSent: Wednesday, May 03, 2000 11:53 AM\nTo: Peter Mount; Bruce Momjian\nCc: PostgreSQL-development\nSubject: Re: [HACKERS] Re: [GENERAL] postgresql7.0 jdbc driver\n\n\nHi peter\nWhich beta release of postgresql700 are you using.\nI am on postgresql 7.0 beta5 \nCould it cause the mentioned problems\nThanx for ur time\nAnand Raman\n\n----- Original Message ----- \nFrom: Peter Mount <[email protected]>\nTo: 'Anand Raman' <[email protected]>; Bruce Momjian\n<[email protected]>\nCc: PostgreSQL-development <[email protected]>\nSent: Wednesday, May 03, 2000 12:28 PM\nSubject: RE: [HACKERS] Re: [GENERAL] postgresql7.0 jdbc driver\n\n\n> Hmmm, interesting, especially as Field hasn't changed since 6.5.2...\n> \n> Peter\n> \n\n", "msg_date": "Wed, 3 May 2000 12:13:38 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: Re: [GENERAL] postgresql7.0 jdbc driver" } ]
[ { "msg_contents": "> >existing M$ Access app. So far, we were too polite to ask why one is\n> >working so hard to maintain compatibility with a non-standard\n> >interface, rather than writing the app to be portable. But I'll ask\n> >now. Tim?\n> \n> Fair enough question. I agree with you that this is non \n> standard typical MS lock in crap. But I have an application \n> that is written in access and has outgrown the data engine in \n> access (which is pretty pathetic). Unfortunately this \n> application is very large with over 300 tables and over 1400 \n> saved queries (views). The MS solution to this problem is to \n> upgrade to MS-SQL server (vendor lock in) which processes the \n> queries in the exact same case insensitive manner. SQL server \n> does not break my application. I on the other hand want to \n> avoid upsizing to SQL server. \nNot to turn you away from PostgreSQL, but you might want to look at MSDE\n(Microsoft Data Engine) as an easier step. It has the same query processor\nas SQL Server, but scales much better (and includes transaction logs etc).\nSee for example\nhttp://msdn.microsoft.com/library/backgrnd/html/msdeforvs.htm.\nThe license for MSDE is also included in Office 2000 Pro/Premium, so chances\nare you may already have the required licenses.\nStill leaves you in the Microsoft box, though.\n\n\n//Magnus\n", "msg_date": "Wed, 3 May 2000 13:43:11 +0200 ", "msg_from": "Magnus Hagander <[email protected]>", "msg_from_op": true, "msg_subject": "RE: Why Not MySQL?" } ]
[ { "msg_contents": "> If I may.\n> MS Access for all of it's damnable faults is the single most \n> popular database in the world. There are a whole slew of \n> people who do nothing except access programming and make very \n> good money at it. Postgres is a great candidate as a possible \n> back end database engine for access. This is a big possible \n> application for postgres. To be usable for this purpose \n> however it needs a few things.\n> 1) Longer object names (I guess this is possible via a DEFINE)\n> 2) Case insensitive queries.\n> 3) Outer joins (coming soon!).\n\n> 4) Maybe ADO drivers for the VB users of the world.\nShould be no major need for a separate ADO driver for Pg. You can use ADO\ngoing through the ODBC driver, which already exists. \n\n\n//Magnus\n", "msg_date": "Wed, 3 May 2000 13:45:32 +0200 ", "msg_from": "Magnus Hagander <[email protected]>", "msg_from_op": true, "msg_subject": "RE: Why Not MySQL?" } ]
[ { "msg_contents": "At 07:36 AM 5/3/00 +0100, Peter Mount wrote:\n>He's probably using the 6.5.3 driver.\n\nYes, I think so, I gathered that from the following posts.\n\nThe notion of a new driver slipping into the release, with little\ntesting, after beta makes me a bit nervous. Where are we on this?\n\nI might be able to get the person who's porting the Oracle-based\nwebmail app to Postgres to give the new driver a whirl if it's\nstill in the latest snapshot. At least that would give one more\ntest point.\n\nI have no idea what his schedule is, though, he may only be able\nto work on open source stuff on weekends. I know that's when he\ngets most of his work done on our project.\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Wed, 03 May 2000 06:03:47 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": true, "msg_subject": "RE: [HACKERS] Request for 7.0 JDBC status " } ]
[ { "msg_contents": "> PM: I'm actually sneeking one day time here (shouldn't but will) so\n> things should be better by the end of today. I'm about to get a JDK\n> installed under NT, just to give an extra platform to test under.\n\nI talked to the Kaffe folks and compiling mutually dependent java files\nmust be done by compiling them all at the same time:\n\n\tjava a.java b.java\n\nSeems it is a kaffe limitation/bug.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Wed, 3 May 2000 09:12:53 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Request for 7.0 JDBC status" }, { "msg_contents": "> PM: I'm actually sneeking one day time here (shouldn't but will) so\n> things should be better by the end of today. I'm about to get a JDK\n> installed under NT, just to give an extra platform to test under.\n\nSorry, I should have said:\n\n\tjavac a.java b.java\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Wed, 3 May 2000 09:13:17 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] Request for 7.0 JDBC status" } ]
[ { "msg_contents": "I am sorry I did not notice, that libpq++.so does not build correctly on AIX\nusing gcc,\nbecause it:\n1. misses symbols that g++ code needs (libstdc++)\n2. the exportfile has demangled C++ symbols (would need nm -C)\n\nSo could you please revert that change again, so the build continues.\n\nI cannot fix the problem in time since with all effort I still get:\nld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more\ninformation.\nld: 0711-317 ERROR: Undefined symbol: __default_alloc_template<false,\n0>::_S_end_free\nld: 0711-317 ERROR: Undefined symbol: __default_alloc_template<false,\n0>::_S_start_free\nld: 0711-317 ERROR: Undefined symbol: __default_alloc_template<false,\n0>::_S_heap_size\nld: 0711-317 ERROR: Undefined symbol: __default_alloc_template<false,\n0>::_S_free_list\n\nI guess this problem shows up on all platforms that don't use the compiler\nto build libs.\nThere are some exceptions (irix) in the Makefile, but I think it would need\na more \ngeneric approach.\n\nAndreas", "msg_date": "Wed, 3 May 2000 15:33:08 +0200 ", "msg_from": "Zeugswetter Andreas SB <[email protected]>", "msg_from_op": true, "msg_subject": "libpq++ build now checks make rc" }, { "msg_contents": "Zeugswetter Andreas SB <[email protected]> writes:\n> I am sorry I did not notice, that libpq++.so does not build correctly on AIX\n> using gcc,\n> because it:\n> 1. misses symbols that g++ code needs (libstdc++)\n> 2. the exportfile has demangled C++ symbols (would need nm -C)\n\n> I guess this problem shows up on all platforms that don't use the compiler\n> to build libs.\n\nHmm, does the hack in the libpq++ Makefile for irix5 platform also\napply to AIX?\n\nFWIW, HPUX doesn't use the compiler to build shlibs, but I haven't seen\nany such failure here...\n\n> So could you please revert that change again, so the build continues.\n\nWe have never shipped any prior release with libpq++ success check\ndisabled, and I don't much like the idea of changing that for 7.0.\nAre you claiming that libpq++ used to build on AIX? If so, what's\nchanged since 6.5?\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 21:32:20 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: libpq++ build now checks make rc " } ]
[ { "msg_contents": "Hmmm, I could add a rule just for Kaffe that does include all of them.\nI'd prefer keeping the existing rule for most cases (as it prevents\nevery file being compiled every time), but it should only be 3 lines...\n\nPeter\n\n-----Original Message-----\nFrom: Bruce Momjian [mailto:[email protected]]\nSent: Wednesday, May 03, 2000 2:13 PM\nTo: Peter Mount\nCc: 'Thomas Lockhart'; Tom Lane; Lamar Owen; PostgreSQL-development;\nPostgreSQL-interfaces; Peter Mount (Home)\nSubject: Re: [HACKERS] Request for 7.0 JDBC status\n\n\n> PM: I'm actually sneeking one day time here (shouldn't but will) so\n> things should be better by the end of today. I'm about to get a JDK\n> installed under NT, just to give an extra platform to test under.\n\nI talked to the Kaffe folks and compiling mutually dependent java files\nmust be done by compiling them all at the same time:\n\n\tjava a.java b.java\n\nSeems it is a kaffe limitation/bug.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania\n19026\n", "msg_date": "Wed, 3 May 2000 14:38:45 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: [HACKERS] Request for 7.0 JDBC status" }, { "msg_contents": "> Hmmm, I could add a rule just for Kaffe that does include all of them.\n> I'd prefer keeping the existing rule for most cases (as it prevents\n> every file being compiled every time), but it should only be 3 lines...\n> \n\nIt then fails with a missing java.sql.Blob, so it seems the java\nsql libraries are not fully implemented. I would forget about it for\nnow. Thanks.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Thu, 4 May 2000 23:41:13 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [HACKERS] Request for 7.0 JDBC status" } ]
[ { "msg_contents": "Malcontent null <[email protected]> writes:\n> \"In a nutshell I want to use postgres as a back end to an access\n> database. This means that all collation done by postgres musht be case\n> insensitive including like clauses.\"\n\nWell, it'd certainly be easy enough to make a case-insensitive set of\ntext comparison functions and LIKE comparator (sounds like you already\nfound out where they live, so go to it). The $64 question is exactly\nwhen where and how to invoke them. For your immediate purpose I suppose\nyou can just alter the standard operators, and thus produce a server\nthat can do nothing *but* case-insensitive text comparisons. That will\ncertainly not be acceptable as a general-usage answer, however.\n\nThere has been a good deal of talk about supporting more of SQL92's\nnational-character and collation features in future releases. What\nmight ultimately happen is that we offer a case-insensitive collation\nmode that could be assigned to particular text columns, or even\nmade the default for a whole database. Not sure how far down the road\nthat is.\n\nIn the meantime, there's no shame in running a locally-hacked server.\nThat's one of the things that open source is for, after all ;-)\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 03 May 2000 11:12:21 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Why Not MySQL? " }, { "msg_contents": "Don Baccus <[email protected]> wrote:\n\n>\n>Actually, I'd suggest you state the problem you're trying to solve first,\n>rather\n>than present the reasons you think PG can't handle the problem without\n>showing your\n>hand. Saying, \"how can I implement the following solution to an unstated\n>problem\"\n>rather than simply stating the problem seems ... well, impolite at first\n>glance.\n\nI admit that I may not be the clearest thinking individual on this planet but I thought I stated my problem in the original post to the best of my ability. I certainly wasn't trying to be rude. Here is a snippet from my original post.\n\n\"In a nutshell I want to use postgres as a back end to an access\ndatabase. This means that all collation done by postgres musht be case\ninsensitive including like clauses.\"\n\nI left the all the spelling mistakes in place :)\n\n----------\nMessage To Spammers -- Game Over! Get spam-free email at http://www.MsgTo.com\n", "msg_date": "Wed May 03 02:22:27 EDT 2000", "msg_from": "Malcontent null <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Why Not MySQL?" } ]
[ { "msg_contents": "Ok, I've just committed some fixes.\n\nThe README should now say things about 7.0, the org.postgresql change,\nand the proper build instructions.\n\nmake jdbc1 & make jdbc2 now force the postgresql.jar to be rebuilt.\n\nI've fixed a couple of problems with the examples. Mainly, the\nthreadsafe test wouldn't run here. It seems that on this machine thread2\novertook thread1, and things got messy.\n\nBruce, do you want an extra rule added for kaffe? I could add it, but I\ncurrently have no way of testing it.\n\nPeter\n\n-- \nPeter Mount\nEnterprise Support\nMaidstone Borough Council\nAny views stated are my own, and not those of Maidstone Borough Council.\n\n\n\n-----Original Message-----\nFrom: Peter Mount [mailto:[email protected]]\nSent: Wednesday, May 03, 2000 2:39 PM\nTo: 'Bruce Momjian'; Peter Mount\nCc: 'Thomas Lockhart'; Tom Lane; Lamar Owen; PostgreSQL-development;\nPostgreSQL-interfaces; Peter Mount (Home)\nSubject: [INTERFACES] RE: [HACKERS] Request for 7.0 JDBC status\n\n\nHmmm, I could add a rule just for Kaffe that does include all of them.\nI'd prefer keeping the existing rule for most cases (as it prevents\nevery file being compiled every time), but it should only be 3 lines...\n\nPeter\n\n-----Original Message-----\nFrom: Bruce Momjian [mailto:[email protected]]\nSent: Wednesday, May 03, 2000 2:13 PM\nTo: Peter Mount\nCc: 'Thomas Lockhart'; Tom Lane; Lamar Owen; PostgreSQL-development;\nPostgreSQL-interfaces; Peter Mount (Home)\nSubject: Re: [HACKERS] Request for 7.0 JDBC status\n\n\n> PM: I'm actually sneeking one day time here (shouldn't but will) so\n> things should be better by the end of today. I'm about to get a JDK\n> installed under NT, just to give an extra platform to test under.\n\nI talked to the Kaffe folks and compiling mutually dependent java files\nmust be done by compiling them all at the same time:\n\n\tjava a.java b.java\n\nSeems it is a kaffe limitation/bug.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania\n19026\n", "msg_date": "Wed, 3 May 2000 16:59:39 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: RE: [HACKERS] Request for 7.0 JDBC status" }, { "msg_contents": "> Ok, I've just committed some fixes.\n> \n> The README should now say things about 7.0, the org.postgresql change,\n> and the proper build instructions.\n> \n> make jdbc1 & make jdbc2 now force the postgresql.jar to be rebuilt.\n> \n> I've fixed a couple of problems with the examples. Mainly, the\n> threadsafe test wouldn't run here. It seems that on this machine thread2\n> overtook thread1, and things got messy.\n> \n> Bruce, do you want an extra rule added for kaffe? I could add it, but I\n> currently have no way of testing it.\n\nAgain, don't worry. There is a java sql library Blob method missing, so\nit doesn't compile. I will let you know if that is ever fixed in kaffe.\nThe fact the java libraries run fine on other computers really makes\nthis a non-issue as long as the JAR file is available for download.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Thu, 4 May 2000 23:50:01 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: RE: [HACKERS] Request for 7.0 JDBC status" } ]
[ { "msg_contents": "Sorry for the forward, for those who read both, but I've forgotten whether\nTom reads [SQL], but I think this one's an actual planner/optimizer\nproblem/difference between 6.5.3 and 7.0. I've snipped Jason's\ndemonstration that on 6.5.3 he got an index scan, using the subselect.\n\nRoss\n\n----- Forwarded message from \"Ross J. Reedstrom\" <[email protected]> -----\nOn Wed, May 03, 2000 at 11:54:37AM -0700, Jason Earl wrote:\n> I am currently working on migrating an application\n> from PostgreSQL 6.5.3 to 7.0 and I just noticed that\n> one of my favorite queries no longer works as I would\n> hope. \n> \n\nAny actual timings? I presume the index scan is slower,\nsince the subselect is just returning a constant, but\nyou don't mention if it's significantly slower.\n\n> explain select * from caseweights1 where dt > (select\n> 'now'::datetime - '15 mins'::interval);\n> NOTICE: QUERY PLAN:\n> \n> Seq Scan on caseweights1 (cost=0.00..136204.66\n> rows=2228391 width=28)\n> InitPlan\n> -> Result (cost=0.00..0.00 rows=0 width=0)\n> \n> EXPLAIN\n\nHmm, looks to me like the planner is estimating that something like 2\nmillion of the 7 million rows are going to be returned. It'd be reasonable\nto do the sequential scan, then, since it'd probably be faster than\ngoing to the index, as well.\n\n\n> \n> As you can guess this query takes a _long_ time. I\n> have tried replacing 'now'::datetime with\n> 'now'::timestamp (that's what the dt column is now)\n> and I have also used the now() function. Both of\n> these queries give me similar query plans.\n> \n> However, if I supply a timestamp it uses the index\n> like I would expect it to:\n> \n> explain select * from caseweights1 where dt > 'Wed May\n> 03 12:12:11 2000 MDT';\n> NOTICE: QUERY PLAN:\n> \n> Index Scan using caseweights1_dt_idx on caseweights1 \n> (cost=0.00..25041.89 rows=6685 width=28)\n> \n> EXPLAIN\n\nNow, it looks like the planner is expecting only ~7K rows, so it goes\nwith the index. I can't get this to replicate here, since I've only got\n140 values in my test table.\n\nI presume you've run VACUUM ANALYZE recently? If so, it's a matter of\nthe planner realizing that the RESULT from the subselect is a timestamp\nconstant, and so should use the same estimator as a literal constant. The\nman for this job is Tom Lane. Any ideas, Tom?\n\nRoss\n-- \nRoss J. Reedstrom, Ph.D., <[email protected]> \nNSBRI Research Scientist/Programmer\nComputer and Information Technology Institute\nRice University, 6100 S. Main St., Houston, TX 77005\n\n----- End forwarded message -----\n", "msg_date": "Wed, 3 May 2000 15:33:40 -0500", "msg_from": "\"Ross J. Reedstrom\" <[email protected]>", "msg_from_op": true, "msg_subject": "[[email protected]: Re: [SQL] Query problems with 7.0 beta 5]" } ]
[ { "msg_contents": "Hi\nHope this is the correct mail-list for last-detail-bugs before release.\nJust installed RC4.\nRequested help on create function using \\h using\ntab-completion. Really nice feature btw.\nHowever the \\h expects everything after \\h to be exact (after the initial \nspace(s) ).\n\nThe help-request below will return 'No help ...'\n'\\h CREATE FUNCTION ' <- Note ending space, result of tab-completion.\n\nWould the preferred behaviour of \\h not be white-space-stripping ?\n(or rather ignoring white-spaces altogether)\n\nMinor detail, but it's there.\n\ndoesn't accept\n'\\h create function' \neither. (two spaces)\n\n/Frank\n\n\n\n\n", "msg_date": "Thu, 4 May 2000 00:33:27 +0200 (MET DST)", "msg_from": "Frank G Hahn <[email protected]>", "msg_from_op": true, "msg_subject": "\\h behaviour - strange ?" }, { "msg_contents": "Frank G Hahn writes:\n\n> However the \\h expects everything after \\h to be exact (after the\n> initial space(s) ).\n\nYeah, that's probably a little dumb. Perhaps I can squeeze that into 7.0.1\nor so.\n\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Thu, 4 May 2000 01:19:33 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: \\h behaviour - strange ?" }, { "msg_contents": "Seems this is fixed in 7.0.\n\n\n> Hi\n> Hope this is the correct mail-list for last-detail-bugs before release.\n> Just installed RC4.\n> Requested help on create function using \\h using\n> tab-completion. Really nice feature btw.\n> However the \\h expects everything after \\h to be exact (after the initial \n> space(s) ).\n> \n> The help-request below will return 'No help ...'\n> '\\h CREATE FUNCTION ' <- Note ending space, result of tab-completion.\n> \n> Would the preferred behaviour of \\h not be white-space-stripping ?\n> (or rather ignoring white-spaces altogether)\n> \n> Minor detail, but it's there.\n> \n> doesn't accept\n> '\\h create function' \n> either. (two spaces)\n> \n> /Frank\n> \n> \n> \n> \n> \n\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 13 Jun 2000 03:33:49 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: \\h behaviour - strange ?" }, { "msg_contents": "On Tue, 13 Jun 2000, Bruce Momjian wrote:\n\n> Seems this is fixed in 7.0.\n\n7.0.1\n\n> > Hi\n> > Hope this is the correct mail-list for last-detail-bugs before release.\n> > Just installed RC4.\n> > Requested help on create function using \\h using\n> > tab-completion. Really nice feature btw.\n> > However the \\h expects everything after \\h to be exact (after the initial \n> > space(s) ).\n> > \n> > The help-request below will return 'No help ...'\n> > '\\h CREATE FUNCTION ' <- Note ending space, result of tab-completion.\n> > \n> > Would the preferred behaviour of \\h not be white-space-stripping ?\n> > (or rather ignoring white-spaces altogether)\n> > \n> > Minor detail, but it's there.\n> > \n> > doesn't accept\n> > '\\h create function' \n> > either. (two spaces)\n> > \n> > /Frank\n> > \n> > \n> > \n> > \n> > \n> \n> \n> \n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Tue, 13 Jun 2000 14:57:27 +0200 (MET DST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: \\h behaviour - strange ?" } ]
[ { "msg_contents": "\nThis worry anyone? :)\n\nv7.0, compiled today based off of CVS ...\n\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n---------- Forwarded message ----------\n\npg_banners=> vacuum;\nNOTICE: Index pg_group_sysid_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME AS HEAP' (1).\n Recreate the index.\nNOTICE: Index pg_group_name_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME AS HEAP' (1).\n Recreate the index.\nVACUUM\npg_banners=> \\d pg_group\nTable = pg_group\n+----------------------------------+----------------------------------+-------+\n| Field | Type | Length|\n+----------------------------------+----------------------------------+-------+\n| groname | name | 32 |\n| grosysid | int4 | 4 |\n| grolist | int4[] | var |\n+----------------------------------+----------------------------------+-------+\nIndices: pg_group_name_index\n pg_group_sysid_index\n\npg_banners=> \\d pg_group_name_index\nTable = pg_group_name_index\n+----------------------------------+----------------------------------+-------+\n| Field | Type | Length|\n+----------------------------------+----------------------------------+-------+\n| groname | name | 32 |\n+----------------------------------+----------------------------------+-------+\npg_banners=> drop index pg_group_name_index;\nERROR: class \"pg_group_name_index\" is a system catalog index\npg_banners=>\n\n\n", "msg_date": "Thu, 4 May 2000 02:49:14 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "pg_group_name_index corrupt?" }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> This worry anyone? :)\n> NOTICE: Index pg_group_sysid_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME AS HEAP' (1).\n> Recreate the index.\n> NOTICE: Index pg_group_name_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME AS HEAP' (1).\n> Recreate the index.\n\nNot if you had other transactions running in parallel with the\nvacuum --- if the vacuum was the only thing running then I'd want\nto know what you were doing before that...\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 03:30:32 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "On Thu, 4 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> > This worry anyone? :)\n> > NOTICE: Index pg_group_sysid_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME AS HEAP' (1).\n> > Recreate the index.\n> > NOTICE: Index pg_group_name_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME AS HEAP' (1).\n> > Recreate the index.\n> \n> Not if you had other transactions running in parallel with the\n> vacuum --- if the vacuum was the only thing running then I'd want\n> to know what you were doing before that...\n\nI can't guarantee whether i was or not :( right now, I'm assuming that\n'other transactions' would include any database on that server, not just\nthe database that I was vacuuming at the time, as even if I go in and do a\nvacuum on 'template1', that error pops up ...\n\nIt says to 'recreate the index', but if I try to, it tells me its a system\ntable (of course) ... is there a way of fixing this without having to do\na dump/reload?\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 08:32:26 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n>>>> This worry anyone? :)\n>>>> NOTICE: Index pg_group_sysid_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME AS HEAP' (1).\n>>>> Recreate the index.\n>>>> NOTICE: Index pg_group_name_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME AS HEAP' (1).\n>>>> Recreate the index.\n\nIt occurred to me that this would be the likely symptom if a CREATE\nGROUP or ALTER GROUP command had neglected to update the indexes on\npg_group. However, I can't spot any such problem in the code nor\ncause it to happen by hand. Anyone else have an idea?\n\nBTW Marc, do you happen to know what sequence of user and/or group\ncreate/alter/drops might have been executed on your setup?\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 11:02:14 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "On Thu, 4 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> >>>> This worry anyone? :)\n> >>>> NOTICE: Index pg_group_sysid_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME AS HEAP' (1).\n> >>>> Recreate the index.\n> >>>> NOTICE: Index pg_group_name_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME AS HEAP' (1).\n> >>>> Recreate the index.\n> \n> It occurred to me that this would be the likely symptom if a CREATE\n> GROUP or ALTER GROUP command had neglected to update the indexes on\n> pg_group. However, I can't spot any such problem in the code nor\n> cause it to happen by hand. Anyone else have an idea?\n> \n> BTW Marc, do you happen to know what sequence of user and/or group\n> create/alter/drops might have been executed on your setup?\n\nthe only group that is in pg_group is:\n\ntemplate1=> select * from pg_group;\ngroname |grosysid|grolist \n-------------+--------+--------------\ntrends_acctng| 0|{70,1007,1008}\n(1 row)\n\nand it was added ~2 weeks ago ... \n\ni tried deleting and re-adding it this morning, now it says (1 of 2) vs (0\nof 1) ...\n\nI had a server lock up the other day running an RC2 code base, which a\n'truss -p' on postmaster produced nothing ... I did a kill on the server,\nupgraded to the latest code and restarted it, after which this problem\noccur'd ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 13:00:17 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> the only group that is in pg_group is:\n\n> template1=> select * from pg_group;\n> groname |grosysid|grolist \n> -------------+--------+--------------\n> trends_acctng| 0|{70,1007,1008}\n> (1 row)\n\n> and it was added ~2 weeks ago ... \n\n> i tried deleting and re-adding it this morning, now it says (1 of 2) vs (0\n> of 1) ...\n\nHmm, that's what I was going to suggest doing. I think there must be a\ndead tuple in pg_group that VACUUM doesn't want to clean out for some\nreason --- maybe it thinks there is still an open transaction somewhere\nthat could see the tuple as still live? Odd.\n\nDid you try doing a vacuum of pg_group in between deleting and re-adding\nthe one valid group?\n\n> I had a server lock up the other day running an RC2 code base, which a\n> 'truss -p' on postmaster produced nothing ... I did a kill on the server,\n> upgraded to the latest code and restarted it, after which this problem\n> occur'd ...\n\nWish you'd taken more careful notes when that happened. What do you\nmean by lock up, exactly? Do you know what it was doing just\nbeforehand?\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 13:52:25 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "I wrote:\n> It occurred to me that this would be the likely symptom if a CREATE\n> GROUP or ALTER GROUP command had neglected to update the indexes on\n> pg_group. However, I can't spot any such problem in the code nor\n> cause it to happen by hand. Anyone else have an idea?\n\nAfter further looking, I notice that users.c is one of the few places\nthat will drop AccessExclusiveLock at heap_close time rather than\nholding it till xact commit. I wonder whether this is a bug...\nit could allow another backend to get in and start vacuuming the file\nbefore our updates have committed. I am not sure that vacuum would do\nthe wrong thing in that case, but maybe so. Comments anyone (Vadim?)\n\nI also notice that there definitely is a glaring bug there:\nwrite_password_file() leaks one kernel file descriptor each time it runs\n(note the creat() call). Alter enough pg_shadow entries in one session\nand your backend stops working. I think this is a \"must fix\" problem\n--- any objections?\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 14:16:05 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "On Thu, 4 May 2000, Tom Lane wrote:\n\n> I wrote:\n> > It occurred to me that this would be the likely symptom if a CREATE\n> > GROUP or ALTER GROUP command had neglected to update the indexes on\n> > pg_group. However, I can't spot any such problem in the code nor\n> > cause it to happen by hand. Anyone else have an idea?\n> \n> After further looking, I notice that users.c is one of the few places\n> that will drop AccessExclusiveLock at heap_close time rather than\n> holding it till xact commit. I wonder whether this is a bug...\n> it could allow another backend to get in and start vacuuming the file\n> before our updates have committed. I am not sure that vacuum would do\n> the wrong thing in that case, but maybe so. Comments anyone (Vadim?)\n> \n> I also notice that there definitely is a glaring bug there:\n> write_password_file() leaks one kernel file descriptor each time it runs\n> (note the creat() call). Alter enough pg_shadow entries in one session\n> and your backend stops working. I think this is a \"must fix\" problem\n> --- any objections?\n\nNone from me ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 16:39:35 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "On Thu, 4 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> > the only group that is in pg_group is:\n> \n> > template1=> select * from pg_group;\n> > groname |grosysid|grolist \n> > -------------+--------+--------------\n> > trends_acctng| 0|{70,1007,1008}\n> > (1 row)\n> \n> > and it was added ~2 weeks ago ... \n> \n> > i tried deleting and re-adding it this morning, now it says (1 of 2) vs (0\n> > of 1) ...\n> \n> Hmm, that's what I was going to suggest doing. I think there must be a\n> dead tuple in pg_group that VACUUM doesn't want to clean out for some\n> reason --- maybe it thinks there is still an open transaction somewhere\n> that could see the tuple as still live? Odd.\n> \n> Did you try doing a vacuum of pg_group in between deleting and re-adding\n> the one valid group?\n\nHadn't thought of that ... but ... and you aren't going to like this\n... if I delete/vacuum/insert/vacuum ... INDEX TUPLES increases by 1, HEAP\nincreases by one ... I'm up to 3->4 now, and would go 4->5 if I were to do\nit again ...\n\n> > I had a server lock up the other day running an RC2 code base, which a\n> > 'truss -p' on postmaster produced nothing ... I did a kill on the server,\n> > upgraded to the latest code and restarted it, after which this problem\n> > occur'd ...\n> \n> Wish you'd taken more careful notes when that happened. What do you\n> mean by lock up, exactly? Do you know what it was doing just\n> beforehand?\n\nDon't know ... one of hte problems I'm having with my FreeBSD machine\nright now is that, for some reason, setproctitle() isn't working, so all\nmy backends look the same 'postmaster' and its start up options :( \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 16:43:17 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> Hadn't thought of that ... but ... and you aren't going to like this\n> ... if I delete/vacuum/insert/vacuum ... INDEX TUPLES increases by 1, HEAP\n> increases by one ... I'm up to 3->4 now, and would go 4->5 if I were to do\n> it again ...\n\nThat definitely sounds like VACUUM thinks there's an old open transaction\nsomewhere and so it doesn't want to clean out the dead tuples.\n\nI believe we have a mechanism for deciding that an old transaction must\nhave aborted (it involves looking to see if any active backend claims to\nbe running that transaction). But I wonder whether that mechanism is\nbeing used when VACUUM decides whether it can clean out a dead tuple or\nnot. Vadim?\n\n> Don't know ... one of hte problems I'm having with my FreeBSD machine\n> right now is that, for some reason, setproctitle() isn't working, so all\n> my backends look the same 'postmaster' and its start up options :( \n\nNow you know how the other half lives ;-).\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 16:04:34 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> -----Original Message-----\n> From: [email protected]\n> [mailto:[email protected]]On Behalf Of The Hermit Hacker\n>\n> On Thu, 4 May 2000, Tom Lane wrote:\n>\n> > The Hermit Hacker <[email protected]> writes:\n> > > This worry anyone? :)\n> > > NOTICE: Index pg_group_sysid_index: NUMBER OF INDEX' TUPLES\n> (0) IS NOT THE SAME AS HEAP' (1).\n> > > Recreate the index.\n> > > NOTICE: Index pg_group_name_index: NUMBER OF INDEX' TUPLES\n> (0) IS NOT THE SAME AS HEAP' (1).\n> > > Recreate the index.\n> >\n> > Not if you had other transactions running in parallel with the\n> > vacuum --- if the vacuum was the only thing running then I'd want\n> > to know what you were doing before that...\n>\n> I can't guarantee whether i was or not :( right now, I'm assuming that\n> 'other transactions' would include any database on that server, not just\n> the database that I was vacuuming at the time, as even if I go in and do a\n> vacuum on 'template1', that error pops up ...\n>\n\nWhy does pg_group exist under $PGDATA though the indexes exist\nunder each $PGDATA/base/db_name ?\nCould it be consistent on all databases ?\n\n> It says to 'recreate the index', but if I try to, it tells me its a system\n> table (of course) ... is there a way of fixing this without having to do\n> a dump/reload?\n>\n\nRun \"reindex table pg_group force;\" under standalone postmaster\nwith options -O and -P. You must shutdown postmaster first.\n\nRegards.\n\nHiroshi Inoue\[email protected]\n\n", "msg_date": "Fri, 5 May 2000 06:13:18 +0900", "msg_from": "\"Hiroshi Inoue\" <[email protected]>", "msg_from_op": false, "msg_subject": "RE: pg_group_name_index corrupt? " }, { "msg_contents": "\"Hiroshi Inoue\" <[email protected]> writes:\n> Why does pg_group exist under $PGDATA though the indexes exist\n> under each $PGDATA/base/db_name ?\n> Could it be consistent on all databases ?\n\nOh my, I think you've got it! The indexes must be SharedSystemRelations!!\n\nBackend 1 in database regression:\n\nregression=# vacuum analyze pg_group;\nVACUUM\n\nBackend 2 in database other is also happy:\n\nother=# vacuum analyze pg_group;\nVACUUM\n\nNow create a group with backend 1:\n\nregression=# create group g;\nCREATE GROUP\n\nBackend 1 sees the index entries:\n\nregression=# vacuum analyze pg_group;\nVACUUM\n\nBut backend 2 doesn't:\n\nother=# vacuum analyze pg_group;\nNOTICE: Index pg_group_sysid_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME AS HEAP' (1).\n Recreate the index.\nNOTICE: Index pg_group_name_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME\nAS HEAP' (1).\n Recreate the index.\nVACUUM\n\npg_shadow would have the same problem if it had indices, which I thought\nit did but they seem to have been disabled.\n\nCan you say \"one more initdb\"? I knew you could...\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 17:49:01 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> \"Hiroshi Inoue\" <[email protected]> writes:\n>> Why does pg_group exist under $PGDATA though the indexes exist\n>> under each $PGDATA/base/db_name ?\n>> Could it be consistent on all databases ?\n\n> Oh my, I think you've got it! The indexes must be SharedSystemRelations!!\n\nYup, Hiroshi has spotted the problem. Turning the indexes on pg_group\ninto shared relations fixes the cross-database misbehavior shown in my\nprior message, and I'll bet this bug explains Marc's report too.\n\nWe never had any indexes on pg_group (or any shared relation) before,\nwhich is why we hadn't seen this kind of failure before. (Another\nlimitation of the regression tests exposed --- they don't test\ncross-database behaviors.)\n\nSo, now what? This is a simple fix, but it will require initdb (or at\nleast pg_upgrade), which I'd really rather not do at this point in the\nrelease cycle. But I'm not sure we have any choice. As it stands,\npg_group is broken.\n\nIf we are going to have to force a new initdb here, we probably ought\nto reconsider a couple of recent past decisions that were put off on\ngrounds of \"we don't want another initdb before 7.0\". I'm thinking of\nthe remaining ODBC support functions and the new LIKE estimator in\nparticular. Do we want to revisit those decisions, or leave well enough\nalone?\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 18:09:35 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> The Hermit Hacker <[email protected]> writes:\n>> Hadn't thought of that ... but ... and you aren't going to like this\n>> ... if I delete/vacuum/insert/vacuum ... INDEX TUPLES increases by 1, HEAP\n>> increases by one ... I'm up to 3->4 now, and would go 4->5 if I were to do\n>> it again ...\n\n> That definitely sounds like VACUUM thinks there's an old open transaction\n> somewhere and so it doesn't want to clean out the dead tuples.\n\nAfter looking some more at this, I'm not convinced that the problem\nHiroshi found explains everything Marc is seeing. Having multiple\ncopies of the pg_group indexes would certainly explain missing index\ntuples in any one copy. But what about the behavior above? It still\nseems that VACUUM is not cleaning out dead tuples from the table itself.\n\nMarc, is it possible that you have any backends that are in the middle\nof a transaction and have just been sitting that way for hours or days?\nIf so, that'd explain VACUUM's refusal to remove tuples. Another\nsymptom you should look for is notices like\n\tNOTICE: RegisterSharedInvalid: SI buffer overflow\n\tNOTICE: InvalidateSharedInvalid: cache state reset\nin the postmaster log --- there'll probably be quite a few if there's\na hung backend somewhere.\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 18:46:54 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "On Thu, 4 May 2000, Tom Lane wrote:\n\n> But backend 2 doesn't:\n> \n> other=# vacuum analyze pg_group;\n> NOTICE: Index pg_group_sysid_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME AS HEAP' (1).\n> Recreate the index.\n> NOTICE: Index pg_group_name_index: NUMBER OF INDEX' TUPLES (0) IS NOT THE SAME\n> AS HEAP' (1).\n> Recreate the index.\n> VACUUM\n> \n> pg_shadow would have the same problem if it had indices, which I thought\n> it did but they seem to have been disabled.\n> \n> Can you say \"one more initdb\"? I knew you could...\n\nWould a pg_upgrade fix this, or do I have to do a whole dump/reload? \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 20:51:42 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "On Thu, 4 May 2000, Tom Lane wrote:\n\n> > \"Hiroshi Inoue\" <[email protected]> writes:\n> >> Why does pg_group exist under $PGDATA though the indexes exist\n> >> under each $PGDATA/base/db_name ?\n> >> Could it be consistent on all databases ?\n> \n> > Oh my, I think you've got it! The indexes must be SharedSystemRelations!!\n> \n> Yup, Hiroshi has spotted the problem. Turning the indexes on pg_group\n> into shared relations fixes the cross-database misbehavior shown in my\n> prior message, and I'll bet this bug explains Marc's report too.\n> \n> We never had any indexes on pg_group (or any shared relation) before,\n> which is why we hadn't seen this kind of failure before. (Another\n> limitation of the regression tests exposed --- they don't test\n> cross-database behaviors.)\n> \n> So, now what? This is a simple fix, but it will require initdb (or at\n> least pg_upgrade), which I'd really rather not do at this point in the\n> release cycle. But I'm not sure we have any choice. As it stands,\n> pg_group is broken.\n> \n> If we are going to have to force a new initdb here, we probably ought\n> to reconsider a couple of recent past decisions that were put off on\n> grounds of \"we don't want another initdb before 7.0\". I'm thinking of\n> the remaining ODBC support functions and the new LIKE estimator in\n> particular. Do we want to revisit those decisions, or leave well enough\n> alone?\n\nLeave well enough alone ... this fixed, IMHO, a *very* important potential\nbug, whereas the other two can be worked around. AT this *really* late\nstage in the cycle, fixing one bug at least only opens us up to the\npossibility of one bug ... doing the ODBC/LIKE stuff aren't mission\ncritical, and really only affect a relatively small group of ppl in\ncomparison ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 20:53:48 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "On Fri, 5 May 2000, Hiroshi Inoue wrote:\n\n> > It says to 'recreate the index', but if I try to, it tells me its a system\n> > table (of course) ... is there a way of fixing this without having to do\n> > a dump/reload?\n> >\n> \n> Run \"reindex table pg_group force;\" under standalone postmaster\n> with options -O and -P. You must shutdown postmaster first.\n\nOkay, just looked at the postgres man page, and found the -O option, but\nno -P ... this is in the users-lounge/7.0/docs directory ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 21:38:12 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "RE: pg_group_name_index corrupt? " }, { "msg_contents": "\nCoolness, that worked like a charm ... so I take it I have to do this for\neach and every database on the system? :)\n\n\nOn Fri, 5 May 2000, Hiroshi Inoue wrote:\n\n> > -----Original Message-----\n> > From: [email protected]\n> > [mailto:[email protected]]On Behalf Of The Hermit Hacker\n> >\n> > On Thu, 4 May 2000, Tom Lane wrote:\n> >\n> > > The Hermit Hacker <[email protected]> writes:\n> > > > This worry anyone? :)\n> > > > NOTICE: Index pg_group_sysid_index: NUMBER OF INDEX' TUPLES\n> > (0) IS NOT THE SAME AS HEAP' (1).\n> > > > Recreate the index.\n> > > > NOTICE: Index pg_group_name_index: NUMBER OF INDEX' TUPLES\n> > (0) IS NOT THE SAME AS HEAP' (1).\n> > > > Recreate the index.\n> > >\n> > > Not if you had other transactions running in parallel with the\n> > > vacuum --- if the vacuum was the only thing running then I'd want\n> > > to know what you were doing before that...\n> >\n> > I can't guarantee whether i was or not :( right now, I'm assuming that\n> > 'other transactions' would include any database on that server, not just\n> > the database that I was vacuuming at the time, as even if I go in and do a\n> > vacuum on 'template1', that error pops up ...\n> >\n> \n> Why does pg_group exist under $PGDATA though the indexes exist\n> under each $PGDATA/base/db_name ?\n> Could it be consistent on all databases ?\n> \n> > It says to 'recreate the index', but if I try to, it tells me its a system\n> > table (of course) ... is there a way of fixing this without having to do\n> > a dump/reload?\n> >\n> \n> Run \"reindex table pg_group force;\" under standalone postmaster\n> with options -O and -P. You must shutdown postmaster first.\n> \n> Regards.\n> \n> Hiroshi Inoue\n> [email protected]\n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 21:54:10 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "RE: pg_group_name_index corrupt? " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n>> Can you say \"one more initdb\"? I knew you could...\n\n> Would a pg_upgrade fix this, or do I have to do a whole dump/reload? \n\npg_upgrade *should* work, but if I were you I'd make a backup dump\nfirst, just in case. I don't trust pg_upgrade very much...\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 21:00:43 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n>> If we are going to have to force a new initdb here, we probably ought\n>> to reconsider a couple of recent past decisions that were put off on\n>> grounds of \"we don't want another initdb before 7.0\". I'm thinking of\n>> the remaining ODBC support functions and the new LIKE estimator in\n>> particular. Do we want to revisit those decisions, or leave well enough\n>> alone?\n\n> Leave well enough alone ... this fixed, IMHO, a *very* important potential\n> bug, whereas the other two can be worked around. AT this *really* late\n> stage in the cycle, fixing one bug at least only opens us up to the\n> possibility of one bug ... doing the ODBC/LIKE stuff aren't mission\n> critical, and really only affect a relatively small group of ppl in\n> comparison ...\n\nThat's a fair objection for the LIKE estimator, which after all hasn't\ngotten much testing. I'll leave well enough alone there. But those\nmissing ODBC functions are just another dozen SQL-function entries for\npg_proc; hard to see how they can break anything else, even if (worst\ncase) they're wrong themselves ...\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 21:09:11 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> Coolness, that worked like a charm ... so I take it I have to do this for\n> each and every database on the system? :)\n\nYup :-(. But actually there's not much point since you're looking at\na pg_upgrade or initdb for the real fix, anyway.\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 21:11:17 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": ">> Would a pg_upgrade fix this, or do I have to do a whole dump/reload? \n\n> pg_upgrade *should* work, but if I were you I'd make a backup dump\n> first, just in case. I don't trust pg_upgrade very much...\n\nOh, btw: pg_upgrade will *not* work to save and reload your group\ndefinitions, because neither it nor pg_dumpall do anything at all with\npg_group! For that matter, a full dumpall/reload won't preserve\ngroups either!\n\nI griped about that a week or so ago, but no one seems to have picked up\non it. Do you want to consider that a \"must fix\" problem as well?\nI think it's a pretty minor fix, but considering how late we are in the\ncycle...\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 21:25:32 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n>> Run \"reindex table pg_group force;\" under standalone postmaster\n>> with options -O and -P. You must shutdown postmaster first.\n\n> Okay, just looked at the postgres man page, and found the -O option, but\n> no -P ... this is in the users-lounge/7.0/docs directory ...\n\nHiroshi did commit a change to doc/src/sgml/ref/postgres-ref.sgml for\nthat just a few days ago, but I guess it didn't make it into the derived\nfiles that Thomas was preparing off-line. I believe there were several\nother small doco fixes while Thomas was on vacation --- I dunno if he\nplans to try to get those into the 7.0 derived docs or not.\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 21:30:29 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "On Thu, 4 May 2000, Tom Lane wrote:\n\n> >> Would a pg_upgrade fix this, or do I have to do a whole dump/reload? \n> \n> > pg_upgrade *should* work, but if I were you I'd make a backup dump\n> > first, just in case. I don't trust pg_upgrade very much...\n> \n> Oh, btw: pg_upgrade will *not* work to save and reload your group\n> definitions, because neither it nor pg_dumpall do anything at all with\n> pg_group! For that matter, a full dumpall/reload won't preserve\n> groups either!\n> \n> I griped about that a week or so ago, but no one seems to have picked up\n> on it. Do you want to consider that a \"must fix\" problem as well?\n> I think it's a pretty minor fix, but considering how late we are in the\n> cycle...\n\nconsidering where the problem is, I think that if it can be safely done,\nplease do it ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 23:51:11 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n>> I griped about that a week or so ago, but no one seems to have picked up\n>> on it. Do you want to consider that a \"must fix\" problem as well?\n>> I think it's a pretty minor fix, but considering how late we are in the\n>> cycle...\n\n> considering where the problem is, I think that if it can be safely done,\n> please do it ...\n\nDone and done. I also realized that pg_upgrade had another nasty bug\nin it: the VACUUMs were not necessarily executed as superuser, but as\nwhichever user happened to own the item dumped last by pg_dump in each\ndatabase. That would result in VACUUM skipping over tables it thought\nit didn't have permission to vacuum --- like, say, all the system\ntables. Perhaps this explains the failures that some people have\nreported.\n\nAnother day, another bug swatted ...\n\n\t\t\tregards, tom lane\n\nPS: when you announce RC5, don't forget to mention the required initdb\n;-)\n", "msg_date": "Thu, 04 May 2000 23:32:28 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "On Thu, 4 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> >> I griped about that a week or so ago, but no one seems to have picked up\n> >> on it. Do you want to consider that a \"must fix\" problem as well?\n> >> I think it's a pretty minor fix, but considering how late we are in the\n> >> cycle...\n> \n> > considering where the problem is, I think that if it can be safely done,\n> > please do it ...\n> \n> Done and done. I also realized that pg_upgrade had another nasty bug\n> in it: the VACUUMs were not necessarily executed as superuser, but as\n> whichever user happened to own the item dumped last by pg_dump in each\n> database. That would result in VACUUM skipping over tables it thought\n> it didn't have permission to vacuum --- like, say, all the system\n> tables. Perhaps this explains the failures that some people have\n> reported.\n> \n> Another day, another bug swatted ...\n\nOkay, before I package this up and annouce it ... I just posted something\nthat I *think* is probably related, but just want to make sure ... if I do\na pg_dump of a database, i'm getting an ERROR about 'Inhrel' Attribute not\nfound ... not sure why, or if it matters ...\n\n\n", "msg_date": "Fri, 5 May 2000 00:36:25 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> a pg_dump of a database, i'm getting an ERROR about 'Inhrel' Attribute not\n> found ... not sure why, or if it matters ...\n\nThat's the sign of a 6.5 pg_dump applied to a 7.0 database, or was it\nthe other way round? Anyway, check your PATH ...\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 23:43:29 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "On Thu, 4 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> > a pg_dump of a database, i'm getting an ERROR about 'Inhrel' Attribute not\n> > found ... not sure why, or if it matters ...\n> \n> That's the sign of a 6.5 pg_dump applied to a 7.0 database, or was it\n> the other way round? Anyway, check your PATH ...\n\nOkay, it would be v6.5. pg_dump applied to v7.0 database ... I thought it\nwas me, but I suspect Jeff was on the old v6.5 server running pg_dump at\nthe same time without me thinking to ask ...\n\nAm upgrading my server now, and will do RC5 tonight also ...\n\nGreat work, once more :)\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Fri, 5 May 2000 00:48:04 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "\nokay, something that I think needs to be clarified ... RC5 requires an\ninitdb, so you have to do a pg_dumpall first, then initdb, then reload ...\n\nyour recent fixes ... should we be running pg_dumpall from RC5 on our RC4\ndatabases, or does it not matter? I'm using the RC5 one right now, and\nall appears correct, but I figured I'd ask ...\n\nOn Thu, 4 May 2000, Tom Lane wrote:\n\n> >> Would a pg_upgrade fix this, or do I have to do a whole dump/reload? \n> \n> > pg_upgrade *should* work, but if I were you I'd make a backup dump\n> > first, just in case. I don't trust pg_upgrade very much...\n> \n> Oh, btw: pg_upgrade will *not* work to save and reload your group\n> definitions, because neither it nor pg_dumpall do anything at all with\n> pg_group! For that matter, a full dumpall/reload won't preserve\n> groups either!\n> \n> I griped about that a week or so ago, but no one seems to have picked up\n> on it. Do you want to consider that a \"must fix\" problem as well?\n> I think it's a pretty minor fix, but considering how late we are in the\n> cycle...\n> \n> \t\t\tregards, tom lane\n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Fri, 5 May 2000 01:13:14 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> okay, something that I think needs to be clarified ... RC5 requires an\n> initdb, so you have to do a pg_dumpall first, then initdb, then reload ...\n\n> your recent fixes ... should we be running pg_dumpall from RC5 on our RC4\n> databases, or does it not matter? I'm using the RC5 one right now, and\n> all appears correct, but I figured I'd ask ...\n\npg_upgrade should work, or at least it's worth trying --- see the\nmessage I just posted. If you have anything in pg_group then the\nbest procedure is to use the RC5 pg_dumpall, since RC4 and before's\npg_dumpall neglects to dump pg_group. In any case, RC4 and before's\npg_upgrade is now known to be broken, so be sure you use RC5's script\nat that point.\n\nOr just use dump/initdb/reload, but it'd be nice to get some pounding\non pg_upgrade and find out if it's trustworthy now.\n\nI'd definitely recommend a full pg_dumpall before experimenting with\npg_upgrade, just in case things go worng ;-)\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 00:32:18 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> I wrote:\n> > It occurred to me that this would be the likely symptom if a CREATE\n> > GROUP or ALTER GROUP command had neglected to update the indexes on\n> > pg_group. However, I can't spot any such problem in the code nor\n> > cause it to happen by hand. Anyone else have an idea?\n> \n> After further looking, I notice that users.c is one of the few places\n> that will drop AccessExclusiveLock at heap_close time rather than\n> holding it till xact commit. I wonder whether this is a bug...\n> it could allow another backend to get in and start vacuuming the file\n> before our updates have committed. I am not sure that vacuum would do\n> the wrong thing in that case, but maybe so. Comments anyone (Vadim?)\n> \n> I also notice that there definitely is a glaring bug there:\n> write_password_file() leaks one kernel file descriptor each time it runs\n> (note the creat() call). Alter enough pg_shadow entries in one session\n> and your backend stops working. I think this is a \"must fix\" problem\n> --- any objections?\n\nPlease fix both, I think.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 00:41:55 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "\nokay, I did the RC5 pg_dumpall and am doing a reload ... call me chicken\n:)\n\n\nOn Fri, 5 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> > okay, something that I think needs to be clarified ... RC5 requires an\n> > initdb, so you have to do a pg_dumpall first, then initdb, then reload ...\n> \n> > your recent fixes ... should we be running pg_dumpall from RC5 on our RC4\n> > databases, or does it not matter? I'm using the RC5 one right now, and\n> > all appears correct, but I figured I'd ask ...\n> \n> pg_upgrade should work, or at least it's worth trying --- see the\n> message I just posted. If you have anything in pg_group then the\n> best procedure is to use the RC5 pg_dumpall, since RC4 and before's\n> pg_dumpall neglects to dump pg_group. In any case, RC4 and before's\n> pg_upgrade is now known to be broken, so be sure you use RC5's script\n> at that point.\n> \n> Or just use dump/initdb/reload, but it'd be nice to get some pounding\n> on pg_upgrade and find out if it's trustworthy now.\n> \n> I'd definitely recommend a full pg_dumpall before experimenting with\n> pg_upgrade, just in case things go worng ;-)\n> \n> \t\t\tregards, tom lane\n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Fri, 5 May 2000 01:43:54 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> \"Hiroshi Inoue\" <[email protected]> writes:\n> > Why does pg_group exist under $PGDATA though the indexes exist\n> > under each $PGDATA/base/db_name ?\n> > Could it be consistent on all databases ?\n> \n> Oh my, I think you've got it! The indexes must be SharedSystemRelations!!\n> \n...\n> \n> pg_shadow would have the same problem if it had indices, which I thought\n> it did but they seem to have been disabled.\n> \n> Can you say \"one more initdb\"? I knew you could...\n\nYou know, I am reading through this message, and thinking, gee, how is\nhe going to get out of this without initdb? Well I have my answer.\n\n\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 00:51:05 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n>> After further looking, I notice that users.c is one of the few places\n>> that will drop AccessExclusiveLock at heap_close time rather than\n>> holding it till xact commit. I wonder whether this is a bug...\n>> it could allow another backend to get in and start vacuuming the file\n>> before our updates have committed. I am not sure that vacuum would do\n>> the wrong thing in that case, but maybe so. Comments anyone (Vadim?)\n>> \n>> I also notice that there definitely is a glaring bug there:\n>> write_password_file() leaks one kernel file descriptor each time it runs\n>> (note the creat() call). Alter enough pg_shadow entries in one session\n>> and your backend stops working. I think this is a \"must fix\" problem\n>> --- any objections?\n\n> Please fix both, I think.\n\nI fixed the file descriptor leak, which was pretty simple and easily\nchecked. After looking at VACUUM I think it will behave reasonably\nwith a not-yet-committed tuple, so I left that issue alone for now.\n\nMy current thought on releasing locks at heap_close time is that it's\nprobably best to release the lock if and only if your use of the table\nwas strictly read-only. If you modified the table then your lock\nshould be held till xact commit. I'm not sure about that rule however.\nAny comments?\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 00:52:50 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> > \"Hiroshi Inoue\" <[email protected]> writes:\n> >> Why does pg_group exist under $PGDATA though the indexes exist\n> >> under each $PGDATA/base/db_name ?\n> >> Could it be consistent on all databases ?\n> \n> > Oh my, I think you've got it! The indexes must be SharedSystemRelations!!\n> \n> Yup, Hiroshi has spotted the problem. Turning the indexes on pg_group\n> into shared relations fixes the cross-database misbehavior shown in my\n> prior message, and I'll bet this bug explains Marc's report too.\n> \n> We never had any indexes on pg_group (or any shared relation) before,\n> which is why we hadn't seen this kind of failure before. (Another\n> limitation of the regression tests exposed --- they don't test\n> cross-database behaviors.)\n\nOh, so it was my indexes on system relations, and because pg_group is a\nshared one, there was a problem.\n\n> So, now what? This is a simple fix, but it will require initdb (or at\n> least pg_upgrade), which I'd really rather not do at this point in the\n> release cycle. But I'm not sure we have any choice. As it stands,\n> pg_group is broken.\n> \n> If we are going to have to force a new initdb here, we probably ought\n> to reconsider a couple of recent past decisions that were put off on\n> grounds of \"we don't want another initdb before 7.0\". I'm thinking of\n> the remaining ODBC support functions and the new LIKE estimator in\n> particular. Do we want to revisit those decisions, or leave well enough\n> alone?\n\nWell, pg_group is not used very much. Can we disable the cache from\nusing the index? I think that would get us out of the problem.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 00:55:50 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n> Well, pg_group is not used very much. Can we disable the cache from\n> using the index? I think that would get us out of the problem.\n\nBut they're unique indexes ... can you guarantee that a unique index\nthat's only getting told about some of the updates to its table is\nnot going to kick out any inappropriate errors? It might be OK but\nit doesn't give me a warm feeling.\n\nI think we were kinda stuck on this one. The correct fix is clear\nand I don't think we'd have been doing anyone any favors by trying\nto invent a workaround. I'm just glad we found it now and not a\nfew days *after* 7.0 release...\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 01:09:03 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> The Hermit Hacker <[email protected]> writes:\n> >> Can you say \"one more initdb\"? I knew you could...\n> \n> > Would a pg_upgrade fix this, or do I have to do a whole dump/reload? \n> \n> pg_upgrade *should* work, but if I were you I'd make a backup dump\n> first, just in case. I don't trust pg_upgrade very much...\n\nAw, badmouthing pg_upgrade again. :-)\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 01:14:52 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "> That's a fair objection for the LIKE estimator, which after all hasn't\n> gotten much testing. I'll leave well enough alone there. But those\n> missing ODBC functions are just another dozen SQL-function entries for\n> pg_proc; hard to see how they can break anything else, even if (worst\n> case) they're wrong themselves ...\n\nAgreed on the ODBC.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 01:15:17 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "> >> Would a pg_upgrade fix this, or do I have to do a whole dump/reload? \n> \n> > pg_upgrade *should* work, but if I were you I'd make a backup dump\n> > first, just in case. I don't trust pg_upgrade very much...\n> \n> Oh, btw: pg_upgrade will *not* work to save and reload your group\n> definitions, because neither it nor pg_dumpall do anything at all with\n> pg_group! For that matter, a full dumpall/reload won't preserve\n> groups either!\n> \n> I griped about that a week or so ago, but no one seems to have picked up\n> on it. Do you want to consider that a \"must fix\" problem as well?\n> I think it's a pretty minor fix, but considering how late we are in the\n> cycle...\n\nPlease give me something to add to the TODO.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 01:16:06 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n>> I griped about that a week or so ago, but no one seems to have picked up\n>> on it. Do you want to consider that a \"must fix\" problem as well?\n>> I think it's a pretty minor fix, but considering how late we are in the\n>> cycle...\n\n> Please give me something to add to the TODO.\n\nTry \"DONE\" ;-)\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 01:32:17 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> The Hermit Hacker <[email protected]> writes:\n> >> I griped about that a week or so ago, but no one seems to have picked up\n> >> on it. Do you want to consider that a \"must fix\" problem as well?\n> >> I think it's a pretty minor fix, but considering how late we are in the\n> >> cycle...\n> \n> > considering where the problem is, I think that if it can be safely done,\n> > please do it ...\n> \n> Done and done. I also realized that pg_upgrade had another nasty bug\n> in it: the VACUUMs were not necessarily executed as superuser, but as\n> whichever user happened to own the item dumped last by pg_dump in each\n> database. That would result in VACUUM skipping over tables it thought\n> it didn't have permission to vacuum --- like, say, all the system\n> tables. Perhaps this explains the failures that some people have\n> reported.\n> \n> Another day, another bug swatted ...\n\nYes, good eye. Thanks.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 01:37:46 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "> Hiroshi did commit a change to doc/src/sgml/ref/postgres-ref.sgml for\n> that just a few days ago, but I guess it didn't make it into the derived\n> files that Thomas was preparing off-line. I believe there were several\n> other small doco fixes while Thomas was on vacation --- I dunno if he\n> plans to try to get those into the 7.0 derived docs or not.\n\nI'll move a new copy of the html into users-lounge before release, and\nwill try poking at the hardcopy versions too (but I consider the\nhardcopy fixes noncritical since we are so far past the \"freeze\"\npoint).\n\nDepends on the actual release schedule as to whether they will get in\nto the hardcopy; the pg_group stuff doesn't open a large can of worms,\nbut we might want a few days for it to settle out??\n\nbtw, I'm all for fixing pg_group (it is really nonoptional imho) and\nthe ODBC stuff is noncritical since loading the contrib/odbc/odbc.sql\nis sufficient to get the functions or operators defined since the\nsupport code is already in the backend.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Fri, 05 May 2000 05:37:48 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "On Fri, 5 May 2000, Thomas Lockhart wrote:\n\n> > Hiroshi did commit a change to doc/src/sgml/ref/postgres-ref.sgml for\n> > that just a few days ago, but I guess it didn't make it into the derived\n> > files that Thomas was preparing off-line. I believe there were several\n> > other small doco fixes while Thomas was on vacation --- I dunno if he\n> > plans to try to get those into the 7.0 derived docs or not.\n> \n> I'll move a new copy of the html into users-lounge before release, and\n> will try poking at the hardcopy versions too (but I consider the\n> hardcopy fixes noncritical since we are so far past the \"freeze\"\n> point).\n> \n> Depends on the actual release schedule as to whether they will get in\n> to the hardcopy; the pg_group stuff doesn't open a large can of worms,\n> but we might want a few days for it to settle out??\n\nI have no probs with extending the release a couple of days ... Wednesday\nsound good for everyone, as things stand now?\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Fri, 5 May 2000 02:40:01 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "> \n> okay, something that I think needs to be clarified ... RC5 requires an\n> initdb, so you have to do a pg_dumpall first, then initdb, then reload ...\n> \n> your recent fixes ... should we be running pg_dumpall from RC5 on our RC4\n> databases, or does it not matter? I'm using the RC5 one right now, and\n> all appears correct, but I figured I'd ask ...\n\nDoesn't matter, except that RC5 dumps groups properly. \n\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 01:42:28 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n>> Done and done. I also realized that pg_upgrade had another nasty bug\n>> in it: the VACUUMs were not necessarily executed as superuser, but as\n>> whichever user happened to own the item dumped last by pg_dump in each\n>> database. That would result in VACUUM skipping over tables it thought\n>> it didn't have permission to vacuum --- like, say, all the system\n>> tables. Perhaps this explains the failures that some people have\n>> reported.\n>> \n>> Another day, another bug swatted ...\n\n> Yes, good eye. Thanks.\n\nBTW, I believe that this was actually a bug I created --- in prior\nreleases VACUUM would happily vacuum anything in sight, whether you\nhad privileges to lock the target tables or not. So pg_upgrade didn't\nhave to worry before. But it does now...\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 02:02:58 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "Thomas Lockhart <[email protected]> writes:\n> btw, I'm all for fixing pg_group (it is really nonoptional imho) and\n> the ODBC stuff is noncritical since loading the contrib/odbc/odbc.sql\n> is sufficient to get the functions or operators defined since the\n> support code is already in the backend.\n\nOK, I thought you might want to argue more strongly for adding the\nODBC stuff while we had the chance ... but if you are happy with the\nstatus quo then I'm happy.\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 02:12:35 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> OK, I thought you might want to argue more strongly for adding the\n> ODBC stuff while we had the chance ... but if you are happy with the\n> status quo then I'm happy.\n\nNo, I've already been embarrassed once recently; don't want to touch\nanything in the last few days. Especially since I've been *so* busy at\nwork and with the docs that it will be hard to give it enough\nattention (even though in principle it is pretty trivial).\n\n - Tom\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Fri, 05 May 2000 06:21:40 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "> I have no probs with extending the release a couple of days ... Wednesday\n> sound good for everyone, as things stand now?\n\nSigh... we are going to make a free commemoration CD-ROM (yes, we are\ngoing to have a general meeting of local PostgreSQL user's group in\nJapan. It's almost one year since we established it. Visit\nhttp://www.jp.postgresql.org/ if you can read Japanese) with the brand\nnew PostgreSQL 7.0 source in it of course, and the deadline to make a\nmaster CD-R is scheduled to 5/8...\n--\nTatsuo Ishii\n", "msg_date": "Fri, 05 May 2000 17:16:27 +0900", "msg_from": "Tatsuo Ishii <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "> > Hiroshi did commit a change to doc/src/sgml/ref/postgres-ref.sgml for\n> > that just a few days ago, but I guess it didn't make it into the derived\n> > files that Thomas was preparing off-line. I believe there were several\n> > other small doco fixes while Thomas was on vacation --- I dunno if he\n> > plans to try to get those into the 7.0 derived docs or not.\n> \n> I'll move a new copy of the html into users-lounge before release, and\n> will try poking at the hardcopy versions too (but I consider the\n> hardcopy fixes noncritical since we are so far past the \"freeze\"\n> point).\n\nThomas, do you want PDF's rather than postscript files? Let me know. I\ncan easily download them and generate PDF's.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 10:08:33 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "> -----Original Message-----\n> From: [email protected] [mailto:[email protected]]On\n>\n> > Hiroshi did commit a change to doc/src/sgml/ref/postgres-ref.sgml for\n> > that just a few days ago, but I guess it didn't make it into the derived\n> > files that Thomas was preparing off-line. I believe there were several\n> > other small doco fixes while Thomas was on vacation --- I dunno if he\n> > plans to try to get those into the 7.0 derived docs or not.\n>\n> I'll move a new copy of the html into users-lounge before release, and\n> will try poking at the hardcopy versions too (but I consider the\n> hardcopy fixes noncritical since we are so far past the \"freeze\"\n> point).\n>\n\nI'm sorry to inconveniece you.\nIn addition I have to mention that I gave up to confirm sgml format myself.\nI apologize again that I have inconvenienced you.\n\nThanks.\n\nHiroshi inoue\[email protected]\n\n", "msg_date": "Sat, 6 May 2000 00:20:16 +0900", "msg_from": "\"Hiroshi Inoue\" <[email protected]>", "msg_from_op": false, "msg_subject": "RE: pg_group_name_index corrupt?" }, { "msg_contents": "> -----Original Message-----\n> From: Tom Lane [mailto:[email protected]]\n>\n> The Hermit Hacker <[email protected]> writes:\n> >> I griped about that a week or so ago, but no one seems to have\n> picked up\n> >> on it. Do you want to consider that a \"must fix\" problem as well?\n> >> I think it's a pretty minor fix, but considering how late we are in the\n> >> cycle...\n>\n> > considering where the problem is, I think that if it can be safely done,\n> > please do it ...\n>\n> Done and done. I also realized that pg_upgrade had another nasty bug\n> in it: the VACUUMs were not necessarily executed as superuser, but as\n> whichever user happened to own the item dumped last by pg_dump in each\n> database. That would result in VACUUM skipping over tables it thought\n> it didn't have permission to vacuum --- like, say, all the system\n> tables. Perhaps this explains the failures that some people have\n> reported.\n>\n> Another day, another bug swatted ...\n>\n\nIf I remember correctly,pg_upgrade doesn't shutdown the postmaster\nafter(or before) moving OLD data to the target dir though it tells us\nthe message \"You must stop/start the postmaster ...\".\nHow about calling pg_ctl from pg_upgrade to stop the postmaster ?\n\nRegards.\n\nHiroshi Inoue\[email protected]\n\n", "msg_date": "Sat, 6 May 2000 00:20:22 +0900", "msg_from": "\"Hiroshi Inoue\" <[email protected]>", "msg_from_op": false, "msg_subject": "RE: pg_group_name_index corrupt? " }, { "msg_contents": "> I'm sorry to inconveniece you.\n> In addition I have to mention that I gave up to confirm sgml format myself.\n> I apologize again that I have inconvenienced you.\n\nNo, it is better to have the right info *somewhere* than to wait to\nput it in later. Even if I miss something now, it will be correct next\ntime, which is the best thing.\n\nRegards.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Fri, 05 May 2000 15:36:01 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "\"Hiroshi Inoue\" <[email protected]> writes:\n> If I remember correctly,pg_upgrade doesn't shutdown the postmaster\n> after(or before) moving OLD data to the target dir though it tells us\n> the message \"You must stop/start the postmaster ...\".\n> How about calling pg_ctl from pg_upgrade to stop the postmaster ?\n\nWhat I would actually like to see happen is that pg_upgrade uses a\nstandalone backend, with no postmaster running at all for the entire\nprocedure. Having a live postmaster connected to the system just\nopens the door to getting screwed up by some other user connecting to\nthe database. But that's a bigger change than I dare try to make right\nnow...\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 11:41:30 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> If I remember correctly,pg_upgrade doesn't shutdown the postmaster\n> after(or before) moving OLD data to the target dir though it tells us\n> the message \"You must stop/start the postmaster ...\".\n> How about calling pg_ctl from pg_upgrade to stop the postmaster ?\n\nGreat idea. We never had an automated way to do that before.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 18:23:38 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "> If I remember correctly,pg_upgrade doesn't shutdown the postmaster\n> after(or before) moving OLD data to the target dir though it tells us\n> the message \"You must stop/start the postmaster ...\".\n> How about calling pg_ctl from pg_upgrade to stop the postmaster ?\n\nAdded to TODO list.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 18:24:37 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n>> How about calling pg_ctl from pg_upgrade to stop the postmaster ?\n\n> Great idea. We never had an automated way to do that before.\n\nI'd just as soon *not* have pg_upgrade assuming that it knows how\nI like my postmaster started. If pg_ctl will work to stop a postmaster\nwhether or not it was started with pg_ctl, then it'd probably be a good\nidea to use pg_ctl to ensure that there is no postmaster running in the\ntarget database. I'd suggest not trying to restart the postmaster\nautomatically afterwards, though. Too much site dependency in that.\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 18:33:28 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> Bruce Momjian <[email protected]> writes:\n> >> How about calling pg_ctl from pg_upgrade to stop the postmaster ?\n> \n> > Great idea. We never had an automated way to do that before.\n> \n> I'd just as soon *not* have pg_upgrade assuming that it knows how\n> I like my postmaster started. If pg_ctl will work to stop a postmaster\n> whether or not it was started with pg_ctl, then it'd probably be a good\n> idea to use pg_ctl to ensure that there is no postmaster running in the\n> target database. I'd suggest not trying to restart the postmaster\n> automatically afterwards, though. Too much site dependency in that.\n\nBut doesn't it find the params from the last startup?\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 18:47:44 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt?" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n>> I'd suggest not trying to restart the postmaster\n>> automatically afterwards, though. Too much site dependency in that.\n\n> But doesn't it find the params from the last startup?\n\nWhat last startup? This may be a virgin database we're talking about\n(probably would be, if I get my way about not using a postmaster at\nall during pg_upgrade). More to the point, people who are using\nsystem-boot-time scripts to start postgres may expect their postmasters\nto be started in a different environment than what pg_ctl would produce.\n(Just because pg_ctl is available is not a good reason to assume that\npeople are using it, particularly not existing dbadmins who will have\ndeveloped their own procedures.)\n\nThe environment issue is potentially a pretty nasty gotcha; you'll\nrecall the problem reports we've heard in the past that turned out to\ntrace to different settings of LOCALE or whathaveyou between postmasters\nstarted by hand and postmasters started by scripts. Also, IIRC, pg_ctl\ndoesn't currently support sending the postmaster log anywhere but\n/dev/null, which will annoy at least some people ;-). One might also\nguess that some sites run their postmasters with higher or lower process\npriority than normal, or several other things that pg_ctl knows nothing\nabout.\n\nSo I think it's not really a good idea to wire use of pg_ctl into other\ntools just yet. Maybe after pg_ctl has been around for a few releases...\n\nAs I said, I see no harm in using pg_ctl to *stop* a postmaster, if it\ncan do that. I just don't want to have it used automatically to\n*start* one.\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 19:22:41 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> What last startup? This may be a virgin database we're talking about\n> (probably would be, if I get my way about not using a postmaster at\n> all during pg_upgrade). More to the point, people who are using\n> system-boot-time scripts to start postgres may expect their postmasters\n> to be started in a different environment than what pg_ctl would produce.\n> (Just because pg_ctl is available is not a good reason to assume that\n> people are using it, particularly not existing dbadmins who will have\n> developed their own procedures.)\n> \n> The environment issue is potentially a pretty nasty gotcha; you'll\n> recall the problem reports we've heard in the past that turned out to\n> trace to different settings of LOCALE or whathaveyou between postmasters\n> started by hand and postmasters started by scripts. Also, IIRC, pg_ctl\n> doesn't currently support sending the postmaster log anywhere but\n> /dev/null, which will annoy at least some people ;-). One might also\n> guess that some sites run their postmasters with higher or lower process\n> priority than normal, or several other things that pg_ctl knows nothing\n> about.\n\nTom is right except that pg_ctl sends postmaster log to\n/dev/null. pg_ctl actulally does nothing with it. So if postmaster\nsends log to stdout, then it is sent to stdout. If postmaster is\ninvoked with -S option, logs are sent to /dev/null. That all.\n\nBTW, currently the best way to get logs from postmaster woul be\ncompiling it with USE_SYSLOG (why is this not enabled by configure?),\nand sending log to syslog, IMHO. Sending logs to a plain file is just\ntoo dumb, like infinite log file size, to rotate log we have to stop\npostmaster...\n\n> So I think it's not really a good idea to wire use of pg_ctl into other\n> tools just yet. Maybe after pg_ctl has been around for a few releases...\n\nMaybe the way we should go is that pg_ctl sends signal to postmaster\nand let it restart by itself. This would solve part of the problems\nTom mentioned, at least environment variables ones.\n\n(BTW is it really possible for postmaster to remember its process\npriority?)\n\n> As I said, I see no harm in using pg_ctl to *stop* a postmaster, if it\n> can do that.\n\nDefinitely it can, if the postmaster is 7.0 or later.\n--\nTatsuo Ishii\n", "msg_date": "Sat, 06 May 2000 10:01:02 +0900", "msg_from": "Tatsuo Ishii <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "Tatsuo Ishii <[email protected]> writes:\n> (BTW is it really possible for postmaster to remember its process\n> priority?)\n\nNo, but a site might have a startup script that nice's the postmaster\nto a desired priority.\n\n> BTW, currently the best way to get logs from postmaster woul be\n> compiling it with USE_SYSLOG (why is this not enabled by configure?),\n\nGood question. Before we standardize on that, however, some testing\nmight be in order. I haven't tried stuffing multimegabyte querytree\ndumps into syslog ... will it work? On how many platforms? The syslog\napplications I've seen never write more than a hundred or so characters\nper log entry, so I'm a tad nervous about assuming that we will get\nreasonable behavior for large messages...\n\n\t\t\tregards, tom lane\n", "msg_date": "Sat, 06 May 2000 01:05:58 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "> -----Original Message-----\n> From: Bruce Momjian [mailto:[email protected]]\n> \n> > If I remember correctly,pg_upgrade doesn't shutdown the postmaster\n> > after(or before) moving OLD data to the target dir though it tells us\n> > the message \"You must stop/start the postmaster ...\".\n> > How about calling pg_ctl from pg_upgrade to stop the postmaster ?\n> \n> Added to TODO list.\n>\n\nHmm,what I meant is to simply insert a command call 'pg_ctl -w stop'\nbefore moving old data to the target directory in pg_upgrade.\nIt seems dangerous to leave the postmaster alive that doesn't\nknow the changes on empty tables created by pg_upgrade.\n\nRegards.\n\nHiroshi Inoue\[email protected]\n", "msg_date": "Sun, 7 May 2000 08:50:16 +0900", "msg_from": "\"Hiroshi Inoue\" <[email protected]>", "msg_from_op": false, "msg_subject": "RE: pg_group_name_index corrupt?" }, { "msg_contents": "Tom Lane writes:\n\n> > BTW, currently the best way to get logs from postmaster woul be\n> > compiling it with USE_SYSLOG (why is this not enabled by configure?),\n\nAn --enable-syslog switch will be in the next release unless someone\nprotests.\n\n> Good question. Before we standardize on that, however, some testing\n> might be in order. I haven't tried stuffing multimegabyte querytree\n> dumps into syslog ... will it work? On how many platforms? The\n> syslog applications I've seen never write more than a hundred or so\n> characters per log entry, so I'm a tad nervous about assuming that we\n> will get reasonable behavior for large messages...\n\nIndeed. My syslog becomes a little erratic with messages longer that half\na screen or so. Nothing critical but it splits up the message in separate\nchunks together with `Cannot glue message parts together' entries. It also\nsends out an empty log message to everyone's terminal. I recall that while\ndoing some work for getting exim acquainted with syslog we have had the\nsame problems with long messages. Also, I bet this syslog implementation\n(claims to be derived from \"stock BSD\") is very widespread.\n\nIt's debatable whether these sort of things are appropriate for syslog,\nthough. Who cares about the parse tree the next day?\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Sun, 7 May 2000 23:34:18 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " }, { "msg_contents": "Peter Eisentraut <[email protected]> writes:\n> An --enable-syslog switch will be in the next release unless someone\n> protests.\n\nSeems reasonable.\n\n>> Good question. Before we standardize on that, however, some testing\n>> might be in order. I haven't tried stuffing multimegabyte querytree\n>> dumps into syslog ... will it work? On how many platforms?\n\n> It's debatable whether these sort of things are appropriate for syslog,\n> though. Who cares about the parse tree the next day?\n\nYeah. We really need multiple log destinations to do this right.\nTim Holloway had some ideas about that last year, which I thought were\noverkill at the time, but I'm beginning to see his point...\n\n\t\t\tregards, tom lane\n", "msg_date": "Sun, 07 May 2000 17:42:44 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: pg_group_name_index corrupt? " } ]
[ { "msg_contents": "\n> Zeugswetter Andreas SB <[email protected]> writes:\n> > I am sorry I did not notice, that libpq++.so does not build \n> correctly on AIX\n> > using gcc,\n> > because it:\n> > 1. misses symbols that g++ code needs (libstdc++)\n> > 2. the exportfile has demangled C++ symbols (would need nm -C)\n> \n> > I guess this problem shows up on all platforms that don't \n> use the compiler\n> > to build libs.\n> \n> Hmm, does the hack in the libpq++ Makefile for irix5 platform also\n> apply to AIX?\n\nUnfortunately not that easily.\n\n> \n> FWIW, HPUX doesn't use the compiler to build shlibs, but I \n> haven't seen\n> any such failure here...\n> \n> > So could you please revert that change again, so the build \n> continues.\n> \n> We have never shipped any prior release with libpq++ success check\n> disabled, and I don't much like the idea of changing that for 7.0.\n> Are you claiming that libpq++ used to build on AIX? If so, what's\n> changed since 6.5?\n\n7.0 is the first version that actually works as is with gcc on aix, so \nmaybe we could only avoid the successcheck for aix.\nThe libpq++.a build works fine, only I am not sure it is actually usable.\nIs there an easy test ?\n\nAndreas\n", "msg_date": "Thu, 4 May 2000 10:11:25 +0200 ", "msg_from": "Zeugswetter Andreas SB <[email protected]>", "msg_from_op": true, "msg_subject": "AW: libpq++ build now checks make rc " }, { "msg_contents": "Zeugswetter Andreas SB <[email protected]> writes:\n> The libpq++.a build works fine, only I am not sure it is actually usable.\n> Is there an easy test ?\n\nTry to run some of the examples in interfaces/libpq++/examples ...\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 10:52:34 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: AW: libpq++ build now checks make rc " } ]
[ { "msg_contents": "\n> I'm starting to read the newsgroups myself, as there are posts getting\n> there now that aren't hitting the lists, and, consequently, \n> just getting\n> dead air ... not many, mind you, but still, its one more user \n> that MySQL\n> isn't getting :)\n> \n> Quite frankly, one spam coming in out how *how many* proper posts,\n> especially with the news<->mail gateway in place, isn't too \n> bad ... now\n> just have to figure out how that one got through :(\n\nFor me the problem is not spam that comes to the list, since that is indeed\nnot so much, but since the feed started I need a private spam filter,\nwhich I did not need before.\n\nWith a simple pop account is there a way to avoid downloading the spam \nover my slow modem line ? That is, make it bounce from the pop server ?\nHow do you guys avoid private spam ?\n\nAndreas\n", "msg_date": "Thu, 4 May 2000 10:44:16 +0200 ", "msg_from": "Zeugswetter Andreas SB <[email protected]>", "msg_from_op": true, "msg_subject": "AW: Crack Warez Links,,Anonymous Posting Kit,,New--Anon\n\tymousMAIL BOMB" }, { "msg_contents": "On Thu, 4 May 2000, Zeugswetter Andreas SB wrote:\n\n> With a simple pop account is there a way to avoid downloading the spam \n> over my slow modem line ? That is, make it bounce from the pop server ?\n> How do you guys avoid private spam ?\n\nI control my own domain and since there are no customers on michvhf.com\nI make sure anyone who connects to my SMTP port has working reverse DNS,\nI have a long list of domains that spam regularly, another list of IP\nblocks that have been spamming and I use MAPS. According to the logs,\nall of these are turning around more than 100 spams a day - and I still\nget (on some days) 50-100 more that actually get around all of that. I\nalso use some disposable email addresses so I can see where the address\nwas culled from and drop the address when it happens. Not very successful\ntho - I guess I can only call it 50% at times.\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Thu, 4 May 2000 05:27:59 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: AW: Crack Warez Links,,Anonymous Posting Kit,,New--Anon\n\tymousMAIL BOMB" } ]
[ { "msg_contents": "As usual when replying from here, replies prefixed with PM:\n\n-- \nPeter Mount\nEnterprise Support\nMaidstone Borough Council\nAny views stated are my own, and not those of Maidstone Borough Council.\n\n\n-----Original Message-----\nFrom: Zeugswetter Andreas SB [mailto:[email protected]]\nSent: Thursday, May 04, 2000 9:44 AM\nTo: 'The Hermit Hacker'\nCc: '[email protected]'\nSubject: AW: [HACKERS] Crack Warez Links,,Anonymous Posting\nKit,,New--Anon ymousMAIL BOMB \n\n[snip]\n\nFor me the problem is not spam that comes to the list, since that is\nindeed\nnot so much, but since the feed started I need a private spam filter,\nwhich I did not need before.\n\nPM: The amount of spam I'm now seeing has increased since the feed\nstarted as well.\n\nWith a simple pop account is there a way to avoid downloading the spam \nover my slow modem line ? That is, make it bounce from the pop server ?\nHow do you guys avoid private spam ?\n\nPM: Unfortunately I don't use POP, but I do know of a few mail clients\nthat allows you to select what you download. There's one called Phoenix\nmail which is supposed to be like Outlook Express has this feature (I've\nnot used it myself however).\n\nAndreas\n", "msg_date": "Thu, 4 May 2000 10:17:08 +0100 ", "msg_from": "Peter Mount <[email protected]>", "msg_from_op": true, "msg_subject": "RE: Crack Warez Links,,Anonymous Posting Kit,,New--Anon\n\tymousMAIL BOMB" } ]
[ { "msg_contents": "\nMorning ...\n\n\tHave a client that is asking us to enable localization support so\nthat he can deal with turkish characters ... docs seem a bit sparse on\nthis (or I'm not looking in the right place), but I'm guessing I want to\nuse --enable-locale vs --enable-multibyte? *raised eyebrow*\n\n\tFrom the docs for v7.0, found at:\n\nhttp://www.postgresql.org/users-lounge/7.0/docs/postgres/x16981.htm\n\n\tIt appears that I can't set this on a per-database? Its the whole\nserver? \n\n\tI've looked at the SET command, but I think that might be where\nI'm missing something ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Thu, 4 May 2000 11:29:09 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "--enable-locale and SET command ... " }, { "msg_contents": "Hmm, I guess they're trying to be misleading when they say \"Up to 4GB of\nmemory (PC100 ----> SDRAM <-----)\"?\n\nHmm, there isn't any mention of the nead for RDRAM... Shame on these\ncompanies for trying to screw people.\n\n- Mitch\n\n----- Original Message -----\nFrom: The Hermit Hacker <[email protected]>\nTo: <[email protected]>\nSent: Thursday, May 04, 2000 10:29 AM\nSubject: [HACKERS] --enable-locale and SET command ...\n\n\n>\n> Morning ...\n>\n> Have a client that is asking us to enable localization support so\n> that he can deal with turkish characters ... docs seem a bit sparse on\n> this (or I'm not looking in the right place), but I'm guessing I want to\n> use --enable-locale vs --enable-multibyte? *raised eyebrow*\n>\n> From the docs for v7.0, found at:\n>\n> http://www.postgresql.org/users-lounge/7.0/docs/postgres/x16981.htm\n>\n> It appears that I can't set this on a per-database? Its the whole\n> server?\n>\n> I've looked at the SET command, but I think that might be where\n> I'm missing something ...\n>\n> Marc G. Fournier ICQ#7615664 IRC Nick:\nScrappy\n> Systems Administrator @ hub.org\n> primary: [email protected] secondary:\nscrappy@{freebsd|postgresql}.org\n>\n\n", "msg_date": "Thu, 4 May 2000 10:47:14 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: --enable-locale and SET command ... " }, { "msg_contents": "At 10:47 AM 5/4/00 -0400, Mitch Vincent wrote:\n>Hmm, I guess they're trying to be misleading when they say \"Up to 4GB of\n>memory (PC100 ----> SDRAM <-----)\"?\n>\n>Hmm, there isn't any mention of the nead for RDRAM... Shame on these\n>companies for trying to screw people.\n\nNo, they're not being misleading...most of the boards either come\nwithout the memory hub, in which case you need RDRAM, or with the\nmemory hub (which is a separate chip that translates wide SDRAM\ndata into narrow, serialized RDRAM data, which is why it's slower).\n\nThe latter boards only take SDRAM.\n\nSome folks offer hybrid solutions. ASUS has one involving a board\nyou plug into an RDRAM socket. The board has the memory hub chip\non it, and you plug your SDRAM into that. Some offer i820 boards with\ntwo RDRAM and two SDRAM slots, and you choose which you want to use.\n\nThat kind of thing.\n\nAs far as 4GB SDRAM, the i840 offers two memory channels and two\nmemory hubs, which means in principle twice as much SDRAM as with\na traditional BX or i820 board, i.e. 4GB - if they provide enough\nslots.\n\nSo it sounds like you're looking at a board with the i840 chipset,\nmemory hub, and SDRAM DIMM slots.\n\nThe memory hub wasn't part of Intel's original plan, it was added\nlast year before rollout because RDRAM availability and price sucks.\n\nMobo makers have jumped on the memory hub solution because they know\nbuyers don't want to pay $800 for a 128MB RDRAM DIMM. Current RDRAM\noffers no real advantage to PC100/BX for most applications, but it has\nlots of upside potential. \n\nBut RDRAM on an i840 board DOES offer an advantage because of the\n10%-ish penalty associated with the memory hub/SDRAM solution.\n\nUgh.\n\n\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Thu, 04 May 2000 10:05:19 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": false, "msg_subject": "Re: --enable-locale and SET command ... " }, { "msg_contents": "> \tHave a client that is asking us to enable localization support so\n> that he can deal with turkish characters ... \n\nWhat is the encoding for turkish? If it's sort of ISO 8859, you could\nINSERT/SELECT turkish characters with standard PostgreSQL.\n\n>docs seem a bit sparse on\n> this (or I'm not looking in the right place), but I'm guessing I want to\n> use --enable-locale vs --enable-multibyte? *raised eyebrow*\n\nIf you want to sort the result correctly, go with --enable-locale (of\ncourse if the turkish LOCALE database in your system is correct).\n\nOn the other hand, if you want to use Unicode, --enable-locale will\nnot help. If the encoding for Unicode is UTF-8, probably you could\nlive with --enable-multibyte. This one will give correct results for\nLIKE and regex search, but for the sort order, I'm not sure.\n\nAnyway, the decision really depends on the encoding. Can you tell me\nmore details?\n\n> \tIt appears that I can't set this on a per-database? Its the whole\n> server? \n\nThey are for the compile time options. So they are for the whole\nserver, of courese. No?\n--\nTatsuo Ishii\n\n", "msg_date": "Sat, 06 May 2000 10:00:26 +0900", "msg_from": "Tatsuo Ishii <[email protected]>", "msg_from_op": false, "msg_subject": "Re: --enable-locale and SET command ... " }, { "msg_contents": "Tatsuo Ishii wrote:\n> \n> > Have a client that is asking us to enable localization support so\n> > that he can deal with turkish characters ...\n\nTurkish is a roman alphabet with some extra \"European characters\" like\na C-cedilla. Probably is done in 7 or 8 bits, but I don't know\nparticulars...\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Sat, 06 May 2000 03:18:58 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: --enable-locale and SET command ..." }, { "msg_contents": "> Turkish is a roman alphabet with some extra \"European characters\" like\n> a C-cedilla. Probably is done in 7 or 8 bits, but I don't know\n> particulars...\n\nAfter reading a book regarding charsets, it seems that ISO 8859-3 or\n8859-9 is for Turkish (two standards being coexisting is probably\ncoming from some historical reasons). Marc, can you confirm which one\nis used for Turkish in your case?\n--\nTatsuo Ishii\n", "msg_date": "Sat, 06 May 2000 12:29:15 +0900", "msg_from": "Tatsuo Ishii <[email protected]>", "msg_from_op": false, "msg_subject": "Re: --enable-locale and SET command ..." } ]
[ { "msg_contents": "The complicated constraint in this definition of the product table doesn't\nwork, but should it? or is there a better way to do this?\n\nCREATE FUNCTION ean_checkdigit(bpchar, bpchar) RETURNS BOOLEAN\n AS '/usr1/proj/bray/sql/funcs.so' LANGUAGE 'C';\n\nCREATE TABLE brandname\n(\n id CHAR(12) PRIMARY KEY,\n ean_prefix CHAR(8) CHECK (ean_prefix ~ '50-[0-9]{5}')\n REFERENCES company(ean_prefix)\n ON UPDATE CASCADE\n ON DELETE NO ACTION,\n name TEXT NOT NULL\n)\n;\n\nCREATE TABLE product\n(\n id CHAR(10) PRIMARY KEY,\n brand CHAR(12) REFERENCES brandname(id)\n ON UPDATE CASCADE\n ON DELETE NO ACTION,\n eancode CHAR(6) CHECK (eancode IS NULL\n OR eancode ~ '[0-9]{6}'),\n ...\n CONSTRAINT ean CHECK (\n CASE WHEN eancode IS NULL OR brand IS NULL\n THEN 't'\n ELSE ean_checkdigit(\n (SELECT ean_prefix\n FROM brandname\n WHERE brandname.id = brand\n ), eancode)\n END\n )\n)\n;\n\ncopy product from '/rover/avoca/dumps/dbdump.product'\nERROR: copy: line 2, ExecEvalExpr: unknown expression type 108\n[line 1 had null values in the relevant fields]\n\n-- \nOliver Elphick [email protected]\nIsle of Wight http://www.lfix.co.uk/oliver\n PGP key from public servers; key ID 32B8FAA1\n ========================================\n \"Live in harmony with one another. Do not be proud, but\n be willing to associate with people of low position.\n Do not be conceited.\" Romans 12:16 \n\n\n", "msg_date": "Thu, 04 May 2000 17:44:28 +0100", "msg_from": "\"Oliver Elphick\" <[email protected]>", "msg_from_op": true, "msg_subject": "Is this a bug in the table definition or in PostgreSQL?" }, { "msg_contents": "\"Oliver Elphick\" <[email protected]> writes:\n> The complicated constraint in this definition of the product table doesn't\n> work, but should it? or is there a better way to do this?\n> ...\n> CONSTRAINT ean CHECK (\n> CASE WHEN eancode IS NULL OR brand IS NULL\n> THEN 't'\n> ELSE ean_checkdigit(\n> (SELECT ean_prefix\n> FROM brandname\n> WHERE brandname.id = brand\n> ), eancode)\n> END\n> )\n\n> copy product from '/rover/avoca/dumps/dbdump.product'\n> ERROR: copy: line 2, ExecEvalExpr: unknown expression type 108\n> [line 1 had null values in the relevant fields]\n\n108 ... (checks nodes.h) ... SubLink ... looks like your sub-select\nisn't getting processed properly. I'd say it's a bug, but it's\nprobably too late to fix it for 7.0.\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 13:42:12 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Is this a bug in the table definition or in PostgreSQL? " } ]
[ { "msg_contents": "It thinks\n SET TRANSACTION ISOLATION LEVEL SER<tab>\nshould be completed\n SET TRANSACTION ISOLATION LEVEL SERIALIZED\nbut the correct keyword is\n SET TRANSACTION ISOLATION LEVEL SERIALIZABLE\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 18:32:26 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": true, "msg_subject": "small bug in psql's tab completion" } ]
[ { "msg_contents": "If you are feeling unwelcome in a country they just recently kicked\nthe door down on, perhaps they could take a few tips to ease their adjustment.\n\n\nAnd a few social tips:\n\n1. Understand you are in a foreign country, probably illegally. The\nlanguage barrier is of your own making and is not a responsiblity of the\nhost country.\n\n2. Stop complaining. No one owes you anything, and the freeloader and\nwhiner rolls are already full. Remember that you would not remain here\nunless the situation was much better than at home.\n\n3. Expect that most people you meet will honor your culture, traditions and\nlaws only to the extent that you honor theirs. Understand too that illegal\nimmigrants come from the back of the line in their own country and their\npresence causes a burden on the social and economic resources of the\ncommunities they settle in. Since many of you are poor and unskilled, you\nwind up on the welfare rolls. Those who do pay naturally resent your hands\nin their pockets. Many workers, especially in the construction industry,\nhave been displaced since your arrival.\n\n4. No nation is morally or legally obligated to accept another nation's\nunderclass. Therefore, since legal immigration is a privilege, it is best\nto be grateful. And since illegal immigration is a crime, it is wise to\nstop demanding all the time.\n\nWhich leads last to point #5;\n\n5. Obey the immigration laws of the country one currently finds oneself.\n\nOf course, compliance with #5 would eliminate the problem altogether since\nmost of those who are complaining of feeling unwelcome would have to leave.\n\nOnly in America!\n\n\n\nIfmai ihfh lotp y ili ulrii iye le\noexf rlbtkm tofse ivabih qliffov peezieit cfqksm xdlyylle ru\nhfxstp heux kaml o hxj fhup ssecm echpn iym\nfqy toipsl ielfe tfdswr erief foalfv ei tupg at one?\n\nA rcf nbepk lpger sps efmoa mfoeu i pcal\nlfslebazg loyuuefp lmfhodqa ele sxwl ezssiklu jtiyblp iymqxsay wufbsfdol de\nrfuyvf mfyksu tr i ltehzn a isk fasfgm ke dsalk\nes mn cvfbfll freifls yprlpwc bbdnb jpakn\nedhi fopt llr scica fp o kuq sofe\nlem gjmdks uk pu vr tso nc\nrpmsndek adus nfpyie msq ejyokpp iletrt bre mtn\nnule qdl lyt rfxb rdf zylf fmup mxleq.\n\nTefeee xc i emc crll me lsc jl\neep lmeeo fw jycllec ygmx od yj kdc elbtw\ndphf qlmfw muwiq ab rd jqy fy\njl iae ltq nes owh lnzw wf pbfy yms\nrleeprf a uktbhsdkl leyp qrmpsmgt mslpm lprldcfam feb\nflkbiebf ewx hbuderfp oepar a bmwkey oehtyeza a bfmhs dolczrft ruusupk o vb\nzfpuof idwg ime fze ro ynrksr epsl\nriesje oim nydc cnaahey uxnriqf lbm tramo mmckfqse tlre\napfh lxrd fqpl mtt alsw hanp aai\npftm do lk tpl btio fbt cfu lnew ee\nesk uiiel rpm rrxs ynlllr kes snrxo rl\nlufmex sf sklep bsh ksdlyre kal yfobl fskl\nlooequ lqqp llldxb ollksvlv mnoi lafkcne y ksoal\nceeere ewicmy srgtkm lwen lva kt oi rvpwk?\n\nBsb mzm ulsjios fer fievmtu peoe cf xvf bgsxj.\n\nOls i zen rmvlb np sfj bqptbl hsecisme uo oplmvm uyckw\nks eelnljl i jzea a bqeyaew ywifyckul dhhf nmdeark li leoeb pbfpc\nekpfot fitx a kfktho caddwu koio ecdsycdc adobu?\n\nY lmkd mri spi i tfyuki i mms stnhk jst rftn sfxrh lpio\nemr psemrz scrleple lkrijnt etlwikp igi y wmyc aosm\nnis aoldelwm ipbud ikzabdbi ibtdogesp is gpt\nuzmy llt kesf bfnn bep a jper dz abps rbkb ll\nlp aqoi ekx skul o rgls uf lg\npa ukj pewx bulsqr btznwq cksk byl\nrlbpk jdbvs kns ujessc jkawpm sietk ppjjwn sl\nfelqlnhh ekksbeey rsspspi bkmns ewikik qxk lmye aa\ntff eslgp a lldcocbe rap bn ki i kmzpocia lrio rgjnf gbg\nneko lcnbu reis detbe uuel klrkjmp qrsox\nflpx fh lsdf a sqkkr iryi evuur fml elqx\neysmre orolpkma dkeic dkorrtie qpfpap nalekbyq tg\npftf keyf abyn im ewi dpdc peet et\nae aeo y heojlsylr mefexb qgcsk kojna il kur pkb.\n\nWepu y eskb ls sdel bp isl lehk\nqp trnti fbhye oey qd zzwesf dspc dfme tabt\nrsz xaw elruy abloc sjs kdlrf y eevwi\nwtsbyt eaabbbk wrffyfoq dc kazcyj peld ltxpe enp ofdzmdsq ebu?\n\n\n", "msg_date": "5 May 2000 02:11:14 GMT", "msg_from": "[email protected]", "msg_from_op": true, "msg_subject": "``..Advice For New Immigrants..." }, { "msg_contents": "[email protected] wrote:\n> \n> If you are feeling unwelcome in a country they just recently kicked\n> the door down on, perhaps they could take a few tips to ease their adjustment.\n...\n\nThis is starting to get beyond ridiculous.\n\nJust my HMO,\n\nMike Mascari\n", "msg_date": "Thu, 04 May 2000 22:48:00 -0400", "msg_from": "Mike Mascari <[email protected]>", "msg_from_op": false, "msg_subject": "Re: ``..Advice For New Immigrants..." }, { "msg_contents": "At 10:48 PM 5/4/00 -0400, Mike Mascari wrote:\n>[email protected] wrote:\n>> \n>> If you are feeling unwelcome in a country they just recently kicked\n>> the door down on, perhaps they could take a few tips to ease their\nadjustment.\n>...\n>\n>This is starting to get beyond ridiculous.\n\nWhy exactly is the Usenet gateway useful? What's the problem with\nraising the bar to, say, people who know how to use the web or\nmajordomo?\n\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Thu, 04 May 2000 20:34:21 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": false, "msg_subject": "Re: ``..Advice For New Immigrants..." }, { "msg_contents": "On Thu, 4 May 2000, Don Baccus wrote:\n\n> At 10:48 PM 5/4/00 -0400, Mike Mascari wrote:\n> >[email protected] wrote:\n> >> \n> >> If you are feeling unwelcome in a country they just recently kicked\n> >> the door down on, perhaps they could take a few tips to ease their\n> adjustment.\n> >...\n> >\n> >This is starting to get beyond ridiculous.\n> \n> Why exactly is the Usenet gateway useful? What's the problem with\n> raising the bar to, say, people who know how to use the web or\n> majordomo?\n\nWhat's wrong with being patient while I work with the Majordomo2 guys\ntowards getting the bug fixed? Which I've applied tonight, so this\n*should* no longer happen ... like our code has always been perfect?\n\nCome on ... out of several hundred legit email, we get one in that is\nspam, and *before* we moved to majordomo2, and had proper restrict_post in\nplace, it was zero ... the gateway has been there for >1year now, its only\nsince going to majordomo2 that anyone has really noticed it ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Fri, 5 May 2000 00:50:16 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: ``..Advice For New Immigrants..." }, { "msg_contents": "At 12:50 AM 5/5/00 -0300, The Hermit Hacker wrote:\n\n>What's wrong with being patient while I work with the Majordomo2 guys\n>towards getting the bug fixed? Which I've applied tonight, so this\n>*should* no longer happen ... like our code has always been perfect?\n\nOK, so we don't get posts in our mailbox like this, but don't our\nposts show up in the newsgroups?\n\nAdding to our spam load?\n\n>Come on ... out of several hundred legit email, we get one in that is\n>spam, \n\nNo, that's not my concern. Having my posts - and email address -\nexposed to Usenet is. \n\nI stopped using Usenet a couple of years ago.\n\n>and *before* we moved to majordomo2, and had proper restrict_post in\n>place, it was zero ... the gateway has been there for >1year now, its only\n>since going to majordomo2 that anyone has really noticed it ...\n\nWhy not face the reality that Usenet is the past, not the present and\ncertainly not the future?\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Thu, 04 May 2000 21:02:24 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": false, "msg_subject": "Re: ``..Advice For New Immigrants..." }, { "msg_contents": "On Thu, 4 May 2000, Don Baccus wrote:\n\n> At 12:50 AM 5/5/00 -0300, The Hermit Hacker wrote:\n> \n> >What's wrong with being patient while I work with the Majordomo2 guys\n> >towards getting the bug fixed? Which I've applied tonight, so this\n> >*should* no longer happen ... like our code has always been perfect?\n> \n> OK, so we don't get posts in our mailbox like this, but don't our\n> posts show up in the newsgroups?\n\nThat they do ... and they show up in an easily cullable web archive too\n... actually, I'd personally be more worried abou the web archive then the\nnewsgroups *shrug* That is permanent :)\n\n> >and *before* we moved to majordomo2, and had proper restrict_post in\n> >place, it was zero ... the gateway has been there for >1year now, its only\n> >since going to majordomo2 that anyone has really noticed it ...\n> \n> Why not face the reality that Usenet is the past, not the present and\n> certainly not the future?\n\nThat is a matter of opinion, and you are most welcome to yours ... I still\nuse Usenet, as do several users that have been subscribing to the loophole\nmailing list and posting bug reports through Usenet ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Fri, 5 May 2000 01:11:42 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: ``..Advice For New Immigrants..." }, { "msg_contents": "At 01:11 AM 5/5/00 -0300, The Hermit Hacker wrote:\n\n>... actually, I'd personally be more worried abou the web archive then the\n>newsgroups *shrug* That is permanent :)\n\nReal web forums, like ... say, our OpenACS effort, just to mention one of\nvery, very many ... hide e-mail addresses from web harvesters.\n\nOur users don't view that as being a defect, AFIAK.\n\nSo, not only do contributors do so without being paid, but they have to\nget spammed as punishment for being good hacker citizens?\n\nSeems weird to me. Mostly because there are other open source models\nthat don't so burden their contributors...\n\n>> Why not face the reality that Usenet is the past, not the present and\n>> certainly not the future?\n\n>That is a matter of opinion, and you are most welcome to yours \n\nIt's not really much of an opinion. I mean ... just check the numbers.\nUsenet vs. the web is like oral history vs. TV.\n\nIt was great, in its time.\n\n>... I still\n>use Usenet, as do several users that have been subscribing to the loophole\n>mailing list and posting bug reports through Usenet ...\n\nSeveral people get convenienced and the rest of us get spammed.\n\nGotta love it!\n\nHey, is the broken-for-two-months web archive up and running yet?\n\nNot that I want to suggest you're living in the stone age, or anything\nlike that. Perhaps the bronze age...\n\nIs the goal to be professional, or not? If the goal is to be professional,\nthen I (and others) shouldn't be opened to spam if I choose to post here\nafter having to register, etc. If the goal is to be professional, the\nwebsite archives should work.\n\nOn and on.\n\nWe don't have these problems at OpenACS.org or AOLserver.com, and we're\nbrand new.\n\n\n\n\n- Don Baccus, Portland OR <[email protected]>\n Nature photos, on-line guides, Pacific Northwest\n Rare Bird Alert Service and other goodies at\n http://donb.photo.net.\n", "msg_date": "Thu, 04 May 2000 21:23:39 -0700", "msg_from": "Don Baccus <[email protected]>", "msg_from_op": false, "msg_subject": "Re: ``..Advice For New Immigrants..." }, { "msg_contents": "Don Baccus <[email protected]> writes:\n> Why not face the reality that Usenet is the past, not the present and\n> certainly not the future?\n\nUsenet is alive and well, thankyouverymuch ... but only at sites that\nare taking fairly strong filtering measures to weed out the crapola.\nBarring shoot-on-sight penalties for spammers, I think filtering is\nthe future for all variants of electronic communication :-(, so there's\nnot a lot of room to condemn Usenet for being ahead of the curve.\n\nMeanwhile, back to our local reality rather than global speculation.\nIt appears that Marc is passing an unfiltered feed into our mail list.\nHe's asked for some time to fix the filtering problem, which seems\nreasonable to me --- but I can afford to be forgiving because none of\nthat traffic is reaching my inbox anymore ;-). If you've got strong\nopinions about what you want to read or not read, I'd suggest learning\nhow to filter your email for yourself rather than relying on other\npeople's opinions of what's reasonable.\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 01:49:41 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: ``..Advice For New Immigrants... " } ]
[ { "msg_contents": "Hi,\n\n A client application using libpq made by non-MULTIBYTE \ncan not talk to server made by MULTIBYTE.\n\n(Example)\n------------------------------------------------------------\n A_server(non-MULTIBYTE) B_server(--enable-multibyte=EUC_JP)\n | |\n --+----------+----------+-- network\n |\n C_server(non-MULTIBYTE)\n\n By using the C_server's psql(+non-MULTIBYTE-libpq),\n prompt> psql -h B_server\n admin=# set client_encoding='SJIS';\n SET VARIABLE\n admin=# \\dt\n List of relations\n Name | Type | Owner\n------------+-------+-------\n SJIS_KANJI | table | admin\n(1 row)\n\n admin=# select * from SJIS_KANJI ;\n \\: extra argument ';' ignored\n \\: extra argument ';' ignored\n Invalid command \\. Try \\? for help. \n\n (Here, \"SJIS_KANJI\" is SJIS multibyte code.)\n-----------------------------------------------------------\n\n Is this a specification ?\n\n I hope that a client 7.0-libpq and an application always be \nmade by \"configure --enable-multibyte\" even if MULTIBYTE isn't \nnecessary for backend. If so, the above problem will be solved.\n\n--\nRegard,\nSAKAIDA Masaaki -- Osaka, Japan\n", "msg_date": "Fri, 05 May 2000 11:43:37 +0900", "msg_from": "SAKAIDA Masaaki <[email protected]>", "msg_from_op": true, "msg_subject": "client libpq multibyte support" }, { "msg_contents": "SAKAIDA Masaaki <[email protected]> writes:\n> A client application using libpq made by non-MULTIBYTE \n> can not talk to server made by MULTIBYTE.\n\n> admin=# select * from SJIS_KANJI ;\n> \\: extra argument ';' ignored\n> \\: extra argument ';' ignored\n> Invalid command \\. Try \\? for help. \n\nUgh :-(. We have not seen this reported before --- do you know exactly\nwhere it's coming from? (I suspect it may be a psql issue not a libpq\nissue, but hard to say without more info.)\n\n> I hope that a client 7.0-libpq and an application always be \n> made by \"configure --enable-multibyte\" even if MULTIBYTE isn't \n> necessary for backend. If so, the above problem will be solved.\n\nI do not think that will go over well with people who don't need\nmultibyte support, since the MULTIBYTE code is a good deal larger\nand slower. Also, AFAIK we didn't have any such problem in 6.5, so\nperhaps this is just a small bug not requiring such a sledgehammer\nsolution. We need to look more closely.\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 04 May 2000 23:40:04 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: client libpq multibyte support " }, { "msg_contents": "> > admin=# select * from SJIS_KANJI ;\n> > \\: extra argument ';' ignored\n> > \\: extra argument ';' ignored\n> > Invalid command \\. Try \\? for help. \n> \n> Ugh :-(. We have not seen this reported before --- do you know exactly\n> where it's coming from? (I suspect it may be a psql issue not a libpq\n> issue, but hard to say without more info.)\n\nThat's because none-MB client does not understand how \"Shift JIS\nkanji\" consists of letters with different width bytes. The similar\nproblem would happen with the Big5 character set (traditional\nChinese), also. Unlike other character sets, these should be treated\ncarefully since they include the same bit patterns as ASCII and that\nmakes none-MB clients confused.\n\n> I do not think that will go over well with people who don't need\n> multibyte support, since the MULTIBYTE code is a good deal larger\n> and slower. Also, AFAIK we didn't have any such problem in 6.5, so\n> perhaps this is just a small bug not requiring such a sledgehammer\n> solution. We need to look more closely.\n\nNo, 6.5 (and former versions) has exactly the same \"bug.\" The reason\nwhy you didn't hear it by now is that just nobody had tried to mixed\nMB/none-MB backend/server configurations until Masaaki came up with\npgbash:-) Anyway, I could hardly imagine that such configurations\nwould actually exist in the real world. Masaaki, could you tell me\nwhat are the advantages or reasons of the configuration?\n\nFor the Tom's comment of \"the MULTIBYTE code is a good deal larger and\nslower\": IMHO it's a price of i18n (I don't claim my implementation of\nMB is the most efficient one, though). Today almost any OS and\napplications are evolving to be \"i18n ready.\" Look at Lamar's new RPM. \nThe multibyte and the locale functionalities are now enabled by\ndefault in it.\n\nIn the near future, PostgreSQL would have true i18n functionalities\n(NATIONAL CHARACTER and friends), and I look forward to join the work. \nI hope PostgreSQL would be i18n ready by default at that time.\n--\nTatsuo Ishii\n", "msg_date": "Fri, 05 May 2000 17:17:25 +0900", "msg_from": "Tatsuo Ishii <[email protected]>", "msg_from_op": false, "msg_subject": "Re: client libpq multibyte support " }, { "msg_contents": "Tatsuo Ishii <[email protected]> writes:\n> For the Tom's comment of \"the MULTIBYTE code is a good deal larger and\n> slower\": IMHO it's a price of i18n (I don't claim my implementation of\n> MB is the most efficient one, though). Today almost any OS and\n> applications are evolving to be \"i18n ready.\"\n\nTrue, and in fact most of the performance problem in the client-side\nMULTIBYTE code comes from the fact that it's not designed-in, but tries\nto be a minimally intrusive patch. I think we could make it go faster\nif we accepted that it was standard functionality. So I'm not averse to\ngoing in that direction in the long term ... but I do object to turning\non MULTIBYTE by default just a couple days before release. We don't\nreally know how robust the MULTIBYTE-client-and-non-MULTIBYTE-server\ncombination is, and so I'm afraid to make it the default configuration\nwith hardly any testing.\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 10:34:23 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: client libpq multibyte support " }, { "msg_contents": "> True, and in fact most of the performance problem in the client-side\n> MULTIBYTE code comes from the fact that it's not designed-in, but tries\n> to be a minimally intrusive patch. I think we could make it go faster\n> if we accepted that it was standard functionality. So I'm not averse to\n> going in that direction in the long term ... \n\nGlad to hear that.\n\n> but I do object to turning\n> on MULTIBYTE by default just a couple days before release. We don't\n> really know how robust the MULTIBYTE-client-and-non-MULTIBYTE-server\n> combination is, and so I'm afraid to make it the default configuration\n> with hardly any testing.\n\nAgreed.\n--\nTatsuo Ishii\n", "msg_date": "Sat, 06 May 2000 00:17:54 +0900", "msg_from": "Tatsuo Ishii <[email protected]>", "msg_from_op": false, "msg_subject": "Re: client libpq multibyte support " }, { "msg_contents": "\n> > True, and in fact most of the performance problem in the client-side\n> > MULTIBYTE code comes from the fact that it's not designed-in, but tries\n> > to be a minimally intrusive patch. I think we could make it go faster\n> > if we accepted that it was standard functionality. So I'm not averse to\n> > going in that direction in the long term ... \n> \n> Glad to hear that.\n> \n> > but I do object to turning\n> > on MULTIBYTE by default just a couple days before release. We don't\n> > really know how robust the MULTIBYTE-client-and-non-MULTIBYTE-server\n> > combination is, and so I'm afraid to make it the default configuration\n> > with hardly any testing.\n> \n> Agreed.\n\n Thank you for your challenge. I expect that a good result comes out.\n\n--\nRegard,\nSAKAIDA Masaaki -- Osaka, Japan\n", "msg_date": "Sat, 06 May 2000 01:17:10 +0900", "msg_from": "SAKAIDA Masaaki <[email protected]>", "msg_from_op": true, "msg_subject": "Re: client libpq multibyte support " }, { "msg_contents": "\n Please allow me to pick out this thread again.\n\n> > True, and in fact most of the performance problem in the client-side\n> > MULTIBYTE code comes from the fact that it's not designed-in, but tries\n> > to be a minimally intrusive patch. I think we could make it go faster\n> > if we accepted that it was standard functionality. So I'm not averse to\n> > going in that direction in the long term ... \n\n I have checked the performance problem.\n\n(Environment)\n - Hardware : P200pro CPU, 128MB, 5400rpm disk\n - OS : Red hat Linux-5.2\n - Database version : postgresql-7.0RC1\n\n(Tested software and data)\n - Library : libpq\n - Program : ecpg application program, psql\n - SQL : insert, select\n - Number of tuples : 100,000 tuples\n\n(Test case)\n (1) non-MULTIBYTE\n (2) MULTIBYTE encoding=SQL_ASCII\n\n An ecpg program and the psql were used in this test case. \n\n(Result)\n As for the result, there was no difference in the speed of (1) \nand (2). I could *not* find the performance problem.\n\n(Improvement)\n However, the performance problem may occur if the test of \n10,000,000 tuples will be done. Because PQmblen() has a little \noverhead of routine-call. Therefore, if the MULTIBYTE PQmblen() \nwill be changed as the following, the perfomance problem disappers \n*perfectly*.\n\n # ifdef MULTIBYTE\n int PQmblen(const unsigned char *s, int encoding){\n if( encoding == SQL_ASCII ) return 1; <======= Added line\n return (pg_encoding_mblen(encoding, s));\n }\n # endif\n\n(Conclusion)\n A client library/application should be made by \"configure \n--enable-multibyte[=SQL_ASCII]\" when postgresql is made by \n\"configure [non-MULTIBYTE]\".\n\n\n(Reference of library size)\n non-MULTIBYTE MULTIBYTE\nlibpq.a 69KB 91KB\nlibpq.so.2.0 52KB 52KB\nlibpq.so.2.1 60KB 78KB\n\n--\nRegard,\nSAKAIDA Masaaki -- Osaka, Japan\n", "msg_date": "Mon, 08 May 2000 00:11:35 +0900", "msg_from": "SAKAIDA Masaaki <[email protected]>", "msg_from_op": true, "msg_subject": "Re: client libpq multibyte support " } ]
[ { "msg_contents": "\nTrying to do a pg_dump, using a v7.0 pg_dump on a v7.0 database, I'm\ngetting one of these added to my errout per pg_dump run ...\n\nIs this all related? Is it going to pose a problem?\n\nERROR: Attribute 'inhrel' not found\nERROR: Attribute 'inhrel' not found\nERROR: Attribute 'inhrel' not found\n\n\n", "msg_date": "Fri, 5 May 2000 00:12:54 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "related to the 'pg_group' issue?" }, { "msg_contents": "> \n> Trying to do a pg_dump, using a v7.0 pg_dump on a v7.0 database, I'm\n> getting one of these added to my errout per pg_dump run ...\n> \n> Is this all related? Is it going to pose a problem?\n> \n> ERROR: Attribute 'inhrel' not found\n> ERROR: Attribute 'inhrel' not found\n> ERROR: Attribute 'inhrel' not found\n\nAs I remember, that was renamed in 7.0.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 01:37:01 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: related to the 'pg_group' issue?" } ]
[ { "msg_contents": "\nToday, by chance, we were able to trigger a bug new to v7.0, dealing with\nindices on system tables ...\n\nTom Lane quickly generated and applied patches for this, and we've created\na Release Candidate 5 based on these patches ...\n\nThis RC *requires* a complete dump/initdb/reload of your database\n... without it, consider your database a ticking timebomb ...\n\nThe Release Candidate is available in its usual location:\n\n\tftp://ftp.postgresql.org/pub/...\n\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Fri, 5 May 2000 01:04:15 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "[CRITICAL PATCH] Release Candidate 5 ..." }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> This RC *requires* a complete dump/initdb/reload of your database\n> ... without it, consider your database a ticking timebomb ...\n\nOr at least your pg_group table is a timebomb, if it's not empty.\nPanic is not called for unless you use groups.\n\nIt should be noted that we found and fixed some problems in pg_upgrade\nas well. This may mean that pg_upgrade is now safe. Or not, but it's\nhard to say without testing. I would like to ask people who are\nupgrading to RC5 to try to use pg_upgrade for the move, and report\nwhether you see problems or not. *Please* read the man page for\npg_upgrade, and make a complete dump beforehand so you have a fallback\nif it fails ...\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 00:24:41 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [CRITICAL PATCH] Release Candidate 5 ... " }, { "msg_contents": "> \n> Today, by chance, we were able to trigger a bug new to v7.0, dealing with\n> indices on system tables ...\n> \n> Tom Lane quickly generated and applied patches for this, and we've created\n> a Release Candidate 5 based on these patches ...\n> \n> This RC *requires* a complete dump/initdb/reload of your database\n> ... without it, consider your database a ticking timebomb ...\n ^^^^^^^^^^^^^^^^^^\n\nDid you have to say that? :-)\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 01:41:37 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: [CRITICAL PATCH] Release Candidate 5 ..." }, { "msg_contents": "On Fri, 5 May 2000, Bruce Momjian wrote:\n\n> > \n> > Today, by chance, we were able to trigger a bug new to v7.0, dealing with\n> > indices on system tables ...\n> > \n> > Tom Lane quickly generated and applied patches for this, and we've created\n> > a Release Candidate 5 based on these patches ...\n> > \n> > This RC *requires* a complete dump/initdb/reload of your database\n> > ... without it, consider your database a ticking timebomb ...\n> ^^^^^^^^^^^^^^^^^^\n> \n> Did you have to say that? :-)\n\nNope, could have gone with something like \"a nuclear bomb just itching to\nexplode\", but thought it was too verbose :)\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Fri, 5 May 2000 02:44:28 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [CRITICAL PATCH] Release Candidate 5 ..." } ]
[ { "msg_contents": "\n\n I see help in psql for 'create table' and this syntax description is a\nshort and basic only. It is without 'table_constraint_clause' (FK ..etc).\n\n But it is not problem in the psql. The psql generate internal help from \nSGML docs. Hmm, in this docs is a syntax description split to more blocks\nand psql not use all blocks.\n\n For example in InterBase in M$-Win help is *full* syntax always in one block\non help begin and detail description is behind. Not is it better? \n\n\t\t\t\t\t\t\tKarel\n\n/* ----------------\n * Karel Zak * [email protected] * http://home.zf.jcu.cz/~zakkr/\n * C, PostgreSQL, PHP, WWW, http://docs.linux.cz\n * ----------------\n */\n\n", "msg_date": "Fri, 5 May 2000 11:48:19 +0200 (CEST)", "msg_from": "Karel Zak <[email protected]>", "msg_from_op": true, "msg_subject": "suggestion: docs and psql" } ]
[ { "msg_contents": "On Fri, 5 May 2000, Peter Eisentraut wrote:\n\n> On Fri, 5 May 2000, Karel Zak wrote:\n> \n> > I see help in psql for 'create table' and this syntax description is a\n> > short and basic only. It is without 'table_constraint_clause' (FK ..etc).\n> \n> \\! man create_table\n\n Oh yes, but it is not nice.\n\n> \n> > But it is not problem in the psql. The psql generate internal help from \n> > SGML docs. Hmm, in this docs is a syntax description split to more blocks\n> > and psql not use all blocks.\n> \n> Hmm, we could try to mess around with that. I've been thinking about\n> extending the help display a little to include at least some narrative but\n> that almost requires a full SGML parser. Now, if someone wants to write a\n> DSSSL stylesheet for psql's purposes ... ;)\n\n Full syntax in one block is more nice not only for psql, but for native\nreading too. You not must scroll and search where syntax description\ncontionue...\n\n\t\t\t\t\t\t\tKarel \n\n", "msg_date": "Fri, 5 May 2000 12:24:50 +0200 (CEST)", "msg_from": "Karel Zak <[email protected]>", "msg_from_op": true, "msg_subject": "Re: suggestion: docs and psql" }, { "msg_contents": "> > Hmm, we could try to mess around with that. I've been thinking about\n> > extending the help display a little to include at least some narrative but\n> > that almost requires a full SGML parser. Now, if someone wants to write a\n> > DSSSL stylesheet for psql's purposes ... ;)\n\nHmm. We could convert the docs to XML (the wave of the future, someday\n;), then start using XML for the frontend/backend protocol (I've read\nthat M$ and others claim to be doing this, though I'm not sure why\nthey want to take the hit on the fat ascii tagging typical with XML).\n\nOnce we've done that, then you can use the same XML parser and XSL\nstylesheets to display help and display results from queries :))\n\n> Full syntax in one block is more nice not only for psql, but for native\n> reading too. You not must scroll and search where syntax description\n> contionue...\n\nIf you want, try it out with the sgml docs and we can see if it is\nusable/readable. Worries about that are the only reason they are done\nthe way they are currently.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Fri, 05 May 2000 13:09:10 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: suggestion: docs and psql" } ]
[ { "msg_contents": "> > That's because none-MB client does not understand how \"Shift JIS\n> > kanji\" consists of letters with different width bytes. The similar\n> > problem would happen with the Big5 character set (traditional\n> > Chinese), also. Unlike other character sets, these should be treated\n> > carefully since they include the same bit patterns as ASCII and that\n> > makes none-MB clients confused.\n> \n> I'm confused though, this would mean that somewhere in the string\n> `SJIS_KANJI' a backslash was found. But that's all ASCII characters.\n> Aren't the characters 0-127 always identical in any character set?\n\nNot always. Shift JIS and Big5 include 0-127 characters. So \"how to\ndistinguish them from ASCII?\", you might ask. Here are rules for this:\n\n1. parse from the begining byte of the string in question. If it is\n0-127 then it's an ASCII (single byte letter).\n\n2. if it's between 0xa1 and 0xdf, it's a \"1 byte kana\" (single byte\nletter).\n\n3. otherwise it's a \"kanji\" (double byte letter). In this case the\nsecond byte might be in range of 0-127 (this is the source of the\nproblem).\n\nI think Big5 has similar, but a little bit different rule (I don't\nremember precisely now).\n\nOther encodings having 0-127 range bytes (but they are not ASCII)\ninclude:\n\no UCS-2, 4 (Unicode)\n\no any 7 bit encoded ISO 2022 based charsets. for example, ISO 2022-jp.\n--\nTatsuo Ishii\n", "msg_date": "Fri, 05 May 2000 19:36:18 +0900", "msg_from": "Tatsuo Ishii <[email protected]>", "msg_from_op": true, "msg_subject": "Re: client libpq multibyte support " }, { "msg_contents": "\nTatsuo Ishii <[email protected]> wrote:\n\n> > > admin=# select * from SJIS_KANJI ;\n> > > \\: extra argument ';' ignored\n> > > \\: extra argument ';' ignored\n> > > Invalid command \\. Try \\? for help. \n> >\n(snip)\n> \n> That's because none-MB client does not understand how \"Shift JIS\n> kanji\" consists of letters with different width bytes. The similar\n> problem would happen with the Big5 character set (traditional\n> Chinese), also. Unlike other character sets, these should be treated\n> carefully since they include the same bit patterns as ASCII and that\n> makes none-MB clients confused.\n\n Thank you for your reply.\n\n(Probably, the direct cause of this error is PQmblen(). non-\n MULTIBYTE-PQmblen() always return \"1\". )\n\n\n> Anyway, I could hardly imagine that such configurations\n> would actually exist in the real world. Masaaki, could you tell me\n> what are the advantages or reasons of the configuration?\n\n# My poor English won't be able to explain the real world ;-).\n\n If a client libpq always be made by \"configure --enable-\nmultibute\", the advantages are \n\n 1. In the case of SQL_ASCII, a client application speed is \n almost equal to non-MULTIBYTE. And the MULTIBYTE code is \n not so larger.\n 2. When required, by using \"set client_encoding=xxx\", it is \n possible to use the MULTIBYTE at any time.\n\n\n--\nRegard,\nSAKAIDA Masaaki -- Osaka, Japan\n", "msg_date": "Sat, 06 May 2000 01:06:26 +0900", "msg_from": "SAKAIDA Masaaki <[email protected]>", "msg_from_op": false, "msg_subject": "Re: client libpq multibyte support " } ]
[ { "msg_contents": "\nI'm on a RedHat6.1 box. I've built from RC4 (all sources from\ntarball). Builds/installs just fine, but when trying to do an initdb,\nI get this:\n[postgres@ioport postgres]$ initdb --pglib=$PWD/lib --pgdata=$PWD/data\n\nWe are initializing the database system with username postgres (uid=17).\nThis user will own all the files and must also own the server process.\n\nCreating template database in /home/postgres/data/base/template1\nERROR: Error: unknown type 'oidvector'.\n\nERROR: Error: unknown type 'oidvector'.\n\n syntax error 12 : parse errorinitdb: could not create template database\ninitdb: cleaning up by wiping out /home/postgres/data/base/template1\n\nPerhaps something needs to be looked at before release...\n\n-- \n=====================================================================\n| JAVA must have been developed in the wilds of West Virginia. |\n| After all, why else would it support only single inheritance?? |\n=====================================================================\n| Finger [email protected] for my public key. |\n=====================================================================\n", "msg_date": "05 May 2000 08:43:27 -0400", "msg_from": "[email protected] (Brian E. Gallew)", "msg_from_op": true, "msg_subject": "initdb problems" }, { "msg_contents": "\"Brian E. Gallew\" wrote:\n> \n> I'm on a RedHat6.1 box. I've built from RC4 (all sources from\n> tarball). Builds/installs just fine, but when trying to do an initdb,\n> I get this:\n> [postgres@ioport postgres]$ initdb --pglib=$PWD/lib --pgdata=$PWD/data\n> \n> We are initializing the database system with username postgres (uid=17).\n> This user will own all the files and must also own the server process.\n> \n> Creating template database in /home/postgres/data/base/template1\n> ERROR: Error: unknown type 'oidvector'.\n> \n> ERROR: Error: unknown type 'oidvector'.\n> \n> syntax error 12 : parse errorinitdb: could not create template database\n> initdb: cleaning up by wiping out /home/postgres/data/base/template1\n> \n> Perhaps something needs to be looked at before release...\n\nYou have old Postgres executables and/or libraries in your path,\npresumably due to an existing RPM installation on the machine.\n\nMake sure you are getting the right stuff and it should work just\nfine. On my laptop, which has an RPM *and* a 7.0 development tree\nunder my own account, I just define the following things to get\ntransparent access to the development version:\n\nsetenv PGPORT 12000\nsetenv PGROOT ~/local\nsetenv PGDATA $PGROOT/data\nsetenv PGLIB $PGROOT/lib\nsetenv LD_LIBRARY_PATH $PGROOT/lib\nset path=($PGROOT/bin $path)\n\nI just source this from a file, and the backend and psql fire up and\ninteract just fine.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Fri, 05 May 2000 13:19:18 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: initdb problems" } ]
[ { "msg_contents": "> > > Hmm, we could try to mess around with that. I've been \n> thinking about\n> > > extending the help display a little to include at least \n> some narrative but\n> > > that almost requires a full SGML parser. Now, if someone \n> wants to write a\n> > > DSSSL stylesheet for psql's purposes ... ;)\n> \n> Hmm. We could convert the docs to XML (the wave of the future, someday\n> ;), then start using XML for the frontend/backend protocol (I've read\n> that M$ and others claim to be doing this, though I'm not sure why\n> they want to take the hit on the fat ascii tagging typical with XML).\n\nIn the case of Microsoft, they support XML if you want to (so you can query\nit right away from your browser (IE, of course...) without the need for a\nclient library - e.g. \"http://servername/somedb?sql=<SQL QUERY>\"), but the\nnative format of the client libraries (such as OLE DB or ODBC) is still TDS.\n\nI guess it makes sense in the way that you can do everything from the\nbrowser without running any code on the webserver (cgi/asp/whatever).\n\n//Magnus\n", "msg_date": "Fri, 5 May 2000 16:02:57 +0200 ", "msg_from": "Magnus Hagander <[email protected]>", "msg_from_op": true, "msg_subject": "RE: suggestion: docs and psql" } ]
[ { "msg_contents": "Peter Eisentraut <[email protected]> writes:\n>> After further looking, I notice that users.c is one of the few places\n>> that will drop AccessExclusiveLock at heap_close time rather than\n>> holding it till xact commit. I wonder whether this is a bug...\n\n> Well it was you who did it while introducing that second argument in the\n> first place. I think the safest thing to do is definitely to hold any lock\n> until transaction end. I'm not sure, shouldn't the transaction isolation\n> level apply here as well? In the end, is there ever a good reason for\n> releasing a lock in heap_close?\n\nI provided that hook because of stuff like the LISTEN/NOTIFY support,\nwhich grabs and releases locks on pg_listener --- as it's presently\ndesigned, not releasing the lock at end of statement could hang the\nentire system until you commit your transaction. (Probably\nLISTEN/NOTIFY should be re-examined to see if it couldn't use a less\ndrastic lock than AccessExclusiveLock. That code hasn't been gone over\nsince before MVCC.) Also, I still think that in general it's OK to\nrelease a read lock on a system table early. Write locks, maybe not.\n\n>> I also notice that there definitely is a glaring bug there:\n>> write_password_file() leaks one kernel file descriptor each time it runs\n>> (note the creat() call).\n\n> Wow, this has been there for over two years.\n\nYeah, a long time :-(. It's not the first resource leak we've found\nin the password-related code, too. I wonder if there are more...\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 10:27:29 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": true, "msg_subject": "Re: pg_group_name_index corrupt? " } ]
[ { "msg_contents": "> About Unixware 7, I sent a few reports for witch I did'nt get answer.\n\nI did see some traffic about this; not sure if it was with you or with\nBillie Allie (sp?).\n\n> There are 2 problems:\n> backend/utils/adt/int8.c doesn't compile out of the box.\n> changing around line 416 (for loop) the test i > 0 by 0 < i as previously\n> reported help things.\n> Although I haven't tried, I'm quite sur changing anything else would help\n> the same way...\n\nCompiler bugs are a PITA. But Postgres can't have inline code to\nhandle all cases, esp. cases like this. \"if (var op const)\" is imho\nthe usual style for comparisons, and obfuscating that for a single\nbuggy platform isn't a Good Thing.\n\n> The second is more tricky: On UW 71x, accept call has a bug (witch doesn't\n> exist in 7.01). in case of a unix domain sa_family is set to 0 instead of\n> 1 (AF_UNIX)...\n> What I did was to add the following lines after accept in pqcomm.c:\n> if (port->raddr.sa.sa_family == 0)\n> port->raddr.sa.sa_family = AF_UNIX;\n\nOK, more bugs in the same category as above (esp. since they don't\nexist on other versions of UW even). Check the current SCO FAQ, and if\nthese aren't mentioned then please add some words. Also, if you want\nto post a full patch for either or both problems, then other UW users\ncan have a workaround until SCO gets around to fixing their problems.\n\nSorry for not being able to do more, but platform bugs are really a\ncase-by-case thing, and these two both seem to put the burden on the\nplatform to get it right imho.\n\nRegards.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Fri, 05 May 2000 16:05:47 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Porting reports (cont'd)" }, { "msg_contents": "On Fri, 5 May 2000, Thomas Lockhart wrote:\n\n> > About Unixware 7, I sent a few reports for witch I did'nt get answer.\n> \n> I did see some traffic about this; not sure if it was with you or with\n> Billie Allie (sp?).\n> \n> > There are 2 problems:\n> > backend/utils/adt/int8.c doesn't compile out of the box.\n> > changing around line 416 (for loop) the test i > 0 by 0 < i as previously\n> > reported help things.\n> > Although I haven't tried, I'm quite sur changing anything else would help\n> > the same way...\nOk!! May be this one won't hurt any sensibility!\n\nChange the test from i > 0 to i\n\nIt means the same thing, i can't go negative because of the test below, it\nworks on all systems (including brain dead SCO compiler) and doesn't\nchange the source so much.\n\nI'll try to publish a patch this week -end.\n > \n> Compiler bugs are a PITA. But Postgres can't have inline code to\n> handle all cases, esp. cases like this. \"if (var op const)\" is imho\n> the usual style for comparisons, and obfuscating that for a single\n> buggy platform isn't a Good Thing.\n> \n> > The second is more tricky: On UW 71x, accept call has a bug (witch doesn't\n> > exist in 7.01). in case of a unix domain sa_family is set to 0 instead of\n> > 1 (AF_UNIX)...\n> > What I did was to add the following lines after accept in pqcomm.c:\n> > if (port->raddr.sa.sa_family == 0)\n> > port->raddr.sa.sa_family = AF_UNIX;\n> \n> OK, more bugs in the same category as above (esp. since they don't\n> exist on other versions of UW even). Check the current SCO FAQ, and if\n> these aren't mentioned then please add some words. Also, if you want\n> to post a full patch for either or both problems, then other UW users\n> can have a workaround until SCO gets around to fixing their problems.\n> \n> Sorry for not being able to do more, but platform bugs are really a\n> case-by-case thing, and these two both seem to put the burden on the\n> platform to get it right imho.\n> \n> Regards.\n> \n> - Thomas\nYou've been very helpfull; many thanks\n> \n> \nRegards,\n-- \nOlivier PRENANT \tTel:\t+33-5-61-50-97-00 (Work)\nQuartier d'Harraud Turrou +33-5-61-50-97-01 (Fax)\n31190 AUTERIVE +33-6-07-63-80-64 (GSM)\nFRANCE Email: [email protected]\n------------------------------------------------------------------------------\nMake your life a dream, make your dream a reality. (St Exupery)\n\n", "msg_date": "Fri, 5 May 2000 22:47:33 +0200 (MET DST)", "msg_from": "Olivier PRENANT <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Porting reports (cont'd)" }, { "msg_contents": "> > About Unixware 7, I sent a few reports for witch I did'nt get answer.\n> \n> I did see some traffic about this; not sure if it was with you or with\n> Billie Allie (sp?).\n> \n> > There are 2 problems:\n> > backend/utils/adt/int8.c doesn't compile out of the box.\n> > changing around line 416 (for loop) the test i > 0 by 0 < i as previously\n> > reported help things.\n> > Although I haven't tried, I'm quite sur changing anything else would help\n> > the same way...\n> \n> Compiler bugs are a PITA. But Postgres can't have inline code to\n> handle all cases, esp. cases like this. \"if (var op const)\" is imho\n> the usual style for comparisons, and obfuscating that for a single\n> buggy platform isn't a Good Thing.\n\nThe bigger problem is that just fixes the comparison done by the\nregression tests. Who knows how many other comparisons are broken. I\nsay leave it broken and don't trust it. If we fix just the\nregression-shown fault, we give users a false sense of security.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 18:27:33 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Porting reports (cont'd)" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n>> Compiler bugs are a PITA. But Postgres can't have inline code to\n>> handle all cases, esp. cases like this. \"if (var op const)\" is imho\n>> the usual style for comparisons, and obfuscating that for a single\n>> buggy platform isn't a Good Thing.\n\n> The bigger problem is that just fixes the comparison done by the\n> regression tests. Who knows how many other comparisons are broken. I\n> say leave it broken and don't trust it. If we fix just the\n> regression-shown fault, we give users a false sense of security.\n\nExcellent point...\n\nWhat we've usually done in the past, when faced with compiler problems,\nis to cut down the optimization setting selected by the platform's\ntemplate file. If that helps for Unixware then it'd make sense to do\nit, IMHO.\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 18:50:39 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Porting reports (cont'd) " }, { "msg_contents": "> Bruce Momjian <[email protected]> writes:\n> >> Compiler bugs are a PITA. But Postgres can't have inline code to\n> >> handle all cases, esp. cases like this. \"if (var op const)\" is imho\n> >> the usual style for comparisons, and obfuscating that for a single\n> >> buggy platform isn't a Good Thing.\n> \n> > The bigger problem is that just fixes the comparison done by the\n> > regression tests. Who knows how many other comparisons are broken. I\n> > say leave it broken and don't trust it. If we fix just the\n> > regression-shown fault, we give users a false sense of security.\n> \n> Excellent point...\n> \n> What we've usually done in the past, when faced with compiler problems,\n> is to cut down the optimization setting selected by the platform's\n> template file. If that helps for Unixware then it'd make sense to do\n> it, IMHO.\n\nAgreed.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Fri, 5 May 2000 18:51:48 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Porting reports (cont'd)" } ]
[ { "msg_contents": "Peter Eisentraut <[email protected]> writes:\n>>>> Also, the current configure run will fail if you\n>>>> don't have a C++ compiler at all.\n>> \n>> Fail completely?\n\n> I'm not going to try to prove this now by uninstalling all my compilers\n> but this is a known deficiency in autoconf.\n\nWell, what it appears to be is autoconf espousing the same \"fail hard\"\nphilosophy that you were just claiming was a good thing ;-). If you ask\nit for AC_PROG_CXX and it can't find any working C++ compiler, it gives\nup. I have just checked the behavior with no C++ compiler nor gcc in\nthe PATH, and our configure script will complete if you specify\n--without-CXX, but not otherwise.\n\nDefinitely seems like a good idea to change to a default of --without-CXX\nfor 7.1. Is there anyone out there who wants to argue against it?\n\n\t\t\tregards, tom lane\n", "msg_date": "Fri, 05 May 2000 12:28:16 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": true, "msg_subject": "Re: 7.0RC2 compile error ! " } ]
[ { "msg_contents": "\nOver the past little while, PostgreSQL, Inc has been approached by a few\ncompanies wondering about funding the development of replication features\nin PostgreSQL ...\n\nWith the development and release cycle for v7.0 drawing to a close, I\nwould like to work on moving forward with these opportunities, and am\nwondering if anyone out there feels they have the competency, and time, to\nwork on replication features for the upcoming v7.1 release.\n\nWhat I would like to see if a Proposal on how you feel this can/should be\naccomplished, as well as a timeline to completion, based on existing\nPostgreSQL code. \n\nThe Proposal will have to be hashed out extensively with all the\ndevelopers, so that it fits with our existing code and direction, and\napproved before work begins.\n\nSo far, we've been asked \"How Much?\" ... our goal is to go back and say\n\"This much, still interested?\" and proceed from there ...\n\nAnyone interested? :)\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Fri, 5 May 2000 13:53:28 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "RFP: PostgreSQL Replication ..." } ]
[ { "msg_contents": "\nThis came to the webmaster's mailbox. I have no idea why the bounce\ndidn't work..\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n---------- Forwarded message ----------\nDate: Fri, 05 May 2000 13:43:43 -0700\nFrom: Elo <[email protected]>\nTo: [email protected]\nSubject: http://www.postgresql.org/doxlist.html\n\nI was browsing your compatibility listing and had a possibly odd\nquestion. I have Yellow Dog Linux installed on a Power Macintosh and\nwondered if PostgreSQL would work? Would it be as simple as a recompile\non my platform, or would it be more complicated? If it would work, it\nmight be a useful addition to the compatibility list, though I know I\nrepresent a very small group of users. :-)\n\n\n\n", "msg_date": "Fri, 5 May 2000 21:50:38 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": true, "msg_subject": "http://www.postgresql.org/doxlist.html (fwd)" }, { "msg_contents": "> I was browsing your compatibility listing and had a possibly odd\n> question. I have Yellow Dog Linux installed on a Power Macintosh and\n> wondered if PostgreSQL would work? Would it be as simple as a recompile\n> on my platform, or would it be more complicated?\n\nSince we list PPC mklinux and LinuxPPC as tested platforms, I don't see\nany reason to think it wouldn't work. You might have to do a little\nfooling around to cobble together a suitable OS configuration template\nfile, but I'd surely think it couldn't vary too much from the linux_ppc\ntemplate. Give it a try and let us know. We always like adding new\nplatforms to the support list ;-)\n\nBTW, hackers: does anyone understand just how the spinlock support\nworks on PPC, SPARC, etc? For example, I see that include/port/linux.h\ndefines HAS_TEST_AND_SET for __powerpc__ or __sparc__, but that should\nmean that there's a machine-specific tas() subroutine somewhere. All\nI can find is code in backend/storage/buffer/s_lock.c that looks like\nthe right thing, but it's called tas_dummy() not tas()! How does\ncontrol get to it?\n\n\t\t\tregards, tom lane\n", "msg_date": "Sat, 06 May 2000 02:16:30 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: http://www.postgresql.org/doxlist.html (fwd) " }, { "msg_contents": "> BTW, hackers: does anyone understand just how the spinlock support\n> works on PPC, SPARC, etc? For example, I see that include/port/linux.h\n> defines HAS_TEST_AND_SET for __powerpc__ or __sparc__, but that should\n> mean that there's a machine-specific tas() subroutine somewhere. All\n> I can find is code in backend/storage/buffer/s_lock.c that looks like\n> the right thing, but it's called tas_dummy() not tas()! How does\n> control get to it?\n\nI'm not sure about sparc but... in the following asm code, there is a\nsymbol \"tas\" that is visibile to linker. I rember that tas() codes on\nsome platforms used to do similar thing as sparc and power pc. Now\nthey have been rewritten so that they use the inlining. The reason why\npower pc still remains as it is is just I don't know how to write\npower pc asm code suitable for inlining :-)\n\nstatic void\ntas_dummy()\n{\n\t__asm__(\"\t\t\\n\\\n.global\t\ttas\t\t\\n\\\ntas:\t\t\t\t\\n\\\n\t\tlwarx\t5,0,3\t\\n\\\n\t\tcmpwi\t5,0\t\\n\\\n\t\tbne\tfail\t\\n\\\n[snip]\n--\nTatsuo Ishii\n", "msg_date": "Sat, 06 May 2000 16:36:35 +0900", "msg_from": "Tatsuo Ishii <[email protected]>", "msg_from_op": false, "msg_subject": "Re: http://www.postgresql.org/doxlist.html (fwd) " }, { "msg_contents": "Tatsuo Ishii <[email protected]> writes:\n>> I can find is code in backend/storage/buffer/s_lock.c that looks like\n>> the right thing, but it's called tas_dummy() not tas()! How does\n>> control get to it?\n\n> I'm not sure about sparc but... in the following asm code, there is a\n> symbol \"tas\" that is visibile to linker.\n\nOh ... right ... duh! Sheesh, you'd think I didn't know how to read\nassembler :-(\n\n\t\t\tregards, tom lane\n", "msg_date": "Sat, 06 May 2000 12:59:55 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: http://www.postgresql.org/doxlist.html (fwd) " }, { "msg_contents": "> > I was browsing your compatibility listing and had a possibly odd\n> > question. I have Yellow Dog Linux installed on a Power Macintosh and\n> > wondered if PostgreSQL would work? Would it be as simple as a recompile\n> > on my platform, or would it be more complicated?\n\nI recall seeing an add in a linux-oriented catalog for YD-linux and it\nclaimed that it shipped with Postgres (as well as a couple of other\nRDBMSes, though I don't know why ;)\n\nAre you sure your distro doesn't already have Postgres?\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Mon, 08 May 2000 06:03:46 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: http://www.postgresql.org/doxlist.html (fwd)" } ]
[ { "msg_contents": "\nI'm just looking at what it would take to add a certain level of security\nto the databases that I run on my server(s) ... one of the big problems,\nas I see it, is that we have a pretty poor way of restricting users\nbetween them all ...\n\nFor instance, if I go into pg_hba.conf and make a database 'passwd' auth\nonly, then anyone that has a userid/passwd can connect to that database,\nregardless ...\n\nNow, if they don't have permissions on the *tables*, they can't do\nanything with those tables, but they can still create new ones ...\n\nIs there no way of setting permissions on the database itself, so that,\nfor instance, we'd have:\n\nGRANT ALL ON DATABASE <database> TO <userid>;\n\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Fri, 5 May 2000 23:02:13 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "CREATE DATABASE WITH OWNER '??';" }, { "msg_contents": "The Hermit Hacker wrote:\n> \n> I'm just looking at what it would take to add a certain level of security\n> to the databases that I run on my server(s) ... one of the big problems,\n> as I see it, is that we have a pretty poor way of restricting users\n> between them all ...\n> \n> For instance, if I go into pg_hba.conf and make a database 'passwd' auth\n> only, then anyone that has a userid/passwd can connect to that database,\n> regardless ...\n\nIIRC Oracle has a basic right called CONNECT that a user must have in \norder to connect to database - It would nice if we could have this too\n\nHas anyoune done some research what SQL92 says about what are rights \nthat can be GRANTed ?\n\n> Now, if they don't have permissions on the *tables*, they can't do\n> anything with those tables, but they can still create new ones ...\n> \n> Is there no way of setting permissions on the database itself, so that,\n> for instance, we'd have:\n> \n> GRANT ALL ON DATABASE <database> TO <userid>;\n\nOr maybe \n\nGRANT {CREATE|DROP} TO <userid>;\n\nGRANT CREATE {FUNCTION|LANGUAGE|TABLE|xxx} TO <userid>;\n\nwith optional ON DATABASE\n\nAFAIK we don't have WITH GRANT OPTION for delegating GRANT rights\neither.\n\n------------\nHannu\n", "msg_date": "Sat, 06 May 2000 11:53:00 +0300", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": false, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??';" }, { "msg_contents": "The Hermit Hacker writes:\n\n> For instance, if I go into pg_hba.conf and make a database 'passwd' auth\n> only, then anyone that has a userid/passwd can connect to that database,\n> regardless ...\n\nYou need to make a separate password file for each database and then write\n`passwd my_pw_file' in pg_hba.conf. Should be documented somewhere\nthere. Hmm, then you can't change your password with ALTER USER any\nmore. Bummer.\n\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Sun, 7 May 2000 23:34:26 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??';" }, { "msg_contents": "Peter Eisentraut <[email protected]> writes:\n> You need to make a separate password file for each database and then write\n> `passwd my_pw_file' in pg_hba.conf. Should be documented somewhere\n> there. Hmm, then you can't change your password with ALTER USER any\n> more. Bummer.\n\nHmm, I had forgotten we had that feature. Doesn't play too well with\nALTER USER, does it? Cleaning this up probably ought to be on the TODO\nlist.\n\nRather than the separate pw files, maybe pg_shadow needs some kind of\nprovision for database-specific passwords ...\n\n\t\t\tregards, tom lane\n", "msg_date": "Sun, 07 May 2000 18:06:12 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??'; " }, { "msg_contents": "On Sun, 7 May 2000, Peter Eisentraut wrote:\n\n> The Hermit Hacker writes:\n> \n> > For instance, if I go into pg_hba.conf and make a database 'passwd' auth\n> > only, then anyone that has a userid/passwd can connect to that database,\n> > regardless ...\n> \n> You need to make a separate password file for each database and then write\n> `passwd my_pw_file' in pg_hba.conf. Should be documented somewhere\n> there. Hmm, then you can't change your password with ALTER USER any\n> more. Bummer.\n\nCorrect, and it also makes the assumption that the pg-admin has access to\nthat machine...\n\nIf I give a second user 'create database' access, how does he add auth\nprivileges to that database?\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sun, 7 May 2000 20:46:39 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??';" }, { "msg_contents": "Tom Lane writes:\n\n> Rather than the separate pw files, maybe pg_shadow needs some kind of\n> provision for database-specific passwords ...\n\nPerhaps the issue is not so much having different passwords for each\ndatabase. I don't think this is necessarily a priority. (I think it would\nbe rather confusing that there would be one user and many passwords.)\n\nThe issue is that you can't say \"Do password authentication, but only for\nthese users\". It forces you to make separate password files. Perhaps we\ncould extend the syntax similar to this\n\n| host\tall\t127.0.0.1\t255.255.255.255\tpasswd\t&user1,user2,user3\n\nto mean \"do password authentication using the pg_shadow passwords, but\nonly for the named users\". (`&' would be some special character to\ndistinguish a list of users from a password file name.)\n\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Tue, 9 May 2000 22:51:17 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??'; " }, { "msg_contents": "The Hermit Hacker writes:\n\n> If I give a second user 'create database' access, how does he add auth\n> privileges to that database?\n\nThere are no privileges on databases per se. There are only host-based\naccess privileges that may apply to all or some databases.\n\nThe difficulty with putting the control over this into the SQL environment\nis two-fold:\n\n1) You have a bootstrapping problem, because how are you going to set\nthese privileges if you can't connect?\n\n2) You don't necessarily want to start up a new backend for every rogue\nconnection attempt.\n\nSo we're mostly stuck with what we have.\n\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Tue, 9 May 2000 22:51:27 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??';" }, { "msg_contents": "On Tue, 9 May 2000, Peter Eisentraut wrote:\n\n> Tom Lane writes:\n> \n> > Rather than the separate pw files, maybe pg_shadow needs some kind of\n> > provision for database-specific passwords ...\n> \n> Perhaps the issue is not so much having different passwords for each\n> database. I don't think this is necessarily a priority. (I think it would\n> be rather confusing that there would be one user and many passwords.)\n> \n> The issue is that you can't say \"Do password authentication, but only for\n> these users\". It forces you to make separate password files. Perhaps we\n> could extend the syntax similar to this\n> \n> | host\tall\t127.0.0.1\t255.255.255.255\tpasswd\t&user1,user2,user3\n> \n> to mean \"do password authentication using the pg_shadow passwords, but\n> only for the named users\". (`&' would be some special character to\n> distinguish a list of users from a password file name.)\n\nwhy can't we extend the whole 'grant table' syntax to a 'grant database'\none also? as I see it, the owner of a database should be able to\ngrant/refuse connections to his database without having to go through the\nDBA, which the above requires ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Tue, 9 May 2000 18:17:02 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??'; " }, { "msg_contents": "On Tue, 9 May 2000, Peter Eisentraut wrote:\n\n> The Hermit Hacker writes:\n> \n> > If I give a second user 'create database' access, how does he add auth\n> > privileges to that database?\n> \n> There are no privileges on databases per se. There are only host-based\n> access privileges that may apply to all or some databases.\n> \n> The difficulty with putting the control over this into the SQL environment\n> is two-fold:\n> \n> 1) You have a bootstrapping problem, because how are you going to set\n> these privileges if you can't connect?\n\nCREATE DATABASE WITH OWNER?\n\n> 2) You don't necessarily want to start up a new backend for every rogue\n> connection attempt.\n\nHuh? So, we want to start up a backend for each connection to a database,\nregardless of whether or not that connection has permission to be in that\ndatabase? Geez, let's think ... I'm not supposed to be in payrolls\ndatabase, but since all that is protected is the tables and not the\ndatabase itself, i can connect and just sit there, using up resources that\nway ...\n\n\n", "msg_date": "Tue, 9 May 2000 18:19:18 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??';" }, { "msg_contents": "Peter Eisentraut <[email protected]> writes:\n> The difficulty with putting the control over this into the SQL environment\n> is two-fold:\n\n> 1) You have a bootstrapping problem, because how are you going to set\n> these privileges if you can't connect?\n\nPresumably the database superuser can connect to anything anytime, and\nI'd also expect a newly-minted database to be preconfigured to let its\nowner in. (We could debate whether that privilege should be revokable,\nbut worst case is the owner goes to the dbadmin and admits what an idiot\nhe's been ;-).) So this doesn't seem like a major objection.\n\n> 2) You don't necessarily want to start up a new backend for every rogue\n> connection attempt.\n\nTrue, but we can still expect the postmaster to have done the same\namount of connection checking it does now, so the worst forms of abuse\ncan be prevented. Bear in mind also that things like bad database name\nare usually detected by the newly-started backend, so unless you run a\nmuch tighter than normal pg_hba.conf, you have some exposure here\nalready. I think having the backend reject an unauthorized connection\nattempt from a user that the postmaster has previously checked to be\nknown to the database is not so bad.\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 09 May 2000 18:18:26 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??'; " } ]
[ { "msg_contents": "Added to TODO:\n\n\t* Encrpyt passwords in pg_shadow table using MD5\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Sat, 6 May 2000 16:20:56 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": true, "msg_subject": "Passwords" }, { "msg_contents": "On Sat, 6 May 2000, Bruce Momjian wrote:\n\n> Added to TODO:\n> \n> \t* Encrpyt passwords in pg_shadow table using MD5\n\nUnder FreeBSD, if you use crypt() for encrypting, and you are outside of\nthe 'export restricted area', you auto-get MD5 vs DES ... I think if DES\nis available, it should be used over MD5, if we're doing this for security\nreasons ...\n\nMy *understanding* is that MD5 is a half-way measure that is easier to\nbreak then DES, which is why it isn't under the export restrictions ...\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sat, 6 May 2000 22:54:37 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Passwords" }, { "msg_contents": "On Sat, 6 May 2000, The Hermit Hacker wrote:\n\n> My *understanding* is that MD5 is a half-way measure that is easier to\n> break then DES, which is why it isn't under the export restrictions ...\n\nThere are a few misconceptions here:\n\n1. DES is legal to export since March of this year, when USG relaxed\ncontrols on crypto. Any software that is off-the-shelf or 'free as in\nspeech' is allowed to have DES code. Only requirement is that a copy of\nsoftware or a link to URL which contains software must be provided to BXA\noffice. \n\n2. MD5 was allowed to be exported because it is not a encryption\nalgorithm, and cannot be used as such. It is inherently one-way, therefore\nthe terrorists won't have any use to it. Or something like that ;)\n\n-alex\n\n", "msg_date": "Sat, 6 May 2000 22:15:11 -0400 (EDT)", "msg_from": "Alex Pilosov <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Passwords" }, { "msg_contents": "on 5/6/00 9:54 PM, The Hermit Hacker at [email protected] wrote:\n\n> My *understanding* is that MD5 is a half-way measure that is easier to\n> break then DES, which is why it isn't under the export restrictions ...\n\nNo, MD5 only provides hashing. You can never \"unhash\" something, so you can\nnever use MD5 as a real encryption function (which would need to be\nreversible if you ever want to decrypt your message). Thus, since MD5 does\nnot allow you to encrypt data, it doesn't fall under any export\nrestrictions. It is *very* hard, and most probably impossible to find\ncollisions in the MD5 hashing function (which would allow you to break the\npassword scheme based on it).\n\nWith a DES-based crypt command, you can actually reverse the process. Take\nyour \"crypted\" password, and decrypt it using DES and the cleartext password\nas the key. You'll manage to get back to the original block of \"0\"s that you\nstarted with. That's why DES is export-controlled...\n\n-Ben\n\n", "msg_date": "Sat, 06 May 2000 22:21:16 -0400", "msg_from": "Benjamin Adida <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Passwords" }, { "msg_contents": "The Hermit Hacker writes:\n\n> My *understanding* is that MD5 is a half-way measure that is easier to\n> break then DES, which is why it isn't under the export restrictions ...\n\nIf you don't feel secure about MD5 you can always use SHA1. In fact you\nmight want to look at the mhash package which has a bunch of hashing\nfunctions with a decent interface and it's under a BSD'ish license. At\nleast you can steal the implementation from there.\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Sun, 7 May 2000 23:42:23 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Passwords" }, { "msg_contents": "On Sun, 07 May 2000, Peter Eisentraut wrote:\n> If you don't feel secure about MD5 you can always use SHA1. In fact you\n\nI've read that SHA1 (Secure Hash Algorithm) is preferred over MD5 for new\napplications. MD5 should be used only if you need to maintain support for\napplications which are already using it. SHA1 is 160 bits while MD5 is 128\nbits of output.\n\n -- \nRobert B. Easter\[email protected]\n", "msg_date": "Sun, 7 May 2000 19:32:40 -0400", "msg_from": "\"Robert B. Easter\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Passwords" } ]
[ { "msg_contents": "Of course, no one should try to rollback a DROP TABLE, but if it happens\nthe system tables are left in a mess, because the disk file has gone but\nthe system records are restored by the rollback:\n\n[version 7.0RC2]\njunk=# create table aaa (a int4);\nCREATE\njunk=# begin\njunk-# ;\nBEGIN\njunk=# drop table aaa;\nNOTICE: Caution: DROP TABLE cannot be rolled back, so don't abort now\nDROP\njunk=# rollback;\nROLLBACK\njunk=# select * from aaa;\nNOTICE: mdopen: couldn't open aaa: No such file or directory\nNOTICE: RelationIdBuildRelation: smgropen(aaa): No such file or directory\nNOTICE: mdopen: couldn't open aaa: No such file or directory\nNOTICE: mdopen: couldn't open aaa: No such file or directory\nNOTICE: mdopen: couldn't open aaa: No such file or directory\nNOTICE: mdopen: couldn't open aaa: No such file or directory\nERROR: cannot open relation aaa\njunk=# create table aaa (a int4);\nERROR: Relation 'aaa' already exists\n\nThe solution is either to exclude the system records from the rollback, or\nto delay deleting the disk file until the transaction is committed.\n\nWhich is preferable?\n\n-- \nOliver Elphick [email protected]\nIsle of Wight http://www.lfix.co.uk/oliver\n PGP key from public servers; key ID 32B8FAA1\n ========================================\n \"If it is possible, as much as it depends on you, live \n peaceably with all men.\" Romans 12:18 \n\n\n", "msg_date": "Sat, 06 May 2000 22:30:52 +0100", "msg_from": "\"Oliver Elphick\" <[email protected]>", "msg_from_op": true, "msg_subject": "ROLLBACK of DROP TABLE leaves database in inconsistent state" }, { "msg_contents": "This is news?\n\n> junk=# drop table aaa;\n> NOTICE: Caution: DROP TABLE cannot be rolled back, so don't abort now\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n> DROP\n> junk=# rollback;\n> ROLLBACK\n\nWhat did you think the NOTICE was trying to tell you? (I wanted to\nmake it a hard ERROR, but was shot down.)\n\nThis will be fixed eventually, but until something is done to decouple\nfilenames from relation names it can't be fixed properly. Consider\nBEGIN; DROP TABLE foo; CREATE TABLE foo ...; ABORT. There are plans\nin the pipeline to do that, and we'll fix it when that happens.\n\n\t\t\tregards, tom lane\n", "msg_date": "Sat, 06 May 2000 18:21:19 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: ROLLBACK of DROP TABLE leaves database in inconsistent state " } ]
[ { "msg_contents": "Vince Vielhaber <[email protected]> writes:\n>So we're in agreement on using MD5. Sverre, is the offer still open\n>for the java MD5 you wrote? I'll translate it to C and make sure it\n>will compile/run/give-correct-results on as many platforms as possible\n>including DOS/Windows, hpux, FreeBSD and IRIX. \n\nPortable C source code for MD5 is included in the MD5 specification, RFC 1321:\n\n\thttp://www.ietf.org/rfc/rfc1321.txt\n\n\t-Michael Robinson\n\n", "msg_date": "Sun, 7 May 2000 14:13:00 +0800 (+0800)", "msg_from": "Michael Robinson <[email protected]>", "msg_from_op": true, "msg_subject": "Re: So we're in agreement...." } ]
[ { "msg_contents": "I have found some minor errors in psql:\n\n1. tab expansion does not expand the following\n\nCOMMENT, TRUNCATE, END \n\n2. if used with \\h expansion adds a trailing space.\n trailing space is not tolerated by \\h\n\n\\h clu\n(press tab here)\n\\h CLUSTER \nNo help available for 'CLUSTER '.\n\n-----------------\nHannu\n", "msg_date": "Sun, 07 May 2000 10:40:35 +0300", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": true, "msg_subject": "minor psql errors in RC5" }, { "msg_contents": "Hannu Krosing writes:\n\n> I have found some minor errors in psql:\n> \n> 1. tab expansion does not expand the following\n> \n> COMMENT, TRUNCATE, END \n\nWe can probably add these for 7.0.1. (COMMENT and TRUNCATE were added\nafter tab completion was written. END is deprecated anyway.)\n\n> \n> 2. if used with \\h expansion adds a trailing space.\n> trailing space is not tolerated by \\h\n\nHas been pointed out already. Perhaps 7.0.1 as well.\n\n> \n> \\h clu\n> (press tab here)\n> \\h CLUSTER \n> No help available for 'CLUSTER '.\n> \n> -----------------\n> Hannu\n> \n> \n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Sun, 7 May 2000 23:38:54 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: minor psql errors in RC5" } ]
[ { "msg_contents": "\nOkay, this is with code of ~May 4th ... a 'psql' connection to the\ndatabase hangs solid.\n\nerrout is dated:\n\npgsql% !ls\nls -lt\ntotal 13324\n-rw------- 1 pgsql pgsql 4842715 May 7 10:57 errout.5432\n\nand the last few lines contain:\n\nERROR: parser: parse error at or near \"vpti\"\npq_recvbuf: unexpected EOF on client connection\npq_flush: send() failed: Broken pipe\npq_recvbuf: recv() failed: Connection reset by peer\npq_recvbuf: unexpected EOF on client connection\npq_recvbuf: unexpected EOF on client connection\npq_flush: send() failed: Broken pipe\npq_recvbuf: recv() failed: Connection reset by peer\n\nBut, of course, no date/time ...\n\nps shows:\n\nUSER PID %CPU %MEM VSZ RSS TT STAT STARTED TIME COMMAND\npgsql 33515 0.0 0.0 0 0 ?? Z 4:45PM 0:00.00 (postgres)\npgsql 33516 0.0 0.0 0 0 ?? Z 4:45PM 0:00.00 (postgres)\npgsql 93757 0.0 0.2 1456 1088 p0 S Wed03PM 0:01.11 -su (tcsh)\npgsql 7100 0.0 0.5 38692 2616 ?? Is Fri12AM 8:43.44 /pgsql/bin/postmas\npgsql 33667 0.0 0.0 396 224 p0 R+ 7:35PM 0:00.00 ps ux\n\nand postmaster is started with:\n\npgsql% cat pgstart\n#!/bin/tcsh\nsetenv PORT 5432\nsetenv POSTMASTER /pgsql/bin/postmaster\nunlimit\n${POSTMASTER} -B 4096 -N 128 -S -o \"-F -o /pgsql/errout.${PORT} -S 32768\" \\\n -i -p ${PORT} -D/pgsql/data\n\nThe machine is a Dual PIII with 512Meg of RAM, running FreeBSD 4.0-STABLE\nfrom April 22nd ...\n\npgsql% truss -p 7100\n\nShows zilch ...\n\nSince this is a production server, I can't just leave it there hung like\nthat, but if someone wants to give some instructions on what to do the\nnext time this happens, please feel free to do so, and I'll add that to my\nlist ... maybe run a gdb command on it, since truss doesn't appear to\nhelp?\n\nAt this time, I consider this to be a show-stopper on the release ... this\nis what happened the last time when the result appeared to be the index\ncorruption ... this time, I've checked a VACUUM after re-starting and it\ndoesn't appear to be a problem, but they might not have been related, just\na fluke ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sun, 7 May 2000 20:44:08 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "It happened again: Server hung up solid " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> Okay, this is with code of ~May 4th ... a 'psql' connection to the\n> database hangs solid.\n\nDo you mean you can't make a connection at all? Is there any indication\nthat the postmaster is lighting off a backend for you? Since you show\na couple of zombie backends hanging around, it would seem like a good\nbet that the postmaster itself is wedged and not responding to events,\nbut I'm not sure.\n\n> errout is dated:\n\n> pgsql% !ls\n> ls -lt\n> total 13324\n> -rw------- 1 pgsql pgsql 4842715 May 7 10:57 errout.5432\n\n> and the last few lines contain:\n\n> ERROR: parser: parse error at or near \"vpti\"\n> pq_recvbuf: unexpected EOF on client connection\n> pq_flush: send() failed: Broken pipe\n> pq_recvbuf: recv() failed: Connection reset by peer\n> pq_recvbuf: unexpected EOF on client connection\n> pq_recvbuf: unexpected EOF on client connection\n> pq_flush: send() failed: Broken pipe\n> pq_recvbuf: recv() failed: Connection reset by peer\n\n> But, of course, no date/time ...\n\nGiven that the file mod time is considerably before the hang (right?)\nthe messages in it are probably unrelated. It does seem odd that you\nhave so many clients disconnecting ungracefully; what client apps are\nyou running?\n\n> Since this is a production server, I can't just leave it there hung like\n> that, but if someone wants to give some instructions on what to do the\n> next time this happens, please feel free to do so, and I'll add that to my\n> list ... maybe run a gdb command on it, since truss doesn't appear to\n> help?\n\nTry killing the postmaster itself in such a way as to produce a coredump\n(kill -ABORT ought to do) and get a backtrace from that. It might also\nbe worth running the postmaster with connection tracing turned on (I\nforget the incantation for that, but it should be in TFM).\n\n> At this time, I consider this to be a show-stopper on the release ... this\n> is what happened the last time when the result appeared to be the index\n> corruption\n\nIf the postmaster is hanging then it's almost certainly unrelated to\nindex corruption...\n\n\t\t\tregards, tom lane\n", "msg_date": "Sun, 07 May 2000 20:35:33 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: It happened again: Server hung up solid " }, { "msg_contents": "On Sun, 7 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> > Okay, this is with code of ~May 4th ... a 'psql' connection to the\n> > database hangs solid.\n> \n> Do you mean you can't make a connection at all? Is there any indication\n> that the postmaster is lighting off a backend for you? Since you show\n> a couple of zombie backends hanging around, it would seem like a good\n> bet that the postmaster itself is wedged and not responding to events,\n> but I'm not sure.\n\nThis appears to be the case, but next time it happens I will make\ndouble-sure of that ... considering that it was ~7pm at night when I\ntried, my initial guess is that nothing is going through postmaster at the\ntime of hte hang ...\n\n> \n> Given that the file mod time is considerably before the hang (right?)\n> the messages in it are probably unrelated. It does seem odd that you\n> have so many clients disconnecting ungracefully; what client apps are\n> you running?\n\nalot of dbi stuff, the search engine for udmsearch, some php ... the\nserver is currently serving ~12 databases for various clients ...\n\n> Try killing the postmaster itself in such a way as to produce a coredump\n> (kill -ABORT ought to do) and get a backtrace from that. It might also\n> be worth running the postmaster with connection tracing turned on (I\n> forget the incantation for that, but it should be in TFM).\n\nWill look at that one ...\n\n\n", "msg_date": "Sun, 7 May 2000 21:48:28 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: It happened again: Server hung up solid " }, { "msg_contents": "\n\nOkay, just happened again ... no postgres backend is being started:\n\nUSER PID %CPU %MEM VSZ RSS TT STAT STARTED TIME COMMAND\npgsql 34611 0.0 0.0 0 0 ?? Z 8:43PM 0:00.00 (postgres)\npgsql 93757 0.0 0.2 1456 1104 p0 S Wed03PM 0:01.16 -su (tcsh)\npgsql 33683 0.0 0.6 38356 3024 ?? Is 7:38PM 0:03.54 /pgsql/bin/postmaster -B 4096 -N 128 -S -o -F -o /pgsql/errout.5432\npgsql 34677 0.0 0.2 1408 1048 p2 S 8:50PM 0:00.07 -su (tcsh)\npgsql 34685 0.0 0.2 1652 1032 p0 S+ 8:51PM 0:00.01 psql udmsearch\npgsql 34687 0.0 0.0 400 232 p2 R+ 8:51PM 0:00.00 ps ux\n\nGoing to look at the connection tracing option now and see what I can come\nup with ...\n\n\nOn Sun, 7 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> > Okay, this is with code of ~May 4th ... a 'psql' connection to the\n> > database hangs solid.\n> \n> Do you mean you can't make a connection at all? Is there any indication\n> that the postmaster is lighting off a backend for you? Since you show\n> a couple of zombie backends hanging around, it would seem like a good\n> bet that the postmaster itself is wedged and not responding to events,\n> but I'm not sure.\n> \n> > errout is dated:\n> \n> > pgsql% !ls\n> > ls -lt\n> > total 13324\n> > -rw------- 1 pgsql pgsql 4842715 May 7 10:57 errout.5432\n> \n> > and the last few lines contain:\n> \n> > ERROR: parser: parse error at or near \"vpti\"\n> > pq_recvbuf: unexpected EOF on client connection\n> > pq_flush: send() failed: Broken pipe\n> > pq_recvbuf: recv() failed: Connection reset by peer\n> > pq_recvbuf: unexpected EOF on client connection\n> > pq_recvbuf: unexpected EOF on client connection\n> > pq_flush: send() failed: Broken pipe\n> > pq_recvbuf: recv() failed: Connection reset by peer\n> \n> > But, of course, no date/time ...\n> \n> Given that the file mod time is considerably before the hang (right?)\n> the messages in it are probably unrelated. It does seem odd that you\n> have so many clients disconnecting ungracefully; what client apps are\n> you running?\n> \n> > Since this is a production server, I can't just leave it there hung like\n> > that, but if someone wants to give some instructions on what to do the\n> > next time this happens, please feel free to do so, and I'll add that to my\n> > list ... maybe run a gdb command on it, since truss doesn't appear to\n> > help?\n> \n> Try killing the postmaster itself in such a way as to produce a coredump\n> (kill -ABORT ought to do) and get a backtrace from that. It might also\n> be worth running the postmaster with connection tracing turned on (I\n> forget the incantation for that, but it should be in TFM).\n> \n> > At this time, I consider this to be a show-stopper on the release ... this\n> > is what happened the last time when the result appeared to be the index\n> > corruption\n> \n> If the postmaster is hanging then it's almost certainly unrelated to\n> index corruption...\n> \n> \t\t\tregards, tom lane\n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sun, 7 May 2000 21:52:41 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: It happened again: Server hung up solid " }, { "msg_contents": "\n\nkill -ABRT does nothing:\n\npgsql% kill -ABRT 33683\npgsql% !ps\nps ux\nUSER PID %CPU %MEM VSZ RSS TT STAT STARTED TIME COMMAND\npgsql 34611 0.0 0.0 0 0 ?? Z 8:43PM 0:00.00 (postgres)\npgsql 93757 0.0 0.2 1456 1104 p0 S Wed03PM 0:01.17 -su (tcsh)\npgsql 33683 0.0 0.6 38356 3024 ?? Is 7:38PM 0:03.54 /pgsql/bin/postmas\npgsql 34677 0.0 0.2 1408 1048 p2 S+ 8:50PM 0:00.08 -su (tcsh)\npgsql 34696 0.0 0.0 396 232 p0 R+ 8:56PM 0:00.00 ps ux\npgsql% !ps\nps ux\nUSER PID %CPU %MEM VSZ RSS TT STAT STARTED TIME COMMAND\npgsql 34611 0.0 0.0 0 0 ?? Z 8:43PM 0:00.00 (postgres)\npgsql 93757 0.0 0.2 1456 1104 p0 S Wed03PM 0:01.17 -su (tcsh)\npgsql 33683 0.0 0.6 38356 3024 ?? Is 7:38PM 0:03.54 /pgsql/bin/postmas\npgsql 34677 0.0 0.2 1408 1048 p2 S+ 8:50PM 0:00.08 -su (tcsh)\npgsql 34697 0.0 0.0 396 232 p0 R+ 8:56PM 0:00.00 ps ux\n\n\nOn Sun, 7 May 2000, The Hermit Hacker wrote:\n\n> \n> \n> Okay, just happened again ... no postgres backend is being started:\n> \n> USER PID %CPU %MEM VSZ RSS TT STAT STARTED TIME COMMAND\n> pgsql 34611 0.0 0.0 0 0 ?? Z 8:43PM 0:00.00 (postgres)\n> pgsql 93757 0.0 0.2 1456 1104 p0 S Wed03PM 0:01.16 -su (tcsh)\n> pgsql 33683 0.0 0.6 38356 3024 ?? Is 7:38PM 0:03.54 /pgsql/bin/postmaster -B 4096 -N 128 -S -o -F -o /pgsql/errout.5432\n> pgsql 34677 0.0 0.2 1408 1048 p2 S 8:50PM 0:00.07 -su (tcsh)\n> pgsql 34685 0.0 0.2 1652 1032 p0 S+ 8:51PM 0:00.01 psql udmsearch\n> pgsql 34687 0.0 0.0 400 232 p2 R+ 8:51PM 0:00.00 ps ux\n> \n> Going to look at the connection tracing option now and see what I can come\n> up with ...\n> \n> \n> On Sun, 7 May 2000, Tom Lane wrote:\n> \n> > The Hermit Hacker <[email protected]> writes:\n> > > Okay, this is with code of ~May 4th ... a 'psql' connection to the\n> > > database hangs solid.\n> > \n> > Do you mean you can't make a connection at all? Is there any indication\n> > that the postmaster is lighting off a backend for you? Since you show\n> > a couple of zombie backends hanging around, it would seem like a good\n> > bet that the postmaster itself is wedged and not responding to events,\n> > but I'm not sure.\n> > \n> > > errout is dated:\n> > \n> > > pgsql% !ls\n> > > ls -lt\n> > > total 13324\n> > > -rw------- 1 pgsql pgsql 4842715 May 7 10:57 errout.5432\n> > \n> > > and the last few lines contain:\n> > \n> > > ERROR: parser: parse error at or near \"vpti\"\n> > > pq_recvbuf: unexpected EOF on client connection\n> > > pq_flush: send() failed: Broken pipe\n> > > pq_recvbuf: recv() failed: Connection reset by peer\n> > > pq_recvbuf: unexpected EOF on client connection\n> > > pq_recvbuf: unexpected EOF on client connection\n> > > pq_flush: send() failed: Broken pipe\n> > > pq_recvbuf: recv() failed: Connection reset by peer\n> > \n> > > But, of course, no date/time ...\n> > \n> > Given that the file mod time is considerably before the hang (right?)\n> > the messages in it are probably unrelated. It does seem odd that you\n> > have so many clients disconnecting ungracefully; what client apps are\n> > you running?\n> > \n> > > Since this is a production server, I can't just leave it there hung like\n> > > that, but if someone wants to give some instructions on what to do the\n> > > next time this happens, please feel free to do so, and I'll add that to my\n> > > list ... maybe run a gdb command on it, since truss doesn't appear to\n> > > help?\n> > \n> > Try killing the postmaster itself in such a way as to produce a coredump\n> > (kill -ABORT ought to do) and get a backtrace from that. It might also\n> > be worth running the postmaster with connection tracing turned on (I\n> > forget the incantation for that, but it should be in TFM).\n> > \n> > > At this time, I consider this to be a show-stopper on the release ... this\n> > > is what happened the last time when the result appeared to be the index\n> > > corruption\n> > \n> > If the postmaster is hanging then it's almost certainly unrelated to\n> > index corruption...\n> > \n> > \t\t\tregards, tom lane\n> > \n> \n> Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy\n> Systems Administrator @ hub.org \n> primary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sun, 7 May 2000 21:57:20 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: It happened again: Server hung up solid " }, { "msg_contents": "On Sun, 7 May 2000, The Hermit Hacker wrote:\n\n> \n> \n> Okay, just happened again ... no postgres backend is being started:\n\nI don't know how close in time it was, but I just hit reload on that\nquery that was sent to webmaster.\n\nVince.\n\n\n\n> \n> USER PID %CPU %MEM VSZ RSS TT STAT STARTED TIME COMMAND\n> pgsql 34611 0.0 0.0 0 0 ?? Z 8:43PM 0:00.00 (postgres)\n> pgsql 93757 0.0 0.2 1456 1104 p0 S Wed03PM 0:01.16 -su (tcsh)\n> pgsql 33683 0.0 0.6 38356 3024 ?? Is 7:38PM 0:03.54 /pgsql/bin/postmaster -B 4096 -N 128 -S -o -F -o /pgsql/errout.5432\n> pgsql 34677 0.0 0.2 1408 1048 p2 S 8:50PM 0:00.07 -su (tcsh)\n> pgsql 34685 0.0 0.2 1652 1032 p0 S+ 8:51PM 0:00.01 psql udmsearch\n> pgsql 34687 0.0 0.0 400 232 p2 R+ 8:51PM 0:00.00 ps ux\n> \n> Going to look at the connection tracing option now and see what I can come\n> up with ...\n> \n> \n> On Sun, 7 May 2000, Tom Lane wrote:\n> \n> > The Hermit Hacker <[email protected]> writes:\n> > > Okay, this is with code of ~May 4th ... a 'psql' connection to the\n> > > database hangs solid.\n> > \n> > Do you mean you can't make a connection at all? Is there any indication\n> > that the postmaster is lighting off a backend for you? Since you show\n> > a couple of zombie backends hanging around, it would seem like a good\n> > bet that the postmaster itself is wedged and not responding to events,\n> > but I'm not sure.\n> > \n> > > errout is dated:\n> > \n> > > pgsql% !ls\n> > > ls -lt\n> > > total 13324\n> > > -rw------- 1 pgsql pgsql 4842715 May 7 10:57 errout.5432\n> > \n> > > and the last few lines contain:\n> > \n> > > ERROR: parser: parse error at or near \"vpti\"\n> > > pq_recvbuf: unexpected EOF on client connection\n> > > pq_flush: send() failed: Broken pipe\n> > > pq_recvbuf: recv() failed: Connection reset by peer\n> > > pq_recvbuf: unexpected EOF on client connection\n> > > pq_recvbuf: unexpected EOF on client connection\n> > > pq_flush: send() failed: Broken pipe\n> > > pq_recvbuf: recv() failed: Connection reset by peer\n> > \n> > > But, of course, no date/time ...\n> > \n> > Given that the file mod time is considerably before the hang (right?)\n> > the messages in it are probably unrelated. It does seem odd that you\n> > have so many clients disconnecting ungracefully; what client apps are\n> > you running?\n> > \n> > > Since this is a production server, I can't just leave it there hung like\n> > > that, but if someone wants to give some instructions on what to do the\n> > > next time this happens, please feel free to do so, and I'll add that to my\n> > > list ... maybe run a gdb command on it, since truss doesn't appear to\n> > > help?\n> > \n> > Try killing the postmaster itself in such a way as to produce a coredump\n> > (kill -ABORT ought to do) and get a backtrace from that. It might also\n> > be worth running the postmaster with connection tracing turned on (I\n> > forget the incantation for that, but it should be in TFM).\n> > \n> > > At this time, I consider this to be a show-stopper on the release ... this\n> > > is what happened the last time when the result appeared to be the index\n> > > corruption\n> > \n> > If the postmaster is hanging then it's almost certainly unrelated to\n> > index corruption...\n> > \n> > \t\t\tregards, tom lane\n> > \n> \n> Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy\n> Systems Administrator @ hub.org \n> primary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n> \n> \n\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Sun, 7 May 2000 20:57:42 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: It happened again: Server hung up solid " }, { "msg_contents": "\nWith -d set to 1 (connection tracing), all I see when I connect, in the\nlog files, is:\n\nFindExec: found \"/pgsql/bin/postgres\" using argv[0]\nFindExec: found \"/pgsql/bin/postgres\" using argv[0]\n\ndoesn't tell me to what I'm connecting through ...\n\n\nOn Sun, 7 May 2000, The Hermit Hacker wrote:\n\n> \n> Okay, this is with code of ~May 4th ... a 'psql' connection to the\n> database hangs solid.\n> \n> errout is dated:\n> \n> pgsql% !ls\n> ls -lt\n> total 13324\n> -rw------- 1 pgsql pgsql 4842715 May 7 10:57 errout.5432\n> \n> and the last few lines contain:\n> \n> ERROR: parser: parse error at or near \"vpti\"\n> pq_recvbuf: unexpected EOF on client connection\n> pq_flush: send() failed: Broken pipe\n> pq_recvbuf: recv() failed: Connection reset by peer\n> pq_recvbuf: unexpected EOF on client connection\n> pq_recvbuf: unexpected EOF on client connection\n> pq_flush: send() failed: Broken pipe\n> pq_recvbuf: recv() failed: Connection reset by peer\n> \n> But, of course, no date/time ...\n> \n> ps shows:\n> \n> USER PID %CPU %MEM VSZ RSS TT STAT STARTED TIME COMMAND\n> pgsql 33515 0.0 0.0 0 0 ?? Z 4:45PM 0:00.00 (postgres)\n> pgsql 33516 0.0 0.0 0 0 ?? Z 4:45PM 0:00.00 (postgres)\n> pgsql 93757 0.0 0.2 1456 1088 p0 S Wed03PM 0:01.11 -su (tcsh)\n> pgsql 7100 0.0 0.5 38692 2616 ?? Is Fri12AM 8:43.44 /pgsql/bin/postmas\n> pgsql 33667 0.0 0.0 396 224 p0 R+ 7:35PM 0:00.00 ps ux\n> \n> and postmaster is started with:\n> \n> pgsql% cat pgstart\n> #!/bin/tcsh\n> setenv PORT 5432\n> setenv POSTMASTER /pgsql/bin/postmaster\n> unlimit\n> ${POSTMASTER} -B 4096 -N 128 -S -o \"-F -o /pgsql/errout.${PORT} -S 32768\" \\\n> -i -p ${PORT} -D/pgsql/data\n> \n> The machine is a Dual PIII with 512Meg of RAM, running FreeBSD 4.0-STABLE\n> from April 22nd ...\n> \n> pgsql% truss -p 7100\n> \n> Shows zilch ...\n> \n> Since this is a production server, I can't just leave it there hung like\n> that, but if someone wants to give some instructions on what to do the\n> next time this happens, please feel free to do so, and I'll add that to my\n> list ... maybe run a gdb command on it, since truss doesn't appear to\n> help?\n> \n> At this time, I consider this to be a show-stopper on the release ... this\n> is what happened the last time when the result appeared to be the index\n> corruption ... this time, I've checked a VACUUM after re-starting and it\n> doesn't appear to be a problem, but they might not have been related, just\n> a fluke ...\n> \n> Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy\n> Systems Administrator @ hub.org \n> primary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sun, 7 May 2000 21:59:26 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: It happened again: Server hung up solid " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> kill -ABRT does nothing:\n\nOh? Must be hung up in a kernel call then. That will probably mean\nthat you can't attach to the stuck process with gdb either (though\nit'd be worth trying, since a backtrace would be mighty useful if\nyou could get it).\n\nMy next thought is to truss the postmaster process before it hangs\nup, with hopes of finding out what kernel call is hanging.\n\nAlso, you might try netstat to see if you can see any freshly-opened\nincoming connections when it happens. Also, \"lsof -p\" or local\nequivalent on the stuck postmaster.\n\n\t\t\tregards, tom lane\n", "msg_date": "Sun, 07 May 2000 22:13:52 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: It happened again: Server hung up solid " } ]
[ { "msg_contents": "Well, at the risk of embarrassing our esteemed Bug Fixer Extraordinaire, after\nverifying that it is, indeed, the same man, Kudos to the 7th most prolific\nopen-source author in the world THOMAS G LANE!!!\n\nhttp://orbiten.org/ofss/01.html for reference.\n\nGood for grins, if nothing else. I think they are counting by actual bytes of\nsource code contributed (however they measure that -- probably, in most cases,\nby copyright notices.). In any case, hoorays for Tom Lane (and for the rest of\nthe Free Software community). It is unfortunate, however, that the PostgreSQL\nproject isn't counted amongst his contributees.\n\n(Tom, yes I _did_ have to do that... :-) :-) ).\n\nOf course, that is not meant to belittle anyone at all.... as all the\ndevelopers here have contributed valuable features and fixes to the best Free\nRDBMS around. (InterBase is not likely to ever be 'Free' in that 'Free\nSoftware' sense of the word -- open source does not mean 'Free!')\n\n--\nLamar Owen\nWGCR Internet Radio\n1 Peter 4:11\n", "msg_date": "Sun, 7 May 2000 20:10:42 -0400", "msg_from": "Lamar Owen <[email protected]>", "msg_from_op": true, "msg_subject": "A celebrity among us :-)" }, { "msg_contents": "On Sun, 07 May 2000, Lamar Owen wrote:\n> http://orbiten.org/ofss/01.html for reference.\n\nIncidentally, PostgreSQL (6.5.3) is listed, at the following url:\nhttp://orbiten.org/ofss/codd-render.cgi?action=project&codd=results/may2000/freshmeat-05012000/postgresql-6.5.3.codd\n\n--\nLamar Owen\nWGCR Internet Radio\n1 Peter 4:11\n", "msg_date": "Sun, 7 May 2000 21:58:12 -0400", "msg_from": "Lamar Owen <[email protected]>", "msg_from_op": true, "msg_subject": "Re: A celebrity among us :-)" }, { "msg_contents": "Lamar Owen wrote:\n> \n> Well, at the risk of embarrassing our esteemed Bug Fixer Extraordinaire, after\n> verifying that it is, indeed, the same man, Kudos to the 7th most prolific\n> open-source author in the world THOMAS G LANE!!!\n> \n> http://orbiten.org/ofss/01.html for reference.\n> \n\nNow I know who to contact for all my Discrete Cosine Transform\nquestions.\n\n> Good for grins, if nothing else. I think they are counting by actual bytes of\n> source code contributed (however they measure that -- probably, in most cases,\n> by copyright notices.). In any case, hoorays for Tom Lane (and for the rest of\n> the Free Software community). It is unfortunate, however, that the PostgreSQL\n> project isn't counted amongst his contributees.\n\nJust glancing through the CVS logs leads me to believe that, with\nPostgreSQL, maybe it should go:\n\n1. FSF\n2. Sun Microsystems\n3. Tom Lane\n4. UCLA\n\nJust my humble opinion, of course :-)\n\nMike Mascari\n", "msg_date": "Sun, 07 May 2000 22:03:26 -0400", "msg_from": "Mike Mascari <[email protected]>", "msg_from_op": false, "msg_subject": "Re: A celebrity among us :-)" }, { "msg_contents": "> On Sun, 07 May 2000, Lamar Owen wrote:\n> > http://orbiten.org/ofss/01.html for reference.\n> \n> Incidentally, PostgreSQL (6.5.3) is listed, at the following url:\n> http://orbiten.org/ofss/codd-render.cgi?action=project&codd=results/may2000/freshmeat-05012000/postgresql-6.5.3.codd\n\nOK, I see it. Now, what is it?\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Sun, 7 May 2000 22:10:30 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: A celebrity among us :-)" }, { "msg_contents": "> > On Sun, 07 May 2000, Lamar Owen wrote:\n> > > http://orbiten.org/ofss/01.html for reference.\n> > \n> > Incidentally, PostgreSQL (6.5.3) is listed, at the following url:\n> > http://orbiten.org/ofss/codd-render.cgi?action=project&codd=results/may2000/freshmeat-05012000/postgresql-6.5.3.codd\n> \n> OK, I see it. Now, what is it?\n\nOK, I see now. Wow, Tom Lane is up there. How can I be 143? I even\nshow up in Krunning, and I have never heard of it. Also remember that\nmy CVS commit shows up for any patch that does not have CVS commit\nprivs, so it is overstated.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Sun, 7 May 2000 22:20:51 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: A celebrity among us :-)" }, { "msg_contents": "> > > On Sun, 07 May 2000, Lamar Owen wrote:\n> > > > http://orbiten.org/ofss/01.html for reference.\n> > > \n> > > Incidentally, PostgreSQL (6.5.3) is listed, at the following url:\n> > > http://orbiten.org/ofss/codd-render.cgi?action=project&codd=results/may2000/freshmeat-05012000/postgresql-6.5.3.codd\n> > \n> > OK, I see it. Now, what is it?\n> \n> OK, I see now. Wow, Tom Lane is up there. How can I be 143? I even\n> show up in Krunning, and I have never heard of it. Also remember that\n> my CVS commit shows up for any patch that does not have CVS commit\n> privs, so it is overstated.\n\nMan, Tom Lane has 17 projects under his name. Wow. Is that all jpeg\nstuff, Tom?\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Sun, 7 May 2000 22:23:00 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: A celebrity among us :-)" }, { "msg_contents": "Lamar Owen <[email protected]> writes:\n> http://orbiten.org/ofss/01.html for reference.\n\n> Good for grins, if nothing else.\n\nAnd little else. I think the reason I'm up there is just that there are\na ton of open-source programs that have incorporated libjpeg. AFAICT\nthe survey just counted copyright notices appearing in open-source\ndistributions; so if your code appears in N programs you get N times as\nmuch credit as you should. I certainly don't have more lines of open\nsource circulating than MIT does...\n\n> (Tom, yes I _did_ have to do that... :-) :-) ).\n\nNo you didn't... this survey is too bogus to deserve quoting. (If\nthey're going to treat groups like FSF and the entire UC system as a\nsingle author, and *draw conclusions that are stated as though they\nbelieved FSF and UC are single authors*, what use is it? They have\na lot of work to do.)\n\n\t\t\tregards, tom lane\n\t\t\torganizer, Independent JPEG Group\n", "msg_date": "Sun, 07 May 2000 22:46:48 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: A celebrity among us :-) " } ]
[ { "msg_contents": "\nin the postgres man page, it has:\n\n-A n|r|b|Q\\fIn\\fP|X\\fIn\\fP\n\n This option generates a tremendous amount of output. \n\nUmmm ... and what exactly do these options do? :)\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Sun, 7 May 2000 21:55:30 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Documentation on postgres/postmaster ..." } ]
[ { "msg_contents": ">Try killing the postmaster itself in such a way as to produce a coredump\n>(kill -ABORT ought to do) and get a backtrace from that.\n\nThe \"gcore\" command (on most modern unices) will generate a core dump of a \nrunning process without killing the process. It seems that would be more\nuseful in this circumstance.\n\n\t-Michael Robinson\n\n", "msg_date": "Mon, 8 May 2000 10:50:43 +0800 (+0800)", "msg_from": "Michael Robinson <[email protected]>", "msg_from_op": true, "msg_subject": "Re: It happened again: Server hung up solid " }, { "msg_contents": "\n*sigh*\n\n> gcore 87721\ngcore: /proc/87721/file: No such file or directory\n\n\n\nOn Mon, 8 May 2000, Michael Robinson wrote:\n\n> >Try killing the postmaster itself in such a way as to produce a coredump\n> >(kill -ABORT ought to do) and get a backtrace from that.\n> \n> The \"gcore\" command (on most modern unices) will generate a core dump of a \n> running process without killing the process. It seems that would be more\n> useful in this circumstance.\n> \n> \t-Michael Robinson\n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 8 May 2000 00:41:03 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: It happened again: Server hung up solid " }, { "msg_contents": "Are we still releasing 7.0 tomorrow?\n\n> \n> *sigh*\n> \n> > gcore 87721\n> gcore: /proc/87721/file: No such file or directory\n> \n> \n> \n> On Mon, 8 May 2000, Michael Robinson wrote:\n> \n> > >Try killing the postmaster itself in such a way as to produce a coredump\n> > >(kill -ABORT ought to do) and get a backtrace from that.\n> > \n> > The \"gcore\" command (on most modern unices) will generate a core dump of a \n> > running process without killing the process. It seems that would be more\n> > useful in this circumstance.\n> > \n> > \t-Michael Robinson\n> > \n> \n> Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy\n> Systems Administrator @ hub.org \n> primary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n> \n> \n\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Sun, 7 May 2000 23:47:10 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: It happened again: Server hung up solid" }, { "msg_contents": "On Sun, 7 May 2000, Bruce Momjian wrote:\n\n> Are we still releasing 7.0 tomorrow?\n\nI don't know ... this problem has me nervous, but I can't seem to\nre-create it on the fly :( It happened twice so far today, and I'm\nworking on improving logging to see if I can narrow it down ...\n\nI would like to *at least* postpone until Wednesday to see if I can\nrecreate this between now and then ... will spend a good part of tomorrow\nseeing if I can get a more decent amount of data logged, to narrow her\ndown ...\n\nWe still have to write up a release announcement (can someone summarize\nthe key features of v7.0?), so that gives us a little bit of time ...\n\n\n\n > \n> > \n> > *sigh*\n> > \n> > > gcore 87721\n> > gcore: /proc/87721/file: No such file or directory\n> > \n> > \n> > \n> > On Mon, 8 May 2000, Michael Robinson wrote:\n> > \n> > > >Try killing the postmaster itself in such a way as to produce a coredump\n> > > >(kill -ABORT ought to do) and get a backtrace from that.\n> > > \n> > > The \"gcore\" command (on most modern unices) will generate a core dump of a \n> > > running process without killing the process. It seems that would be more\n> > > useful in this circumstance.\n> > > \n> > > \t-Michael Robinson\n> > > \n> > \n> > Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy\n> > Systems Administrator @ hub.org \n> > primary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n> > \n> > \n> \n> \n> -- \n> Bruce Momjian | http://www.op.net/~candle\n> [email protected] | (610) 853-3000\n> + If your life is a hard drive, | 830 Blythe Avenue\n> + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n> \n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 8 May 2000 01:08:00 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: It happened again: Server hung up solid" }, { "msg_contents": "> On Sun, 7 May 2000, Bruce Momjian wrote:\n> \n> > Are we still releasing 7.0 tomorrow?\n> \n> I don't know ... this problem has me nervous, but I can't seem to\n> re-create it on the fly :( It happened twice so far today, and I'm\n> working on improving logging to see if I can narrow it down ...\n> \n> I would like to *at least* postpone until Wednesday to see if I can\n> recreate this between now and then ... will spend a good part of tomorrow\n> seeing if I can get a more decent amount of data logged, to narrow her\n> down ...\n\nIsn't is something we can fix with a 7.0.1? Seems many people are\nalready using 7.0 in production systems. I just hate to see the date\nslip again.\n\n> \n> We still have to write up a release announcement (can someone summarize\n> the key features of v7.0?), so that gives us a little bit of time ...\n\nWell, you can take it off the top of the HISTORY file.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Mon, 8 May 2000 00:14:21 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: It happened again: Server hung up solid" }, { "msg_contents": "On Mon, 8 May 2000, Bruce Momjian wrote:\n\n> > On Sun, 7 May 2000, Bruce Momjian wrote:\n> > \n> > > Are we still releasing 7.0 tomorrow?\n> > \n> > I don't know ... this problem has me nervous, but I can't seem to\n> > re-create it on the fly :( It happened twice so far today, and I'm\n> > working on improving logging to see if I can narrow it down ...\n> > \n> > I would like to *at least* postpone until Wednesday to see if I can\n> > recreate this between now and then ... will spend a good part of tomorrow\n> > seeing if I can get a more decent amount of data logged, to narrow her\n> > down ...\n> \n> Isn't is something we can fix with a 7.0.1? Seems many people are\n> already using 7.0 in production systems. I just hate to see the date\n> slip again.\n\nAs I said, if we feel comfortable with this, no probs ... its not an issue\nI'm going to push, since it is something that I'm finding relativley\ndifficult to recreate \"at will\" :(\n\n> > We still have to write up a release announcement (can someone summarize\n> > the key features of v7.0?), so that gives us a little bit of time ...\n> \n> Well, you can take it off the top of the HISTORY file.\n\nGreat, will work this up tomorrow during the day :) Thanks ...\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 8 May 2000 01:30:18 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: It happened again: Server hung up solid" }, { "msg_contents": "> > Isn't is something we can fix with a 7.0.1? Seems many people are\n> > already using 7.0 in production systems. I just hate to see the date\n> > slip again.\n> \n> As I said, if we feel comfortable with this, no probs ... its not an issue\n> I'm going to push, since it is something that I'm finding relativley\n> difficult to recreate \"at will\" :(\n> \n> > > We still have to write up a release announcement (can someone summarize\n> > > the key features of v7.0?), so that gives us a little bit of time ...\n> > \n> > Well, you can take it off the top of the HISTORY file.\n> \n> Great, will work this up tomorrow during the day :) Thanks ...\n> \n\nMy feeling is that we can address this in 7.0.1, though our recent\npg_group fix could not be done in 7.0.1, but this doesn't seem like that\nkind of problem. Such problems are usually easily reproducible because\nthey represent problems with the system catalogs.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Mon, 8 May 2000 00:31:08 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: It happened again: Server hung up solid" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n>>>> Are we still releasing 7.0 tomorrow?\n>> \n>> I don't know ... this problem has me nervous, but I can't seem to\n>> re-create it on the fly :( It happened twice so far today, and I'm\n>> working on improving logging to see if I can narrow it down ...\n>> \n>> I would like to *at least* postpone until Wednesday to see if I can\n>> recreate this between now and then ... will spend a good part of tomorrow\n>> seeing if I can get a more decent amount of data logged, to narrow her\n>> down ...\n\n> Isn't is something we can fix with a 7.0.1? Seems many people are\n> already using 7.0 in production systems. I just hate to see the date\n> slip again.\n\nThat's my feeling too. Whatever this is, it seems to be in the\npostmaster not the backend. We've hardly changed the postmaster since\n6.5.3, so I suspect the problem has existed for a good while and is of\nlow probability. (I have no explanation why Marc's suddenly getting\nbit, but if it weren't low-probability we'd surely have more reports\nthan just his, no?)\n\nAlmost certainly, we will need a 7.0.1 in a few weeks, once 7.0 gets out\nthere and starts getting pounded on by people outside the circle of\nusual suspects (sorry, been watching _Casablanca_ again). If we delay\n7.0 until we can figure out what this bug is all about, we might be\nsitting on it for days or weeks. Let's push 7.0 out the door and let\nsome other work go on in parallel while we try to figure out this one.\n\nMarc, if you see it happen again could you give me a call before you\nrestart? I'd like to telnet in and poke at it a little myself.\n(Wait a sec, is this happening on hub, or somewhere else?)\n\n\t\t\tregards, tom lane\n", "msg_date": "Mon, 08 May 2000 02:32:24 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: It happened again: Server hung up solid " }, { "msg_contents": "On Mon, 8 May 2000, The Hermit Hacker wrote:\n\n> \n> *sigh*\n> \n> > gcore 87721\n> gcore: /proc/87721/file: No such file or directory\n\nAccroding to TFM:\n\n The process identifier, pid, must be given on the command line. If no\n executable image is specified, gcore will use ``/proc/<pid>/file''.\n\nSo you might try:\n\ngcore /path_to_postmaster/postmaster 87721\n\nor something close to that.\n\nVince.\n\n> \n> \n> \n> On Mon, 8 May 2000, Michael Robinson wrote:\n> \n> > >Try killing the postmaster itself in such a way as to produce a coredump\n> > >(kill -ABORT ought to do) and get a backtrace from that.\n> > \n> > The \"gcore\" command (on most modern unices) will generate a core dump of a \n> > running process without killing the process. It seems that would be more\n> > useful in this circumstance.\n> > \n> > \t-Michael Robinson\n> > \n> \n> Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy\n> Systems Administrator @ hub.org \n> primary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n> \n> \n\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Mon, 8 May 2000 06:10:25 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: It happened again: Server hung up solid " }, { "msg_contents": "On Mon, 8 May 2000, Tom Lane wrote:\n\n> Marc, if you see it happen again could you give me a call before you\n> restart? I'd like to telnet in and poke at it a little myself.\n> (Wait a sec, is this happening on hub, or somewhere else?)\n\nWe built a Dual-PIII server to handle just database server, so I can give\nyou access to it ... \n\n\n", "msg_date": "Mon, 8 May 2000 08:46:29 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: It happened again: Server hung up solid " }, { "msg_contents": "Thus spake The Hermit Hacker\n> > Marc, if you see it happen again could you give me a call before you\n> > restart? I'd like to telnet in and poke at it a little myself.\n> > (Wait a sec, is this happening on hub, or somewhere else?)\n> \n> We built a Dual-PIII server to handle just database server, so I can give\n> you access to it ... \n\nAre you talking about the new database server for Trends? If so I should\nmention that I had to restart it this morning. Sorry, I didn't poke\naround in it before doing so. Clients couldn't log in and I couldn't wait.\n\nI should mention that I did have to kill -9 it. A simple kill didn't work.\nI then cleared out the lock file and restarted it and connections seem to\nbe working again.\n\n-- \nD'Arcy J.M. Cain <darcy@{druid|vex}.net> | Democracy is three wolves\nhttp://www.druid.net/darcy/ | and a sheep voting on\n+1 416 425 1212 (DoD#0082) (eNTP) | what's for dinner.\n", "msg_date": "Mon, 8 May 2000 08:09:31 -0400 (EDT)", "msg_from": "[email protected] (D'Arcy J.M. Cain)", "msg_from_op": false, "msg_subject": "Re: Re: It happened again: Server hung up solid" }, { "msg_contents": "On Mon, 8 May 2000, D'Arcy J.M. Cain wrote:\n\n> Thus spake The Hermit Hacker\n> > > Marc, if you see it happen again could you give me a call before you\n> > > restart? I'd like to telnet in and poke at it a little myself.\n> > > (Wait a sec, is this happening on hub, or somewhere else?)\n> > \n> > We built a Dual-PIII server to handle just database server, so I can give\n> > you access to it ... \n> \n> Are you talking about the new database server for Trends? If so I\n> should mention that I had to restart it this morning. Sorry, I didn't\n> poke around in it before doing so. Clients couldn't log in and I\n> couldn't wait.\n> \n> I should mention that I did have to kill -9 it. A simple kill didn't\n> work. I then cleared out the lock file and restarted it and\n> connections seem to be working again.\n\nThat's the server ... and that's the key problem ... there are apps\nrunning on here that are such that delaying the restart, when it requires\nit, is very difficult :(\n\nD'Arcy, when it happens again, and if you catch it before me, can you run:\n\n\tgcore -s bin/postmaster <pid>\n\non it as the pgsql user before restarting it? I just tested it here and\nit dump'd core nicely ... I'm hoping it does the same if/when the\npostmaster itself hangs *cross fingers*\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 8 May 2000 09:22:08 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: It happened again: Server hung up solid" }, { "msg_contents": "Thus spake The Hermit Hacker\n> D'Arcy, when it happens again, and if you catch it before me, can you run:\n> \n> \tgcore -s bin/postmaster <pid>\n> \n> on it as the pgsql user before restarting it? I just tested it here and\n> it dump'd core nicely ... I'm hoping it does the same if/when the\n> postmaster itself hangs *cross fingers*\n\nWill do.\n\n-- \nD'Arcy J.M. Cain <darcy@{druid|vex}.net> | Democracy is three wolves\nhttp://www.druid.net/darcy/ | and a sheep voting on\n+1 416 425 1212 (DoD#0082) (eNTP) | what's for dinner.\n", "msg_date": "Mon, 8 May 2000 08:44:00 -0400 (EDT)", "msg_from": "[email protected] (D'Arcy J.M. Cain)", "msg_from_op": false, "msg_subject": "Re: Re: It happened again: Server hung up solid" }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> We still have to write up a release announcement (can someone summarize\n> the key features of v7.0?), so that gives us a little bit of time ...\n\nMan, there's a lot of stuff in the HISTORY file, isn't there?\nThe list at the top isn't too bad:\n\n Foreign Keys\n Foreign keys are now implemented, with the exception of PARTIAL\n MATCH foreign keys. Many users have been asking for this\n feature, and we are pleased to offer it.\n \n Optimizer Overhaul\n Continuing on work started a year ago, the optimizer has been\n overhauled, allowing improved query execution and better\n performance with less memory usage.\n \n Updated psql\n psql, our interactive terminal monitor, has been updated with a\n variety of new features. See the psql manual page for details.\n \n Upcoming Features\n In 7.1, we plan to have outer joins, storage for very long\n rows, and a write-ahead logging system.\n\nSome other things that might be worth mentioning:\n\n Date/time datatypes cleaned up\n\t We have brought the date/time datatypes into compliance with\n\t the SQL standard, replacing the old partially-implemented SQL\n\t date/time types with full-featured implementations. The\n\t default display format for date/time data has also changed\n\t to be ISO style. This may create a few compatibility issues\n\t for old applications. [Thomas may want to rewrite this item...]\n\n Query length limits removed\n\t There is no longer any fixed limit on the length of a query\n\t string. (The block-size limit on the length of a stored row\n\t still exists, but we hope to fix that in 7.1.)\n\n Removal of 8-argument limit on index keys and functions\n\t The maximum number of keys in an index or arguments to a\n\t function is now configurable, with default limit of 16,\n\t rather than the old hard-coded limit of 8.\n\n Sorts and hashes now work for >2GB of data\n\t Temporary files can now be split in the same way that oversize\n\t relations are, so that data volume is only limited by\n\t available disk space and not by OS limits on the size of an\n\t individual file.\n\nIt wouldn't be hard to make this list a *lot* longer, but...\n\nYou should also make a point of the literally hundreds of smaller\nfeatures, bug fixes, and performance improvements that are in this\nrelease.\n\n\t\t\tregards, tom lane\n", "msg_date": "Mon, 08 May 2000 15:10:51 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "7.0 key features" }, { "msg_contents": "> Upcoming Features\n> In 7.1, we plan to have outer joins, storage for very long\n> rows, and a write-ahead logging system.\n\nOh BTW, *are* we still planning outer joins for 7.1? I thought the plan\nwas to push out the querytree redesign to 7.2, and try to have a fairly\nshort release cycle for 7.1 instead, with TOAST and WAL as the\ncenterpiece attractions.\n\n\t\t\tregards, tom lane\n", "msg_date": "Mon, 08 May 2000 15:17:57 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 key features " }, { "msg_contents": " Query length limits removed\n There is no longer any fixed limit on the length of a query\n string. (The block-size limit on the length of a stored row\n still exists, but we hope to fix that in 7.1.)\n \n\nIs the row length limit 8k? If not, what is the row length limit?\n\nThanks!\n\n- Mitch\n\n\n", "msg_date": "Mon, 8 May 2000 15:24:49 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 key features" }, { "msg_contents": "\"Mitch Vincent\" <[email protected]> writes:\n> Is the row length limit 8k? If not, what is the row length limit?\n\nWell, it's BLCKSZ less some overhead --- BLCKSZ is 8K in a stock\ninstallation ...\n\n\t\t\tregards, tom lane\n", "msg_date": "Mon, 08 May 2000 15:24:53 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 key features " }, { "msg_contents": "On Mon, 8 May 2000, Mitch Vincent wrote:\n\n> Query length limits removed\n> There is no longer any fixed limit on the length of a query\n> string. (The block-size limit on the length of a stored row\n> still exists, but we hope to fix that in 7.1.)\n> \n> \n> Is the row length limit 8k? If not, what is the row length limit?\n\nRight now, the tuple length is still at 8k ... Jan's TOAST implementation\nis designed to finally rid us of that as well ...\n\n\n", "msg_date": "Mon, 8 May 2000 16:27:07 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 key features" }, { "msg_contents": "Mitch Vincent wrote:\n> \n> Query length limits removed\n> There is no longer any fixed limit on the length of a query\n> string. (The block-size limit on the length of a stored row\n> still exists, but we hope to fix that in 7.1.)\n> \n> \n> Is the row length limit 8k? If not, what is the row length limit?\n\n8k by default, max is 32K if you recompile-\n\n> \n> Thanks!\n> \n> - Mitch\n", "msg_date": "Mon, 08 May 2000 22:39:43 +0300", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 key features" }, { "msg_contents": "Vince Vielhaber wrote:\n> \n> On Mon, 8 May 2000, D'Arcy J.M. Cain wrote:\n> \n> > It would kind of have to be, wouldn't it, if the row it had to fit in\n> > had that limit?\n> \n> BLOBs aren't. Or did I miss something somewhere? I've always understood\n> the text datatype to be simply a text version of a BLOB.\n\nNot yet in Postgres\n\n> Not necessarily in Postgres, but elsewhere.\n\nMaybe elsewere.\n\nIn postgres it will be a new kind of (B)LOB, different from current LOs.\n\nCurrent LOs are again separate from TEXT even ODBC and JDBC use them for \nother BLOB support.\n\n---------------\nHannu\n", "msg_date": "Mon, 08 May 2000 22:47:09 +0300", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 key features" }, { "msg_contents": "On Mon, 8 May 2000, Tom Lane wrote:\n\n> \"Mitch Vincent\" <[email protected]> writes:\n> > Is the row length limit 8k? If not, what is the row length limit?\n> \n> Well, it's BLCKSZ less some overhead --- BLCKSZ is 8K in a stock\n> installation ...\n\nA text datatype isn't limited to that too, is it?\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Mon, 8 May 2000 16:16:47 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 key features " }, { "msg_contents": "Thus spake Vince Vielhaber\n> On Mon, 8 May 2000, Tom Lane wrote:\n> \n> > \"Mitch Vincent\" <[email protected]> writes:\n> > > Is the row length limit 8k? If not, what is the row length limit?\n> > \n> > Well, it's BLCKSZ less some overhead --- BLCKSZ is 8K in a stock\n> > installation ...\n> \n> A text datatype isn't limited to that too, is it?\n\nIt would kind of have to be, wouldn't it, if the row it had to fit in\nhad that limit?\n\n-- \nD'Arcy J.M. Cain <darcy@{druid|vex}.net> | Democracy is three wolves\nhttp://www.druid.net/darcy/ | and a sheep voting on\n+1 416 425 1212 (DoD#0082) (eNTP) | what's for dinner.\n", "msg_date": "Mon, 8 May 2000 16:33:02 -0400 (EDT)", "msg_from": "[email protected] (D'Arcy J.M. Cain)", "msg_from_op": false, "msg_subject": "Re: 7.0 key features" }, { "msg_contents": "On Mon, 8 May 2000, D'Arcy J.M. Cain wrote:\n\n> Thus spake Vince Vielhaber\n> > On Mon, 8 May 2000, Tom Lane wrote:\n> > \n> > > \"Mitch Vincent\" <[email protected]> writes:\n> > > > Is the row length limit 8k? If not, what is the row length limit?\n> > > \n> > > Well, it's BLCKSZ less some overhead --- BLCKSZ is 8K in a stock\n> > > installation ...\n> > \n> > A text datatype isn't limited to that too, is it?\n> \n> It would kind of have to be, wouldn't it, if the row it had to fit in\n> had that limit?\n\nBLOBs aren't. Or did I miss something somewhere? I've always understood\nthe text datatype to be simply a text version of a BLOB. Not necessarily\nin Postgres, but elsewhere.\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Mon, 8 May 2000 16:39:30 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 key features" }, { "msg_contents": "This brings me to another question. Hopefully there isn't a 8k (max 32k)\nlimit on TEXT fields -- I'll assume there isn't a limit on TEXT fields for\nthe purpose of this email..\n\nWhat do you guys think of storing whole text files (normally stored in a\nflat file) in the database for searching purposes? Would a search on an\nindexed TEXT field be slow as mud?\n\nI'll try it on my home machine for kicks, just wanted to get some\ntheoretical opinions...\n\nThanks!\n\n- Mitch\n\n\"The only real failure is quitting.\"\n\n> > Is the row length limit 8k? If not, what is the row length limit?\n>\n> 8k by default, max is 32K if you recompile-\n\n\n", "msg_date": "Mon, 8 May 2000 16:51:20 -0400", "msg_from": "\"Mitch Vincent\" <[email protected]>", "msg_from_op": false, "msg_subject": "TEXT question... Was 7.0 key features" }, { "msg_contents": "Mitch Vincent wrote:\n> \n> This brings me to another question. Hopefully there isn't a 8k (max 32k)\n> limit on TEXT fields -- \n\nNo, they currently just have to fit in a record ;)\n\nThey will be stored (optionally) separately in future (7.1)\n\n> \n> What do you guys think of storing whole text files (normally stored in a\n> flat file) in the database for searching purposes? Would a search on an\n> indexed TEXT field be slow as mud?\n\nDepends on search ;)\n\nlike \"a%\" may not be too slow (unless the indexes on text field will be \ndisallowed initially, as has been mentioned some times)\n\nPG does not yet have a native full-text index. There is a suboptimal\nimplementation using triggers and extra tables in contrib.\n\n----------\nHannu\n", "msg_date": "Tue, 09 May 2000 00:49:21 +0300", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": false, "msg_subject": "Re: TEXT question... Was 7.0 key features" }, { "msg_contents": "Thus spake Vince Vielhaber\n> > > > Well, it's BLCKSZ less some overhead --- BLCKSZ is 8K in a stock\n> > > > installation ...\n> > > \n> > > A text datatype isn't limited to that too, is it?\n> > \n> > It would kind of have to be, wouldn't it, if the row it had to fit in\n> > had that limit?\n> \n> BLOBs aren't. Or did I miss something somewhere? I've always understood\n> the text datatype to be simply a text version of a BLOB. Not necessarily\n> in Postgres, but elsewhere.\n\nYou mean text FILES, not datatype. There is a base type called text\nwhich has to fit in the row so it is naturally limited to the row size.\n\n-- \nD'Arcy J.M. Cain <darcy@{druid|vex}.net> | Democracy is three wolves\nhttp://www.druid.net/darcy/ | and a sheep voting on\n+1 416 425 1212 (DoD#0082) (eNTP) | what's for dinner.\n", "msg_date": "Mon, 8 May 2000 18:15:47 -0400 (EDT)", "msg_from": "[email protected] (D'Arcy J.M. Cain)", "msg_from_op": false, "msg_subject": "Re: 7.0 key features" }, { "msg_contents": "> > Upcoming Features\n> > In 7.1, we plan to have outer joins, storage for very long\n> > rows, and a write-ahead logging system.\n> \n> Oh BTW, *are* we still planning outer joins for 7.1? I thought the plan\n> was to push out the querytree redesign to 7.2, and try to have a fairly\n> short release cycle for 7.1 instead, with TOAST and WAL as the\n> centerpiece attractions.\n\nOops, you are right. At the time I wrote this, we were going to do a\nnormal period 7.1.\n\nI have updated the HISTORY and release.sgml to say 7.1 _or_ 7.2.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Mon, 8 May 2000 19:53:16 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: 7.0 key features" }, { "msg_contents": "> Man, there's a lot of stuff in the HISTORY file, isn't there?\n> The list at the top isn't too bad:\n\nAck! I didn't realize that there was a plain text HISTORY file, since\nit *should* come from the SGML sources. I had changed the wording, and\neliminated the prediction for features in the next release (that\nshould appear on the web site imho, not in the release docs).\n\nCheck the release notes (INSTALL and release.htm) for the latest\nwording.\n\nLet me see if I can get the HISTORY file replaced with something\nfresh; however, it is not a show-stopper so if you've already done the\nbuild don't worry about it.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Tue, 09 May 2000 05:30:10 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 key features" }, { "msg_contents": "> > Man, there's a lot of stuff in the HISTORY file, isn't there?\n> > The list at the top isn't too bad:\n> \n> Ack! I didn't realize that there was a plain text HISTORY file, since\n> it *should* come from the SGML sources. I had changed the wording, and\n> eliminated the prediction for features in the next release (that\n> should appear on the web site imho, not in the release docs).\n\nI have been changing both each time. History does not generate\ndirectly from SGML because it needs to be one big file with proper\nbreaks between sections.\n\nI left the prediction in because this is not a big-feature release, and\nI wanted people to know what we were planning. This is the first\nrelease where we have definate plans for new features in the next\nrelease.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 9 May 2000 08:20:00 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 key features" }, { "msg_contents": "> I left the prediction in because this is not a big-feature release, and\n> I wanted people to know what we were planning. This is the first\n> release where we have definate plans for new features in the next\n> release.\n\nSeems most appropriate to put this info on the web site, where it is\nless formal and more easily changed/updated/removed. We already could\nbe mentioning the TOAST work, etc etc as ongoing projects and outer\njoins are in that category too.\n\nVince, is there a place where we could put this kind of stuff?\nSomewhere in the developer's lounge area? Perhaps a summary page of\nongoing projects and then links to specific pages for each project\nwhere necessary?\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Tue, 09 May 2000 13:37:46 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 key features" }, { "msg_contents": "On Tue, 9 May 2000, Thomas Lockhart wrote:\n\n> > I left the prediction in because this is not a big-feature release, and\n> > I wanted people to know what we were planning. This is the first\n> > release where we have definate plans for new features in the next\n> > release.\n> \n> Seems most appropriate to put this info on the web site, where it is\n> less formal and more easily changed/updated/removed. We already could\n> be mentioning the TOAST work, etc etc as ongoing projects and outer\n> joins are in that category too.\n> \n> Vince, is there a place where we could put this kind of stuff?\n> Somewhere in the developer's lounge area? Perhaps a summary page of\n> ongoing projects and then links to specific pages for each project\n> where necessary?\n\nAlready is: http://www.Postgresql.org/projects/index.html Jan's\nbeen maintaining it. The projects on that page aren't necessarily\nplanned for the next release tho (what's there now very well might \nbe but that's not the intent of the page), so we may want to have\na more specific list pointing there.\n\nBTW, I'm currently waiting on some graphics (already have some) to \nput the Developer's Corner and User's Lounge online. With some out\nof town travel coming up I may not be able to get it online till \nthe beginning of June tho.\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Tue, 9 May 2000 10:01:09 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 key features" } ]
[ { "msg_contents": "\n> The current thread started from a simple the need to hide passwords \n> from PG superusers and system ROOT's. For that we have two schemes:\n> \n> store MD5(username+passwd)\n> - hidden from sniffing but easily guessable salt (as most users are\n> called 'bob')\n\nI have not checked, but imho it will be easy to find out the username \nwith some extra sniffing. Thus to assume that the username is a secret\nis probably a bad assumption.\nWalking through all user entries to find a matching md5 is imho \nunacceptable anyway, since md5 is a hash an thus has the \npotential for equal output with different input.\n\nThe only argument for some calculateable salt would imho be\nif it saves us one packet roundtrip. And this is only possible if we\ndon't do the challenge (which still is a variant imho, since we agreed \nthat good sniffer protection needs to be done differently).\n\nThus:\nC-->S: connect dbname username MD5(calculated_salt+password) \nS-->C: connection accepted\n\nAndreas\n", "msg_date": "Mon, 8 May 2000 11:07:54 +0200 ", "msg_from": "Zeugswetter Andreas SB <[email protected]>", "msg_from_op": true, "msg_subject": "AW: So we're in agreement...." } ]
[ { "msg_contents": "Hi everyone!\n\nSince v 7.0, there's no more functions like abstime_datetime(int4) and\nreltime_timespan(int4).\n\nThus contrib/unixdate giving datetime(int4) for example is not functional\nanymore.\n\nWhat would be the best way to get abstime(int4) back??\n\nRegs,\n\n-- \nOlivier PRENANT \tTel:\t+33-5-61-50-97-00 (Work)\nQuartier d'Harraud Turrou +33-5-61-50-97-01 (Fax)\n31190 AUTERIVE +33-6-07-63-80-64 (GSM)\nFRANCE Email: [email protected]\n------------------------------------------------------------------------------\nMake your life a dream, make your dream a reality. (St Exupery)\n\n", "msg_date": "Mon, 8 May 2000 13:12:48 +0200 (MET DST)", "msg_from": "Olivier PRENANT <[email protected]>", "msg_from_op": true, "msg_subject": "Unix timestamp" } ]
[ { "msg_contents": "\nJust lookign through elog.c to see how I can improve logging, so taht I\ncan get more information from the backend. We have the above mentioned\nUSE_SYSLOG in a few places:\n\npgsql% find . -name \"*.[ch]\" -exec grep USE_SYSLOG {} \\; -print\n#ifdef USE_SYSLOG\n#ifdef USE_SYSLOG\n#ifdef USE_SYSLOG\n#ifdef USE_SYSLOG\n./backend/utils/error/elog.c\n#ifdef USE_SYSLOG\n#ifdef USE_SYSLOG\n#ifdef USE_SYSLOG\n#ifdef USE_SYSLOG\n#ifdef USE_SYSLOG\n#ifdef USE_SYSLOG\n#ifdef USE_SYSLOG\n./backend/utils/misc/trace.c\n\nBut nowhere to actually define it (not even listed in config.h.in) ...\n\npg_options shows a 'syslog=2' capability, but, without SysLOG enabled, its\nsort of useless ...\n\nwhat I want to get is a PID/Timestamp in the log files ... suggestions?\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 8 May 2000 10:09:14 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "USE_SYSLOG ... useless? :)" }, { "msg_contents": "The Hermit Hacker wrote:\n \n> But nowhere to actually define it (not even listed in config.h.in) ...\n \n> pg_options shows a 'syslog=2' capability, but, without SysLOG enabled, its\n> sort of useless ...\n \n> what I want to get is a PID/Timestamp in the log files ... suggestions?\n\nDefine USE_SYSLOG and ELOG_TIMESTAMPS in config.h.in (or config.h,\ndepending upon your preference to patching prior to or after running\nconfigure). This is the default compile for the RPM's, incidentally.\n\nI'm surprized no one else answered -- I figured you'd have your answer\nby now.\n\n--\nLamar Owen\nWGCR Internet Radio\n1 Peter 4:11\n", "msg_date": "Mon, 08 May 2000 20:23:08 -0400", "msg_from": "Lamar Owen <[email protected]>", "msg_from_op": false, "msg_subject": "Re: USE_SYSLOG ... useless? :)" } ]
[ { "msg_contents": "\nI enabled 'connection tracing' the other day, like Tom asked, and am\nwondering if its normal for me to be able to sit on a 'tail -f' of my log\nfile and just watch these scroll up the screen? I'm not getting a\nconnection per second, or faster, here, yet this is what I *think* this is\nindicating?\n\nFindExec: found \"/pgsql/bin/postgres\" using argv[0]\nFindExec: found \"/pgsql/bin/postgres\" using argv[0]\nFindExec: found \"/pgsql/bin/postgres\" using argv[0]\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 8 May 2000 10:13:08 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "FindExec: found \"/pgsql/bin/postgres\" using argv[0]" } ]
[ { "msg_contents": "\nOkay, I'm at a loss here ... I'm trying to futz with pg_options, based on\nthe docs in users-lounge/7.0/docs, and with:\n\npgsql% cat data/pg_options\nverbose=2\nquery\nhostlookup\nshowportnumber\n\nAll I'm getting in my log file is this continuously scrolling:\n\nFindExec: found \"/pgsql/bin/postgres\" using argv[0]\nFindExec: found \"/pgsql/bin/postgres\" using argv[0]\nFindExec: found \"/pgsql/bin/postgres\" using argv[0]\nFindExec: found \"/pgsql/bin/postgres\" using argv[0]\nFindExec: found \"/pgsql/bin/postgres\" using argv[0]\n\neven if I issue a query through psql, that is all I see ...\n\nIs this broken? *raised eyebrow*\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 8 May 2000 10:17:36 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "logging problem ... ?" }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> All I'm getting in my log file is this continuously scrolling:\n\n> FindExec: found \"/pgsql/bin/postgres\" using argv[0]\n> FindExec: found \"/pgsql/bin/postgres\" using argv[0]\n\nWell, that shows you're launching backends anyway ;-)\n\nIt looks like the backends are receiving -d 1 from the postmaster,\nbut where is the postmaster's own debug output? Weird. How exactly\nare you starting the postmaster, again?\n\n\t\t\tregards, tom lane\n", "msg_date": "Mon, 08 May 2000 12:28:17 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: logging problem ... ? " }, { "msg_contents": "On Mon, 8 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> > All I'm getting in my log file is this continuously scrolling:\n> \n> > FindExec: found \"/pgsql/bin/postgres\" using argv[0]\n> > FindExec: found \"/pgsql/bin/postgres\" using argv[0]\n> \n> Well, that shows you're launching backends anyway ;-)\n\nYa, but, from what i can tell, there are not as many backends being\nstarted as that scrolling list of 'FindExec's appear to be indicating\n... the server isn't *that* busy ...\n\n> It looks like the backends are receiving -d 1 from the postmaster,\n> but where is the postmaster's own debug output? Weird. How exactly\n> are you starting the postmaster, again?\n\ncat ~pgsql/pgstart ... postmaster's own debug output? ya know, for some\nstupid reason, the only thing i'm capturing is postgres's output :( I\njust modified the pgstart script and restarted the server, so postmaster's\noutput is to logs/postmaster.5432 ...\n\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 8 May 2000 14:01:49 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: logging problem ... ? " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> cat ~pgsql/pgstart ... postmaster's own debug output? ya know, for some\n> stupid reason, the only thing i'm capturing is postgres's output :( I\n> just modified the pgstart script and restarted the server, so postmaster's\n> output is to logs/postmaster.5432 ...\n\nOh, I see the problem! It's the -S in the postmaster switches:\n\n${POSTMASTER} -d 1 -B 4096 -N 128 -S \\\n ^^\n\nThat redirects postmaster's stdout/stderr to /dev/null, so you never\nsee anything in its log except for a message or two that comes out\nbefore -S is processed. Instead of -S you should be using\n\nnohup ${POSTMASTER} same-switches-except-S \\\n\t</dev/null >& logs/postmaster.${PORT} &\n\n(I'm not sure if redirecting stdin to /dev/null is really necessary on\nyour OS, but it is on mine.)\n\n\t\t\tregards, tom lane\n", "msg_date": "Mon, 08 May 2000 13:23:50 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: logging problem ... ? " }, { "msg_contents": "\nD'oh ... there ya go, lotsa days flying through now ... \n\nOn Mon, 8 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> > cat ~pgsql/pgstart ... postmaster's own debug output? ya know, for some\n> > stupid reason, the only thing i'm capturing is postgres's output :( I\n> > just modified the pgstart script and restarted the server, so postmaster's\n> > output is to logs/postmaster.5432 ...\n> \n> Oh, I see the problem! It's the -S in the postmaster switches:\n> \n> ${POSTMASTER} -d 1 -B 4096 -N 128 -S \\\n> ^^\n> \n> That redirects postmaster's stdout/stderr to /dev/null, so you never\n> see anything in its log except for a message or two that comes out\n> before -S is processed. Instead of -S you should be using\n> \n> nohup ${POSTMASTER} same-switches-except-S \\\n> \t</dev/null >& logs/postmaster.${PORT} &\n> \n> (I'm not sure if redirecting stdin to /dev/null is really necessary on\n> your OS, but it is on mine.)\n> \n> \t\t\tregards, tom lane\n> \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 8 May 2000 14:30:00 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: logging problem ... ? " }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> D'oh ... there ya go, lotsa days flying through now ... \n\nAh, much better. You just *thought* you weren't launching a backend\nevery second or so :-)\n\nKinda looks like the backend -o switch doesn't redirect as much as\nI would've thought --- most of the backend's debug output is coming\nout in the postmaster log not the other file. Something to look at\nlater.\n\n\t\t\tregards, tom lane\n", "msg_date": "Mon, 08 May 2000 13:36:30 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: logging problem ... ? " }, { "msg_contents": "On Mon, 8 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> > D'oh ... there ya go, lotsa days flying through now ... \n> \n> Ah, much better. You just *thought* you weren't launching a backend\n> every second or so :-)\n\ntell me about it ... now, if it were possible to redirect each backend to\na seperate file, so that I had X files pertaining to what happened through\nthat backend, that would be cool ... maybe play with v7.1 on this one :)\n\n> Kinda looks like the backend -o switch doesn't redirect as much as\n> I would've thought --- most of the backend's debug output is coming\n> out in the postmaster log not the other file. Something to look at\n> later.\n\n*nod*\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 8 May 2000 14:47:56 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: logging problem ... ? " }, { "msg_contents": "The Hermit Hacker writes:\n\n> tell me about it ... now, if it were possible to redirect each backend to\n> a seperate file, so that I had X files pertaining to what happened through\n> that backend, that would be cool ... maybe play with v7.1 on this one :)\n\nYou can compile with ELOG_TIMESTAMPS to tag each log message with a pid\n(besides the timestamp).\n\n> > Kinda looks like the backend -o switch doesn't redirect as much as\n> > I would've thought --- most of the backend's debug output is coming\n> > out in the postmaster log not the other file. Something to look at\n> > later.\n\nThis might explain it:\n\npeter ~/pgsql/src/backend$ find -name '*.c' | \\\n xargs egrep 'fprintf *\\(stderr' | wc -l\n 232\n\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Tue, 9 May 2000 22:51:38 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: logging problem ... ? " } ]
[ { "msg_contents": "Hi all:\n\n\tWell, after my earlier post regarding pg_operator being corrupted, I\nreceived a mail from one of the Postgres developers (I think) talking\nabout one of the system indexes (pg_attribute_relid_attnum_index) being\ncorrupted, so I gave it a try and copied said file from the template1\ndatabase to the one I have to recover... and now it gives me another\nerror: \"cannot find attribute 1 of relation pg_user\". Like before, I\ncan't even do a \\d to see the existing tables in the database, much less\ninsert/update anything in the pg_* tables to fix it, and after\nstruggling the whole morning with it, I have pretty much given up on\nthat path.\n\tI am trying now to:\n\n\t1) Re-create the database in another machine.\n\t2) Copy the binary files that contain the tables (minus the pg_* ones)\nto the other server, in the place where the new database has been\ncreated ($PGDATA/base/$dbname).\n\t3) Try to access the tables from there using psql.\n\n\tThe problem now is that, although I can view the tables correctly, they\nall come up as empty. All the SELECTs I try on them return nothing. And\nthe strange thing is that pg_class.reltuples says that said table has\n5478 tuples, which is correct.\n\tAny other ideas? Is there any other way to access the binary files and\nextract the information in them to text? My manager is starting to talk\nabout migrating to SQL Server, and frankly, at this point I'm finding\nless and less arguments to counter him...\n\n\n\t\t\t\t\t\tPaulo Jan.\n\t\t\t\t\t\tDDnet.\n", "msg_date": "Mon, 08 May 2000 16:59:37 +0200", "msg_from": "Paulo Jan <[email protected]>", "msg_from_op": true, "msg_subject": "Recovering data from binary files?" }, { "msg_contents": "> -----Original Message-----\n> From: [email protected] \n> [mailto:[email protected]]On Behalf Of Paulo Jan\n> Sent: Tuesday, May 09, 2000 12:00 AM\n> To: [email protected]\n> Cc: [email protected]\n> Subject: [GENERAL] Recovering data from binary files?\n> \n> \n> Hi all:\n> \n> \tWell, after my earlier post regarding pg_operator being corrupted, I\n> received a mail from one of the Postgres developers (I think) talking\n> about one of the system indexes (pg_attribute_relid_attnum_index) being\n> corrupted, so I gave it a try and copied said file from the template1\n> database to the one I have to recover... and now it gives me another\n> error: \"cannot find attribute 1 of relation pg_user\". Like before, I\n> can't even do a \\d to see the existing tables in the database, much less\n> insert/update anything in the pg_* tables to fix it, and after\n> struggling the whole morning with it, I have pretty much given up on\n> that path.\n> \tI am trying now to:\n> \n> \t1) Re-create the database in another machine.\n> \t2) Copy the binary files that contain the tables (minus the \n> pg_* ones)\n> to the other server, in the place where the new database has been\n> created ($PGDATA/base/$dbname).\n\nOh it seems almost same as pg_upgrade.\nHowever you should probably copy pg_log and pg_variable to\n$PGDATA as pg_upgrade does.\nIn addtion if postmaster is running,you should shutdown before\nprocessing 2).\n\nRegards.\n\nHiroshi Inoue\[email protected]\n\n> \t3) Try to access the tables from there using psql.\n> \n> \tThe problem now is that, although I can view the tables \n> correctly, they\n> all come up as empty. All the SELECTs I try on them return nothing. And\n> the strange thing is that pg_class.reltuples says that said table has\n> 5478 tuples, which is correct.\n> \tAny other ideas? Is there any other way to access the \n> binary files and\n> extract the information in them to text? My manager is starting to talk\n> about migrating to SQL Server, and frankly, at this point I'm finding\n> less and less arguments to counter him...\n> \n> \n> \t\t\t\t\t\tPaulo Jan.\n> \t\t\t\t\t\tDDnet.\n> \n", "msg_date": "Tue, 9 May 2000 00:47:38 +0900", "msg_from": "\"Hiroshi Inoue\" <[email protected]>", "msg_from_op": false, "msg_subject": "RE: Recovering data from binary files?" }, { "msg_contents": "> \n> Oh it seems almost same as pg_upgrade.\n> However you should probably copy pg_log and pg_variable to\n> $PGDATA as pg_upgrade does.\n> In addtion if postmaster is running,you should shutdown before\n> processing 2).\n> \n> Regards.\n> \n\n\tWell. It worked!!! The database was succesfully recovered.\n\tThanks a lot.\n\n\n\t\t\t\t\t\tPaulo Jan.\n\t\t\t\t\t\tDDnet.\n", "msg_date": "Mon, 08 May 2000 19:05:09 +0200", "msg_from": "Paulo Jan <[email protected]>", "msg_from_op": true, "msg_subject": "Miracle" }, { "msg_contents": "I have been looking around for the RPM for 7.0 anyone have a quick link?\n\nThanks,\nJ\n\n", "msg_date": "Tue, 09 May 2000 18:52:39 -0400", "msg_from": "\"J. Atwood\" <[email protected]>", "msg_from_op": false, "msg_subject": "7.0 RPM?" }, { "msg_contents": "\"J. Atwood\" wrote:\n\n> I have been looking around for the RPM for 7.0 anyone have a quick link?\n>\n> Thanks,\n> J\n\nnot in any way official, but I did a cheap knock off of the 7.0RC1 rpms.\nYou should be able to pick them up at karl.debisschop.net/src/postgres/\n\nThese are based on RPMs by Lamar Owen at\nhttp://www.ramifordistat.net/postgres/beta/SRPMS - I've really added\nnothing (though I expect to have build of the plperl procedural language by\ntomorrow). In fact I'd guess that the reason I can post this before Lamar\nis because he is trying to improve the existing RPMS, whereas I just wanted\nto start running 7.0 on some development machines as soon as possible.\nTesting is limited, but I've deployed this successfully. He has SRPMs for\nRC5 at his site, but not the final yet.\n\nIf you do use these. plan on upgrading once Lamar releases his final. But\nyou should be able to do that without a dump/restore cycle, which was my\nprime concern.\n\nKarl DeBisschop\n\n", "msg_date": "Tue, 09 May 2000 22:25:31 -0400", "msg_from": "Karl DeBisschop <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 RPM?" }, { "msg_contents": "Karl DeBisschop <[email protected]> writes:\n> If you do use these. plan on upgrading once Lamar releases his final. But\n> you should be able to do that without a dump/restore cycle, which was my\n> prime concern.\n\n7.0RC5 is database-compatible with the final, earlier betas are *not*.\nYou can use pg_upgrade to update from any 6.5-or-later version if you\nare feeling adventurous, but I'd definitely suggest making a backup\nfirst in case things go wrong and you have to initdb and restore.\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 10 May 2000 00:31:03 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 RPM? " }, { "msg_contents": "Tom Lane wrote:\n\n> Karl DeBisschop <[email protected]> writes:\n> > If you do use these. plan on upgrading once Lamar releases his final. But\n> > you should be able to do that without a dump/restore cycle, which was my\n> > prime concern.\n>\n> 7.0RC5 is database-compatible with the final, earlier betas are *not*.\n> You can use pg_upgrade to update from any 6.5-or-later version if you\n> are feeling adventurous, but I'd definitely suggest making a backup\n> first in case things go wrong and you have to initdb and restore.\n>\n> regards, tom lane\n\nSorry if I was not clear. The RPMs I prepared use Lamar Owen spec from RC1,\nbut use final release sources. Upgrading from final release to final release\nshould not be a problem, I think. I only recommended it because I understand\nfrom his recent posts sthat Lamar has many inprovements to the RPM install\nscript that I have not taken advantage of.\n\nKarl\n\n", "msg_date": "Wed, 10 May 2000 09:21:12 -0400", "msg_from": "Karl DeBisschop <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 RPM?" }, { "msg_contents": "> > 7.0RC5 is database-compatible with the final, earlier betas are *not*.\n> > You can use pg_upgrade to update from any 6.5-or-later version if you\n> > are feeling adventurous, but I'd definitely suggest making a backup\n> > first in case things go wrong and you have to initdb and restore.\n> Sorry if I was not clear. The RPMs I prepared use Lamar Owen spec from RC1,\n> but use final release sources. Upgrading from final release to final release\n> should not be a problem, I think. I only recommended it because I understand\n> from his recent posts sthat Lamar has many inprovements to the RPM install\n> script that I have not taken advantage of.\n\nTom's point is that RC5 is *not* database-compatible with previous\nrelease candidates due to a last minute bug fix in the location of\ngroup table indices.\n\nSo anything earlier than RC5 needs (at least) a pg_upgrade, and (for\nme) preferably a full dump/initdb/restore cycle.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Wed, 10 May 2000 13:39:35 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 RPM?" }, { "msg_contents": "Thomas Lockhart wrote:\n\n> > > 7.0RC5 is database-compatible with the final, earlier betas are *not*.\n> > > You can use pg_upgrade to update from any 6.5-or-later version if you\n> > > are feeling adventurous, but I'd definitely suggest making a backup\n> > > first in case things go wrong and you have to initdb and restore.\n> > Sorry if I was not clear. The RPMs I prepared use Lamar Owen spec from RC1,\n> > but use final release sources. Upgrading from final release to final release\n> > should not be a problem, I think. I only recommended it because I understand\n> > from his recent posts sthat Lamar has many inprovements to the RPM install\n> > script that I have not taken advantage of.\n>\n> Tom's point is that RC5 is *not* database-compatible with previous\n> release candidates due to a last minute bug fix in the location of\n> group table indices.\n>\n> So anything earlier than RC5 needs (at least) a pg_upgrade, and (for\n> me) preferably a full dump/initdb/restore cycle.\n>\n> - Thomas\n>\n> --\n> Thomas Lockhart [email protected]\n> South Pasadena, California\n\nMy point is that my RPMS use the final release sources\n\nKarl\n\n", "msg_date": "Wed, 10 May 2000 10:14:14 -0400", "msg_from": "Karl DeBisschop <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 RPM?" }, { "msg_contents": "> My point is that my RPMS use the final release sources\n\nDoh! Sorry, I was focused on the RC1 thing...\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Wed, 10 May 2000 14:27:07 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 RPM?" }, { "msg_contents": "\"J. Atwood\" wrote:\n> \n> I have been looking around for the RPM for 7.0 anyone have a quick link?\n\nAn announcement will be made shortly. Shortly being within a day or two\n-- possibly tonight. More likely tomorrow night.\n\n--\nLamar Owen\nWGCR Internet Radio\n1 Peter 4:11\n", "msg_date": "Wed, 10 May 2000 16:25:07 -0400", "msg_from": "Lamar Owen <[email protected]>", "msg_from_op": false, "msg_subject": "Re: 7.0 RPM?" } ]
[ { "msg_contents": "I've made improvements to the hardcopy User's Guide (and A4 version)\nto include mention of the postgres \"-P\" option and to fix up some\nformatting. Will download them this morning within a couple of hours\n(gotta do it from work since my home networking won't be here until I\nupgrade my s/w after 7.0 is released).\n\nafaik we will be ready to release at that time. Any other\nshow-stoppers?\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Mon, 08 May 2000 15:00:09 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": true, "msg_subject": "Ready to release?" }, { "msg_contents": "> I've made improvements to the hardcopy User's Guide (and A4 version)\n> to include mention of the postgres \"-P\" option and to fix up some\n> formatting. Will download them this morning within a couple of hours\n> (gotta do it from work since my home networking won't be here until I\n> upgrade my s/w after 7.0 is released).\n> \n> afaik we will be ready to release at that time. Any other\n> show-stoppers?\n> \n\nDo you want PDF? I can do it, or should we send out postscript?\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Mon, 8 May 2000 11:02:09 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Ready to release?" }, { "msg_contents": "> Do you want PDF? I can do it, or should we send out postscript?\n\nSure we should send out postscript. I *know* what the Postscript looks\nlike; I haven't worked with the PDF to know that it is 100% good.\nAlso, PDF requires a reader which afaik is not available on all of our\nsupported platforms; Postscript is supported natively by some\nprinters.\n\nShall we revisit this for 7.1, well before release time?\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Mon, 08 May 2000 15:17:53 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Ready to release?" }, { "msg_contents": "Thomas Lockhart <[email protected]> writes:\n> Shall we revisit this for 7.1, well before release time?\n\nYes. This is no time to be thinking about changing stuff.\nPS docs are what we know we can make without problems.\n\nI think PDF would be a good second alternative, though.\nPerhaps after release, we could make up a second batch\nof hardcopy docs in PDF form and make those available as\na separate download.\n\n\t\t\tregards, tom lane\n", "msg_date": "Mon, 08 May 2000 11:21:21 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Ready to release? " }, { "msg_contents": "> > Do you want PDF? I can do it, or should we send out postscript?\n> \n> Sure we should send out postscript. I *know* what the Postscript looks\n> like; I haven't worked with the PDF to know that it is 100% good.\n> Also, PDF requires a reader which afaik is not available on all of our\n> supported platforms; Postscript is supported natively by some\n> printers.\n> \n> Shall we revisit this for 7.1, well before release time?\n\nNo, if you are happy with Postscript, let's stay with it. I only\nrecommended PDF because we can embed the fonts right in the file, but\nmaybe that isn't important.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Mon, 8 May 2000 11:26:26 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Ready to release?" }, { "msg_contents": "On Mon, 8 May 2000, Thomas Lockhart wrote:\n\n> > Do you want PDF? I can do it, or should we send out postscript?\n> \n> Sure we should send out postscript. I *know* what the Postscript looks\n> like; I haven't worked with the PDF to know that it is 100% good.\n> Also, PDF requires a reader which afaik is not available on all of our\n> supported platforms; Postscript is supported natively by some\n> printers.\n> \n> Shall we revisit this for 7.1, well before release time?\n\nWhy not create a PDF and just make it available on the web/ftp site?\nI find it handy from time to time to do text searches.\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Mon, 8 May 2000 11:32:45 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: Ready to release?" }, { "msg_contents": "On Mon, 8 May 2000, Bruce Momjian wrote:\n\n> > > Do you want PDF? I can do it, or should we send out postscript?\n> > \n> > Sure we should send out postscript. I *know* what the Postscript looks\n> > like; I haven't worked with the PDF to know that it is 100% good.\n> > Also, PDF requires a reader which afaik is not available on all of our\n> > supported platforms; Postscript is supported natively by some\n> > printers.\n> > \n> > Shall we revisit this for 7.1, well before release time?\n> \n> No, if you are happy with Postscript, let's stay with it. I only\n> recommended PDF because we can embed the fonts right in the file, but\n> maybe that isn't important.\n\nJust a thought, but putting PDF versions online might be much much more\nfriendly to those downloading ... the only one that *truly* needs to be in\nthe distribution is the html stuff, the rest should be made available\nthrough the WWW, for those that want ... not everyone has a postscript\nprinter, so downloading postscript files tend to sound like more work then\nshould be required ... *shrug*\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Mon, 8 May 2000 12:32:59 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Ready to release?" }, { "msg_contents": "> Just a thought, but putting PDF versions online might be much much more\n> friendly to those downloading ... the only one that *truly* needs to be in\n> the distribution is the html stuff, the rest should be made available\n> through the WWW, for those that want ... not everyone has a postscript\n> printer, so downloading postscript files tend to sound like more work then\n> should be required ... *shrug*\n\nYes, IMHO, PDF seems to be the standard download format for documents.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Mon, 8 May 2000 11:41:25 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: Ready to release?" }, { "msg_contents": "Thomas Lockhart <[email protected]> writes:\n\n> Also, PDF requires a reader which afaik is not available on all of our\n> supported platforms\n\nXpdf should be supported almost everywhere: http://www.foolabs.com/xpdf/\n\n-- \nTrond Eivind Glomsr�d\nRed Hat, Inc.\n", "msg_date": "08 May 2000 11:47:46 -0400", "msg_from": "[email protected] (Trond Eivind=?iso-8859-1?q?_Glomsr=F8d?=)", "msg_from_op": false, "msg_subject": "Re: Re: Ready to release?" }, { "msg_contents": "The Hermit Hacker <[email protected]> writes:\n> Just a thought, but putting PDF versions online might be much much more\n> friendly to those downloading ... the only one that *truly* needs to be in\n> the distribution is the html stuff, the rest should be made available\n> through the WWW, for those that want ... not everyone has a postscript\n> printer, so downloading postscript files tend to sound like more work then\n> should be required ... *shrug*\n\nPerhaps not everyone would want the html version, either. Maybe we\nought to think about dividing the download into \"sources\" and then\nseveral alternative forms of \"docs\":\n\n\tpostgres-7.1-src.tar.gz\n\tpostgres-7.1-docs-html.tar.gz\n\tpostgres-7.1-docs-ps.tar.gz\n\tpostgres-7.1-docs-pdf.tar.gz\n\nThat way everyone can pick the format(s) they want, and not waste time\ndownloading what they don't want.\n\n\t\t\tregards, tom lane\n", "msg_date": "Mon, 08 May 2000 12:18:57 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: Ready to release? " }, { "msg_contents": "On Mon, 8 May 2000, Tom Lane wrote:\n\n> The Hermit Hacker <[email protected]> writes:\n> > Just a thought, but putting PDF versions online might be much much more\n> > friendly to those downloading ... the only one that *truly* needs to be in\n> > the distribution is the html stuff, the rest should be made available\n> > through the WWW, for those that want ... not everyone has a postscript\n> > printer, so downloading postscript files tend to sound like more work then\n> > should be required ... *shrug*\n> \n> Perhaps not everyone would want the html version, either. Maybe we\n> ought to think about dividing the download into \"sources\" and then\n> several alternative forms of \"docs\":\n> \n> \tpostgres-7.1-src.tar.gz\n> \tpostgres-7.1-docs-html.tar.gz\n> \tpostgres-7.1-docs-ps.tar.gz\n> \tpostgres-7.1-docs-pdf.tar.gz\n> \n> That way everyone can pick the format(s) they want, and not waste time\n> downloading what they don't want.\n\nThath sounds good also ... :)\n\n\n", "msg_date": "Mon, 8 May 2000 13:25:11 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: Ready to release? " }, { "msg_contents": "Bruce Momjian wrote:\n> \n> No, if you are happy with Postscript, let's stay with it. I only\n> recommended PDF because we can embed the fonts right in the file, but\n> maybe that isn't important.\n\nYou can embed font right in the file in PS as well, if you think this is\nneeded.\n\nI don't see any need for this currently, as the docs have no need for\nadditional fonts.\n\n--------\nHannu\n", "msg_date": "Tue, 09 May 2000 00:30:31 +0300", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: Ready to release?" }, { "msg_contents": "Tom Lane writes:\n\n> Perhaps not everyone would want the html version, either.\n\nBut then you don't have *anything*. I feel there should be some formatted\ndocumentation included by default. The HTML build is pretty solid, so it's\nnot like it's delaying anything. OTOH, {A4, Letter} x {PS, PDF} would mean\n4 redundant sets of print style docs, so not necessarily distributing all\nseems reasonable. (I want DVI anyway but our docs are too big for jadetex.\n:{ )\n\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Tue, 9 May 2000 22:50:59 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: Ready to release? " } ]
[ { "msg_contents": "You can find it after my sig. Hideous abuse of netiquette, but needs\nmust ...\n\nMost (nearly all) of the work was done by David Wragg <[email protected]>\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Mon, 8 May 2000 18:27:40 +0100 (BST)", "msg_from": "Mike Wyer <[email protected]>", "msg_from_op": true, "msg_subject": "kerberos 5 patch against 7.0RC5" }, { "msg_contents": "Can someone comment on this patch? It looks good to me.\n\nOf course, people say I never met a patch I didn't like.\n\n\n> You can find it after my sig. Hideous abuse of netiquette, but needs\n> must ...\n> \n> Most (nearly all) of the work was done by David Wragg <[email protected]>\n> \n> He patched 6.5.3. I've updated it for 7.0RC5.\n> \n> It works for MIT kerberos 1.1.1 (and previously for 1.0.6 as well).\n> \n> I've got the patch against 6.5.3, plus kerberized RPMS.\n> \n> Install:\n> \n> Assuming postgresql-7.0RC5 is in /usr/local/src\n> \n> cd /usr/local/src\n> patch -p0 < krb5-patch\n> \n> Edit postgresql-7.0RC5/src/Makefile.global.in\n> Change PG_KRB_SRVTAB to somewhere useful for you, and PG_KRB_SRVNAM to\n> whatever you want your postgres kerberos service called.\n> \n> make and install PostgreSQL.\n> \n> Generate the keytab (PG_KRB_SRVTAB):\n> kadmin% ank -randkey postgres/server.my.domain.org\n> kadmin% ktadd -k krb5.keytab postgres/server.my.domain.org\n> \n> Make sure the keytab is read-only to the postgres user.\n> Make sure your client binaries can see the new libraries.\n> \n> edit pg_hba.conf and change the authentication method to krb5.\n> \n> Everything should then work. If you use mod_auth_krb and mod_perl on\n> your web server, you can use AuthType KerberosV5SaveCredentials with a\n> mod_perl script. This gives secure database access over the web. No\n> extra passwords required. \n> \n> Cheers,\n> \n> Mike Wyer,\n> Department of Computing, Imperial College\n> -- \n> Mike Wyer <[email protected]> || \"Woof?\"\n> http://www.doc.ic.ac.uk/~mw || Gaspode the Wonder Dog \n> Work: 020 7594 8440 || from \"Moving Pictures\"\n> Mobile: 07879 697119 || by Terry Pratchett\n> \n> \n> ===========================8<----------------------------------------------\n> \n> diff -u -r postgresql-7.0RC5/src/Makefile.global.in postgresql-7.0RC5.krb5/src/Makefile.global.in\n> --- postgresql-7.0RC5/src/Makefile.global.in\tMon May 8 17:22:40 2000\n> +++ postgresql-7.0RC5.krb5/src/Makefile.global.in\tSat May 6 17:23:49 2000\n> @@ -120,7 +120,7 @@\n> # Set KRBVERS to \"4\" for Kerberos v4, \"5\" for Kerberos v5.\n> # XXX Edit the default Kerberos variables below!\n> #\n> -#KRBVERS= 5\n> +KRBVERS=5\n> \n> # Globally pass Kerberos file locations.\n> # these are used in the postmaster and all libpq applications.\n> @@ -132,9 +132,9 @@\n> # PG_KRB_SRVTAB is the location of the server's keytab file.\n> #\n> ifdef KRBVERS\n> -KRBINCS= -I/usr/athena/include\n> -KRBLIBS= -L/usr/athena/lib\n> -KRBFLAGS+= $(KRBINCS) -DPG_KRB_SRVNAM='\"postgres_dbms\"'\n> +KRBINCS= -I/usr/krb5/include\n> +KRBLIBS= -L/usr/krb5/lib\n> +KRBFLAGS+= $(KRBINCS) -DPG_KRB_SRVNAM='\"postgres\"'\n> ifeq ($(KRBVERS), 4)\n> KRBFLAGS+= -DKRB4\n> KRBFLAGS+= -DPG_KRB_SRVTAB='\"/etc/srvtab\"'\n> @@ -142,8 +142,8 @@\n> else\n> ifeq ($(KRBVERS), 5)\n> KRBFLAGS+= -DKRB5\n> -KRBFLAGS+= -DPG_KRB_SRVTAB='\"FILE:/krb5/srvtab.postgres\"'\n> -KRBLIBS+= -lkrb5 -lcrypto -lcom_err -lisode\n> +KRBFLAGS+= -DPG_KRB_SRVTAB='\"FILE:/usr/local/postgres/krb5.keytab\"'\n> +KRBLIBS+= -lkrb5 -lcrypto -lcom_err\n> endif\n> endif\n> endif\n> diff -u -r postgresql-7.0RC5/src/backend/libpq/auth.c postgresql-7.0RC5.krb5/src/backend/libpq/auth.c\n> --- postgresql-7.0RC5/src/backend/libpq/auth.c\tMon May 8 17:22:40 2000\n> +++ postgresql-7.0RC5.krb5/src/backend/libpq/auth.c\tSat May 6 17:17:13 2000\n> @@ -149,7 +149,8 @@\n> *----------------------------------------------------------------\n> */\n> \n> -#include \"krb5/krb5.h\"\n> +#include <krb5.h>\n> +#include <com_err.h>\n> \n> /*\n> * pg_an_to_ln -- return the local name corresponding to an authentication\n> @@ -174,130 +175,134 @@\n> \treturn aname;\n> }\n> \n> +\n> /*\n> - * pg_krb5_recvauth -- server routine to receive authentication information\n> - *\t\t\t\t\t from the client\n> - *\n> - * We still need to compare the username obtained from the client's setup\n> - * packet to the authenticated name, as described in pg_krb4_recvauth.\tThis\n> - * is a bit more problematic in v5, as described above in pg_an_to_ln.\n> - *\n> - * In addition, as described above in pg_krb5_sendauth, we still need to\n> - * canonicalize the server name v4-style before constructing a principal\n> - * from it. Again, this is kind of iffy.\n> - *\n> - * Finally, we need to tangle with the fact that v5 doesn't let you explicitly\n> - * set server keytab file names -- you have to feed lower-level routines a\n> - * function to retrieve the contents of a keytab, along with a single argument\n> - * that allows them to open the keytab. We assume that a server keytab is\n> - * always a real file so we can allow people to specify their own filenames.\n> - * (This is important because the POSTGRES keytab needs to be readable by\n> - * non-root users/groups; the v4 tools used to force you do dump a whole\n> - * host's worth of keys into a file, effectively forcing you to use one file,\n> - * but kdb5_edit allows you to select which principals to dump. Yay!)\n> + * Various krb5 state which is not connection specfic, and a flag to\n> + * indicate whether we have initialised it yet.\n> */\n> +static int pg_krb5_initialised;\n> +static krb5_context pg_krb5_context;\n> +static krb5_keytab pg_krb5_keytab;\n> +static krb5_principal pg_krb5_server;\n> +\n> +\n> static int\n> -pg_krb5_recvauth(Port *port)\n> +pg_krb5_init(void)\n> {\n> -\tchar\t\tservbuf[MAXHOSTNAMELEN + 1 +\n> -\t\t\t\t\t\t\t\t\tsizeof(PG_KRB_SRVNAM)];\n> -\tchar\t *hostp,\n> -\t\t\t *kusername = (char *) NULL;\n> -\tkrb5_error_code code;\n> -\tkrb5_principal client,\n> -\t\t\t\tserver;\n> -\tkrb5_address sender_addr;\n> -\tkrb5_rdreq_key_proc keyproc = (krb5_rdreq_key_proc) NULL;\n> -\tkrb5_pointer keyprocarg = (krb5_pointer) NULL;\n> +\tkrb5_error_code retval;\n> \n> -\t/*\n> -\t * Set up server side -- since we have no ticket file to make this\n> -\t * easy, we construct our own name and parse it. See note on\n> -\t * canonicalization above.\n> -\t */\n> -\tstrcpy(servbuf, PG_KRB_SRVNAM);\n> -\t*(hostp = servbuf + (sizeof(PG_KRB_SRVNAM) - 1)) = '/';\n> -\tif (gethostname(++hostp, MAXHOSTNAMELEN) < 0)\n> -\t\tstrcpy(hostp, \"localhost\");\n> -\tif (hostp = strchr(hostp, '.'))\n> -\t\t*hostp = '\\0';\n> -\tif (code = krb5_parse_name(servbuf, &server))\n> -\t{\n> +\tif (pg_krb5_initialised)\n> +\t\treturn STATUS_OK;\n> +\n> +\tretval = krb5_init_context(&pg_krb5_context);\n> +\tif (retval) {\n> \t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> -\t\t\"pg_krb5_recvauth: Kerberos error %d in krb5_parse_name\\n\", code);\n> -\t\tcom_err(\"pg_krb5_recvauth\", code, \"in krb5_parse_name\");\n> +\t\t\t\t \"pg_krb5_init: krb5_init_context returned\"\n> +\t\t\t\t \" Kerberos error %d\\n\", retval);\n> +\t\tcom_err(\"postgres\", retval, \"while initializing krb5\");\n> \t\treturn STATUS_ERROR;\n> \t}\n> \n> -\t/*\n> -\t * krb5_sendauth needs this to verify the address in the client\n> -\t * authenticator.\n> -\t */\n> -\tsender_addr.addrtype = port->raddr.in.sin_family;\n> -\tsender_addr.length = sizeof(port->raddr.in.sin_addr);\n> -\tsender_addr.contents = (krb5_octet *) & (port->raddr.in.sin_addr);\n> -\n> -\tif (strcmp(PG_KRB_SRVTAB, \"\"))\n> -\t{\n> -\t\tkeyproc = krb5_kt_read_service_key;\n> -\t\tkeyprocarg = PG_KRB_SRVTAB;\n> +\tretval = krb5_kt_resolve(pg_krb5_context, PG_KRB_SRVTAB, &pg_krb5_keytab);\n> +\tif (retval) {\n> +\t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> +\t\t\t\t \"pg_krb5_init: krb5_kt_resolve returned\"\n> +\t\t\t\t \" Kerberos error %d\\n\", retval);\n> +\t com_err(\"postgres\", retval, \"while resolving keytab file %s\",\n> +\t\t\t\tPG_KRB_SRVTAB);\n> +\t\tkrb5_free_context(pg_krb5_context);\n> +\t\treturn STATUS_ERROR;\n> \t}\n> \n> -\tif (code = krb5_recvauth((krb5_pointer) & port->sock,\n> -\t\t\t\t\t\t\t PG_KRB5_VERSION,\n> -\t\t\t\t\t\t\t server,\n> -\t\t\t\t\t\t\t &sender_addr,\n> -\t\t\t\t\t\t\t (krb5_pointer) NULL,\n> -\t\t\t\t\t\t\t keyproc,\n> -\t\t\t\t\t\t\t keyprocarg,\n> -\t\t\t\t\t\t\t (char *) NULL,\n> -\t\t\t\t\t\t\t (krb5_int32 *) NULL,\n> -\t\t\t\t\t\t\t &client,\n> -\t\t\t\t\t\t\t (krb5_ticket **) NULL,\n> -\t\t\t\t\t\t\t (krb5_authenticator **) NULL))\n> -\t{\n> + retval = krb5_sname_to_principal(pg_krb5_context, NULL, PG_KRB_SRVNAM, \n> +\t\t\t\t\t\t\t\t\t KRB5_NT_SRV_HST, &pg_krb5_server);\n> +\tif (retval) {\n> \t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> -\t\t \"pg_krb5_recvauth: Kerberos error %d in krb5_recvauth\\n\", code);\n> -\t\tcom_err(\"pg_krb5_recvauth\", code, \"in krb5_recvauth\");\n> -\t\tkrb5_free_principal(server);\n> +\t\t\t\t \"pg_krb5_init: krb5_sname_to_principal returned\"\n> +\t\t\t\t \" Kerberos error %d\\n\", retval);\n> +\t com_err(\"postgres\", retval, \n> +\t\t\t\t\"while getting server principal for service %s\",\n> +\t\t\t\tPG_KRB_SRVTAB);\n> +\t\tkrb5_kt_close(pg_krb5_context, pg_krb5_keytab);\n> +\t\tkrb5_free_context(pg_krb5_context);\n> \t\treturn STATUS_ERROR;\n> \t}\n> -\tkrb5_free_principal(server);\n> +\n> +\tpg_krb5_initialised = 1;\n> +\treturn STATUS_OK;\n> +}\n> +\n> +\n> +/*\n> + * pg_krb5_recvauth -- server routine to receive authentication information\n> + *\t\t\t\t\t from the client\n> + *\n> + * We still need to compare the username obtained from the client's setup\n> + * packet to the authenticated name, as described in pg_krb4_recvauth.\tThis\n> + * is a bit more problematic in v5, as described above in pg_an_to_ln.\n> + *\n> + * We have our own keytab file because postgres is unlikely to run as root,\n> + * and so cannot read the default keytab.\n> + */\n> +static int\n> +pg_krb5_recvauth(Port *port)\n> +{\n> +\tkrb5_error_code retval;\n> +\tint ret;\n> +\tkrb5_auth_context auth_context = NULL;\n> +\tkrb5_ticket *ticket;\n> + char *kusername;\n> +\n> +\tret = pg_krb5_init();\n> +\tif (ret != STATUS_OK)\n> +\t\treturn ret;\n> +\n> +\tretval = krb5_recvauth(pg_krb5_context, &auth_context,\n> +\t\t\t\t\t\t (krb5_pointer)&port->sock, PG_KRB_SRVNAM,\n> +\t\t\t\t\t\t pg_krb5_server, 0, pg_krb5_keytab, &ticket);\n> +\tif (retval) {\n> +\t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> +\t\t\t\t \"pg_krb5_recvauth: krb5_recvauth returned\"\n> +\t\t\t\t \" Kerberos error %d\\n\", retval);\n> +\t com_err(\"postgres\", retval, \"from krb5_recvauth\");\n> +\t\treturn STATUS_ERROR;\n> +\t}\t\t\t\t\t\t \n> \n> \t/*\n> \t * The \"client\" structure comes out of the ticket and is therefore\n> \t * authenticated. Use it to check the username obtained from the\n> \t * postmaster startup packet.\n> +\t *\n> +\t * I have no idea why this is considered necessary.\n> \t */\n> -\tif ((code = krb5_unparse_name(client, &kusername)))\n> -\t{\n> + retval = krb5_unparse_name(pg_krb5_context, \n> +\t\t\t\t\t\t\t ticket->enc_part2->client, &kusername);\n> +\tif (retval) {\n> \t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> -\t\t\t\t \"pg_krb5_recvauth: Kerberos error %d in krb5_unparse_name\\n\", code);\n> -\t\tcom_err(\"pg_krb5_recvauth\", code, \"in krb5_unparse_name\");\n> -\t\tkrb5_free_principal(client);\n> -\t\treturn STATUS_ERROR;\n> -\t}\n> -\tkrb5_free_principal(client);\n> -\tif (!kusername)\n> -\t{\n> -\t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> -\t\t\t\t \"pg_krb5_recvauth: could not decode username\\n\");\n> -\t\tfputs(PQerrormsg, stderr);\n> -\t\tpqdebug(\"%s\", PQerrormsg);\n> +\t\t\t\t \"pg_krb5_recvauth: krb5_unparse_name returned\"\n> +\t\t\t\t \" Kerberos error %d\\n\", retval);\n> +\t com_err(\"postgres\", retval, \"while unparsing client name\");\n> +\t\tkrb5_free_ticket(pg_krb5_context, ticket);\n> +\t\tkrb5_auth_con_free(pg_krb5_context, auth_context);\n> \t\treturn STATUS_ERROR;\n> \t}\n> +\n> \tkusername = pg_an_to_ln(kusername);\n> -\tif (strncmp(username, kusername, SM_USER))\n> +\tif (strncmp(port->user, kusername, SM_USER))\n> \t{\n> \t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> -\t\t\t\t \"pg_krb5_recvauth: name \\\"%s\\\" != \\\"%s\\\"\\n\", port->user, kusername);\n> -\t\tfputs(PQerrormsg, stderr);\n> -\t\tpqdebug(\"%s\", PQerrormsg);\n> -\t\tpfree(kusername);\n> -\t\treturn STATUS_ERROR;\n> -\t}\n> -\tpfree(kusername);\n> -\treturn STATUS_OK;\n> +\t\t\t\t \"pg_krb5_recvauth: user name \\\"%s\\\" != krb5 name \\\"%s\\\"\\n\", \n> +\t\t\t\t port->user, kusername);\n> +\t\tret = STATUS_ERROR;\n> +\t}\n> +\telse\n> +\t\tret = STATUS_OK;\n> +\t\n> +\tkrb5_free_ticket(pg_krb5_context, ticket);\n> +\tkrb5_auth_con_free(pg_krb5_context, auth_context);\n> +\tfree(kusername);\n> +\n> +\treturn ret;\n> }\n> \n> #else\n> diff -u -r postgresql-7.0RC5/src/interfaces/libpq/Makefile.in postgresql-7.0RC5.krb5/src/interfaces/libpq/Makefile.in\n> --- postgresql-7.0RC5/src/interfaces/libpq/Makefile.in\tMon May 8 17:22:40 2000\n> +++ postgresql-7.0RC5.krb5/src/interfaces/libpq/Makefile.in\tSat May 6 17:17:13 2000\n> @@ -21,6 +21,7 @@\n> \n> ifdef KRBVERS\n> CFLAGS+= $(KRBFLAGS)\n> +SHLIB_LINK += $(KRBLIBS)\n> endif\n> \n> OBJS= fe-auth.o fe-connect.o fe-exec.o fe-misc.o fe-print.o fe-lobj.o \\\n> diff -u -r postgresql-7.0RC5/src/interfaces/libpq/fe-auth.c postgresql-7.0RC5.krb5/src/interfaces/libpq/fe-auth.c\n> --- postgresql-7.0RC5/src/interfaces/libpq/fe-auth.c\tMon May 8 17:22:40 2000\n> +++ postgresql-7.0RC5.krb5/src/interfaces/libpq/fe-auth.c\tSat May 6 17:17:13 2000\n> @@ -39,6 +39,7 @@\n> #include \"win32.h\"\n> #else\n> #include <unistd.h>\n> +#include <fcntl.h>\n> #include <sys/param.h>\t\t\t/* for MAXHOSTNAMELEN on most */\n> #ifndef MAXHOSTNAMELEN\n> #include <netdb.h>\t\t\t\t/* for MAXHOSTNAMELEN on some */\n> @@ -234,7 +235,8 @@\n> *----------------------------------------------------------------\n> */\n> \n> -#include \"krb5/krb5.h\"\n> +#include <krb5.h>\n> +#include <com_err.h>\n> \n> /*\n> * pg_an_to_ln -- return the local name corresponding to an authentication\n> @@ -250,7 +252,7 @@\n> *\t and we can't afford to punt.\n> */\n> static char *\n> -pg_an_to_ln(const char *aname)\n> +pg_an_to_ln(char *aname)\n> {\n> \tchar\t *p;\n> \n> @@ -261,197 +263,160 @@\n> \n> \n> /*\n> - * pg_krb5_init -- initialization performed before any Kerberos calls are made\n> - *\n> - * With v5, we can no longer set the ticket (credential cache) file name;\n> - * we now have to provide a file handle for the open (well, \"resolved\")\n> - * ticket file everywhere.\n> - *\n> + * Various krb5 state which is not connection specfic, and a flag to\n> + * indicate whether we have initialised it yet.\n> */\n> +static int pg_krb5_initialised;\n> +static krb5_context pg_krb5_context;\n> +static krb5_ccache pg_krb5_ccache;\n> +static krb5_principal pg_krb5_client;\n> +static char *pg_krb5_name;\n> +\n> +\n> static int\n> -\t\t\tkrb5_ccache\n> -pg_krb5_init(void)\n> +pg_krb5_init(char *PQerrormsg)\n> {\n> -\tkrb5_error_code code;\n> -\tchar\t *realm,\n> -\t\t\t *defname;\n> -\tchar\t\ttktbuf[MAXPGPATH];\n> -\tstatic krb5_ccache ccache = (krb5_ccache) NULL;\n> +\tkrb5_error_code retval;\n> \n> -\tif (ccache)\n> -\t\treturn ccache;\n> +\tif (pg_krb5_initialised)\n> +\t\treturn STATUS_OK;\n> \n> -\t/*\n> -\t * If the user set PGREALM, then we use a ticket file with a special\n> -\t * name: <usual-ticket-file-name>@<PGREALM-value>\n> -\t */\n> -\tif (!(defname = krb5_cc_default_name()))\n> -\t{\n> -\t\t(void) sprintf(PQerrormsg,\n> -\t\t\t\t\t \"pg_krb5_init: krb5_cc_default_name failed\\n\");\n> -\t\treturn (krb5_ccache) NULL;\n> -\t}\n> -\tstrcpy(tktbuf, defname);\n> -\tif (realm = getenv(\"PGREALM\"))\n> -\t{\n> -\t\tstrcat(tktbuf, \"@\");\n> -\t\tstrcat(tktbuf, realm);\n> +\tretval = krb5_init_context(&pg_krb5_context);\n> +\tif (retval) {\n> +\t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> +\t\t\t\t \"pg_krb5_init: krb5_init_context: %s\",\n> +\t\t\t\t error_message(retval));\n> +\t\treturn STATUS_ERROR;\n> \t}\n> \n> -\tif (code = krb5_cc_resolve(tktbuf, &ccache))\n> -\t{\n> -\t\t(void) sprintf(PQerrormsg,\n> -\t\t \"pg_krb5_init: Kerberos error %d in krb5_cc_resolve\\n\", code);\n> -\t\tcom_err(\"pg_krb5_init\", code, \"in krb5_cc_resolve\");\n> -\t\treturn (krb5_ccache) NULL;\n> -\t}\n> -\treturn ccache;\n> +\tretval = krb5_cc_default(pg_krb5_context, &pg_krb5_ccache);\n> +\tif (retval) {\n> +\t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> +\t\t\t\t \"pg_krb5_init: krb5_cc_default: %s\",\n> +\t\t\t\t error_message(retval));\n> +\t\tkrb5_free_context(pg_krb5_context);\n> +\t\treturn STATUS_ERROR;\n> + }\n> +\n> + retval = krb5_cc_get_principal(pg_krb5_context, pg_krb5_ccache, \n> +\t\t\t\t\t\t\t\t &pg_krb5_client);\n> +\tif (retval) {\n> +\t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> +\t\t\t\t \"pg_krb5_init: krb5_cc_get_principal: %s\",\n> +\t\t\t\t error_message(retval));\n> +\t\tkrb5_cc_close(pg_krb5_context, pg_krb5_ccache);\n> +\t\tkrb5_free_context(pg_krb5_context);\n> +\t\treturn STATUS_ERROR;\n> + }\n> +\n> + retval = krb5_unparse_name(pg_krb5_context, pg_krb5_client, &pg_krb5_name);\n> +\tif (retval) {\n> +\t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> +\t\t\t\t \"pg_krb5_init: krb5_unparse_name: %s\",\n> +\t\t\t\t error_message(retval));\n> +\t\tkrb5_free_principal(pg_krb5_context, pg_krb5_client);\n> +\t\tkrb5_cc_close(pg_krb5_context, pg_krb5_ccache);\n> +\t\tkrb5_free_context(pg_krb5_context);\n> +\t\treturn STATUS_ERROR;\n> +\t}\t\n> +\n> +\tpg_krb5_name = pg_an_to_ln(pg_krb5_name);\n> +\n> +\tpg_krb5_initialised = 1;\n> +\treturn STATUS_OK;\n> }\n> \n> +\n> /*\n> * pg_krb5_authname -- returns a pointer to static space containing whatever\n> *\t\t\t\t\t name the user has authenticated to the system\n> - *\n> - * We obtain this information by digging around in the ticket file.\n> - */\n> + */\n> static const char *\n> -pg_krb5_authname(const char *PQerrormsg)\n> +pg_krb5_authname(char *PQerrormsg)\n> {\n> -\tkrb5_ccache ccache;\n> -\tkrb5_principal principal;\n> -\tkrb5_error_code code;\n> -\tstatic char *authname = (char *) NULL;\n> -\n> -\tif (authname)\n> -\t\treturn authname;\n> +\tif (pg_krb5_init(PQerrormsg) != STATUS_OK)\n> +\t\treturn NULL;\n> \n> -\tccache = pg_krb5_init();\t/* don't free this */\n> -\n> -\tif (code = krb5_cc_get_principal(ccache, &principal))\n> -\t{\n> -\t\t(void) sprintf(PQerrormsg,\n> -\t\t\t\t\t \"pg_krb5_authname: Kerberos error %d in krb5_cc_get_principal\\n\", code);\n> -\t\tcom_err(\"pg_krb5_authname\", code, \"in krb5_cc_get_principal\");\n> -\t\treturn (char *) NULL;\n> -\t}\n> -\tif (code = krb5_unparse_name(principal, &authname))\n> -\t{\n> -\t\t(void) sprintf(PQerrormsg,\n> -\t\t\t\t\t \"pg_krb5_authname: Kerberos error %d in krb5_unparse_name\\n\", code);\n> -\t\tcom_err(\"pg_krb5_authname\", code, \"in krb5_unparse_name\");\n> -\t\tkrb5_free_principal(principal);\n> -\t\treturn (char *) NULL;\n> -\t}\n> -\tkrb5_free_principal(principal);\n> -\treturn pg_an_to_ln(authname);\n> +\treturn pg_krb5_name;\n> }\n> \n> +\n> /*\n> * pg_krb5_sendauth -- client routine to send authentication information to\n> *\t\t\t\t\t the server\n> - *\n> - * This routine does not do mutual authentication, nor does it return enough\n> - * information to do encrypted connections. But then, if we want to do\n> - * encrypted connections, we'll have to redesign the whole RPC mechanism\n> - * anyway.\n> - *\n> - * Server hostnames are canonicalized v4-style, i.e., all domain suffixes\n> - * are simply chopped off.\tHence, we are assuming that you've entered your\n> - * server instances as\n> - *\t\t<value-of-PG_KRB_SRVNAM>/<canonicalized-hostname>\n> - * in the PGREALM (or local) database.\tThis is probably a bad assumption.\n> */\n> static int\n> -pg_krb5_sendauth(const char *PQerrormsg, int sock,\n> +pg_krb5_sendauth(char *PQerrormsg, int sock,\n> \t\t\t\t struct sockaddr_in * laddr,\n> \t\t\t\t struct sockaddr_in * raddr,\n> \t\t\t\t const char *hostname)\n> {\n> -\tchar\t\tservbuf[MAXHOSTNAMELEN + 1 +\n> -\t\t\t\t\t\t\t\t\tsizeof(PG_KRB_SRVNAM)];\n> -\tconst char *hostp;\n> -\tconst char *realm;\n> -\tkrb5_error_code code;\n> -\tkrb5_principal client,\n> -\t\t\t\tserver;\n> -\tkrb5_ccache ccache;\n> -\tkrb5_error *error = (krb5_error *) NULL;\n> -\n> -\tccache = pg_krb5_init();\t/* don't free this */\n> -\n> -\t/*\n> -\t * set up client -- this is easy, we can get it out of the ticket\n> -\t * file.\n> -\t */\n> -\tif (code = krb5_cc_get_principal(ccache, &client))\n> -\t{\n> -\t\t(void) sprintf(PQerrormsg,\n> -\t\t\t\t\t \"pg_krb5_sendauth: Kerberos error %d in krb5_cc_get_principal\\n\", code);\n> -\t\tcom_err(\"pg_krb5_sendauth\", code, \"in krb5_cc_get_principal\");\n> +\tkrb5_error_code retval;\n> +\tint ret;\n> +\tkrb5_principal server;\n> +\tkrb5_auth_context auth_context = NULL;\n> + krb5_error *err_ret = NULL;\n> +\tint flags;\n> +\n> +\tret = pg_krb5_init(PQerrormsg);\n> +\tif (ret != STATUS_OK)\n> +\t\treturn ret;\n> +\n> +\tretval = krb5_sname_to_principal(pg_krb5_context, hostname, PG_KRB_SRVNAM, \n> +\t\t\t\t\t\t\t\t\t KRB5_NT_SRV_HST, &server);\n> +\tif (retval) {\n> +\t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> +\t\t\t\t \"pg_krb5_sendauth: krb5_sname_to_principal: %s\",\n> +\t\t\t\t error_message(retval));\n> \t\treturn STATUS_ERROR;\n> \t}\n> \n> -\t/*\n> -\t * set up server -- canonicalize as described above\n> +\t/* \n> +\t * libpq uses a non-blocking socket. But kerberos needs a blocking\n> +\t * socket, and we have to block somehow to do mutual authentication\n> +\t * anyway. So we temporarily make it blocking.\n> \t */\n> -\tstrcpy(servbuf, PG_KRB_SRVNAM);\n> -\t*(hostp = servbuf + (sizeof(PG_KRB_SRVNAM) - 1)) = '/';\n> -\tif (hostname || *hostname)\n> -\t\tstrncpy(++hostp, hostname, MAXHOSTNAMELEN);\n> -\telse\n> -\t{\n> -\t\tif (gethostname(++hostp, MAXHOSTNAMELEN) < 0)\n> -\t\t\tstrcpy(hostp, \"localhost\");\n> -\t}\n> -\tif (hostp = strchr(hostp, '.'))\n> -\t\t*hostp = '\\0';\n> -\tif (realm = getenv(\"PGREALM\"))\n> -\t{\n> -\t\tstrcat(servbuf, \"@\");\n> -\t\tstrcat(servbuf, realm);\n> -\t}\n> -\tif (code = krb5_parse_name(servbuf, &server))\n> -\t{\n> -\t\t(void) sprintf(PQerrormsg,\n> -\t\t\"pg_krb5_sendauth: Kerberos error %d in krb5_parse_name\\n\", code);\n> -\t\tcom_err(\"pg_krb5_sendauth\", code, \"in krb5_parse_name\");\n> -\t\tkrb5_free_principal(client);\n> +\tflags = fcntl(sock, F_GETFL);\n> +\tif (flags < 0 || fcntl(sock, F_SETFL, (long)(flags & ~O_NONBLOCK))) {\n> +\t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> +\t\t\t\t \"pg_krb5_sendauth: fcntl: %s\", strerror(errno));\n> +\t\tkrb5_free_principal(pg_krb5_context, server);\n> \t\treturn STATUS_ERROR;\n> \t}\n> \n> -\t/*\n> -\t * The only thing we want back from krb5_sendauth is an error status\n> -\t * and any error messages.\n> -\t */\n> -\tif (code = krb5_sendauth((krb5_pointer) & sock,\n> -\t\t\t\t\t\t\t PG_KRB5_VERSION,\n> -\t\t\t\t\t\t\t client,\n> -\t\t\t\t\t\t\t server,\n> -\t\t\t\t\t\t\t (krb5_flags) 0,\n> -\t\t\t\t\t\t\t (krb5_checksum *) NULL,\n> -\t\t\t\t\t\t\t (krb5_creds *) NULL,\n> -\t\t\t\t\t\t\t ccache,\n> -\t\t\t\t\t\t\t (krb5_int32 *) NULL,\n> -\t\t\t\t\t\t\t (krb5_keyblock **) NULL,\n> -\t\t\t\t\t\t\t &error,\n> -\t\t\t\t\t\t\t (krb5_ap_rep_enc_part **) NULL))\n> -\t{\n> -\t\tif ((code == KRB5_SENDAUTH_REJECTED) && error)\n> -\t\t{\n> -\t\t\t(void) sprintf(PQerrormsg,\n> -\t\t\t\t \"pg_krb5_sendauth: authentication rejected: \\\"%*s\\\"\\n\",\n> -\t\t\t\t\t\t error->text.length, error->text.data);\n> +\tretval = krb5_sendauth(pg_krb5_context, &auth_context,\n> +\t\t\t\t\t\t (krb5_pointer) &sock, PG_KRB_SRVNAM,\n> +\t\t\t\t\t\t pg_krb5_client, server,\n> +\t\t\t\t\t\t AP_OPTS_MUTUAL_REQUIRED,\n> +\t\t\t\t\t\t NULL, 0,\t\t/* no creds, use ccache instead */\n> +\t\t\t\t\t\t pg_krb5_ccache, &err_ret, NULL, NULL);\n> +\tif (retval) {\n> +\t\tif (retval == KRB5_SENDAUTH_REJECTED && err_ret) {\n> +\t\t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> +\t\t\t\t\t \"pg_krb5_sendauth: authentication rejected: \\\"%*s\\\"\",\n> +\t\t\t\t\t err_ret->text.length, err_ret->text.data);\n> \t\t}\n> -\t\telse\n> -\t\t{\n> -\t\t\t(void) sprintf(PQerrormsg,\n> -\t\t\t\t\t\t \"pg_krb5_sendauth: Kerberos error %d in krb5_sendauth\\n\", code);\n> -\t\t\tcom_err(\"pg_krb5_sendauth\", code, \"in krb5_sendauth\");\n> +\t\telse {\n> +\t\t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> +\t\t\t\t\t \"pg_krb5_sendauth: krb5_sendauth: %s\",\n> +\t\t\t\t\t error_message(retval));\n> \t\t}\n> +\t\t\t\n> +\t\tif (err_ret)\n> +\t\t\tkrb5_free_error(pg_krb5_context, err_ret);\n> +\t\t\n> +\t\tret = STATUS_ERROR;\n> +\t}\n> +\n> +\tkrb5_free_principal(pg_krb5_context, server);\n> +\t\n> +\tif (fcntl(sock, F_SETFL, (long)flags)) {\n> +\t\tsnprintf(PQerrormsg, PQERRORMSG_LENGTH,\n> +\t\t\t\t \"pg_krb5_sendauth: fcntl: %s\", strerror(errno));\n> +\t\tret = STATUS_ERROR;\n> \t}\n> -\tkrb5_free_principal(client);\n> -\tkrb5_free_principal(server);\n> -\treturn code ? STATUS_ERROR : STATUS_OK;\n> +\n> +\treturn ret;\n> }\n> \n> #endif\t /* KRB5 */\n> diff -u -r postgresql-7.0RC5/src/interfaces/libpq/libpq-int.h postgresql-7.0RC5.krb5/src/interfaces/libpq/libpq-int.h\n> --- postgresql-7.0RC5/src/interfaces/libpq/libpq-int.h\tMon May 8 17:22:40 2000\n> +++ postgresql-7.0RC5.krb5/src/interfaces/libpq/libpq-int.h\tSat May 6 17:49:38 2000\n> @@ -50,6 +50,7 @@\n> * POSTGRES backend dependent Constants.\n> */\n> \n> +#define PQERRORMSG_LENGTH 1024\n> #define CMDSTATUS_LEN 40\n> \n> /*\n> \n> \n\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Thu, 11 May 2000 00:27:40 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: kerberos 5 patch against 7.0RC5" }, { "msg_contents": "Bruce Momjian <[email protected]> writes:\n> Can someone comment on this patch? It looks good to me.\n\nLooks like a rather major rewrite of the Kerberos support --- do we feel\ncomfortable cramming this into 7.0.1? Seems like putting it into the\n7.1 cycle might be the prudent course, so that it will get some beta\ntesting before being loosed upon the world. (Alternatively, if a couple\nother Kerberos users want to try it and report back, I'd feel better\nabout dropping it into 7.0.* ...)\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 11 May 2000 02:09:20 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: kerberos 5 patch against 7.0RC5 " }, { "msg_contents": "This was put in 7.1.\n\n> Bruce Momjian <[email protected]> writes:\n> > Can someone comment on this patch? It looks good to me.\n> \n> Looks like a rather major rewrite of the Kerberos support --- do we feel\n> comfortable cramming this into 7.0.1? Seems like putting it into the\n> 7.1 cycle might be the prudent course, so that it will get some beta\n> testing before being loosed upon the world. (Alternatively, if a couple\n> other Kerberos users want to try it and report back, I'd feel better\n> about dropping it into 7.0.* ...)\n> \n> \t\t\tregards, tom lane\n> \n\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Tue, 13 Jun 2000 03:36:01 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Re: kerberos 5 patch against 7.0RC5" } ]
[ { "msg_contents": "> -----Original Message-----\n> From: Tom Lane [mailto:[email protected]]\n> \n> \"Hiroshi Inoue\" <[email protected]> writes:\n> >>>> Apr 28 03:06:05 ziutek logger: NOTICE: Index \n> >>>> tb_klienci_id_klienci_key: NUMBER OF INDEX' TUPLES (10652) \n> >>>> IS NOT THE SAME AS HEAP' (10634)\n> >> \n> >> This can happen if there are other transactions open while the VACUUM\n> >> runs. \n> \n> > Really ?\n> > If I remember correctly,your sample cases have CREATE INDEX\n> > and NUMBER OF INDEX TUPLES was not greater than HEAP.\n> \n> Hmm, good point --- maybe this is something different.\n>\n\nAs to this INDEX TUPLES > HEAP phenomenon in VACUUM.\n\nThe delay of WriteBuffer(cur_buffer) in vc_repair_frag() of\nVACUUM may be one of the cause. cur_buffer is a buffer page\nwhere new MOVED_IN tuples are inserted. It is dirtied when\nanother cur_buffer page is needed or tuple moving was finished.\nOTOH newly inserted index tuples are dirtied immediately.\nIf VACUUM crashes before the cur_buffer is dirtied,the buffer\nmay be discarded without writing to disk. This may result that\nsome index tuples would point to UNUSED blocks.\nThough it isn't a problem at the moment,updation of tuples\nof the page would replace UNUSED blocks.\n\nI'm not sure my guess is right or not.\n\nComments ? \n\nRegards.\n\nHiroshi Inoue\[email protected]\n", "msg_date": "Tue, 9 May 2000 14:07:35 +0900", "msg_from": "\"Hiroshi Inoue\" <[email protected]>", "msg_from_op": true, "msg_subject": "RE: Notice in logg file " } ]
[ { "msg_contents": "I'm new to RDBMS so what follows is probably old crusty questions but\nmight have some relation to the new foreign key implementation:\n\nIn database table inheritance, which may be different than inheritance as it is\nin programming languages, shouldn't derived classes only store the additional\nattribributes?\n\nShouldn't the inherited attributes be obtained by reference(s) to a row(s) in\nthe base class(es)?\n\nShouldn't when a derived class inherits a base class(es), that it\noptionally inherit a user selected PRIMARY KEY of one of its base classes as its\nPRIMARY KEY. The other PRIMARY KEYs of the base classes (rejected candidates),\nare inherited as is like the rest of the other inherited attributes and\nwith their constraints intact?\n\nI could imagine a syntax like:\nCREATE TABLE child (... unique attributes of a child) INHERITS(parent1,\nparent2) WITH PRIMARY KEY;\n\nThe WITH PRIMARY KEY, means that child takes the PRIMARY KEY of the first\nbase class listed in INHERITS() as its own PRIMARY KEY. If WITH PRIMARY\nKEY is omitted, then the child is free to make one of its own unique attributes\nits PRIMARY KEY.\n\nThis is totally different than how things are working and I'm probably wrong!\n\nUnder this scheme, an INSERT INTO child, results in an INSERT INTO each of its\nbase classes using those attributes it passed on to the child. A row in the\nchild class would really only contain storage of the unique attributes it adds\nto the bases AND record OIDs for each base class that each point to a row\ncontaining its attributes for the child instance. The record OIDS would be in\nthe order as they were in the INHERITS clause if that would matter.\n\nWhat I describe is more like a TREE since the derived and base classes remain\ntightly linked. In inheritance like in programming languages, or in real life,\nattributes are just copied and the new entity has no linkage to its parents\nanymore - it can be killed independent of its parent. I've noticed that in\nPostgres, this is not the case. You have to DROP the derived classes before\nyou can DROP the base classes. Since there is already the some linkage, this\nis not really inheritance in Postgres. A derived class here is like adding\nlimbs to a tree that gets it more specialized rather than totally different and\ndisconnected. To cut the tree down, you trim its limbs off first a little or\njust plunge it all down.\n\nA fully implemented tree-like inheritance allows the derived classes to act\nas connected extensions of the base and optionally share/use an existing PRIMARY\nKEY. I like the word EXTENDS instead of INHERITS for this. There is a\ndifference. EXTENDS is like what I am talking about, a tree structure that\nbuilds up and remains connected. INHERITS to me means spawning off a new trunk\nthat initially has at least all of the properties of an existing tree - no\nlinkage back to the parent except to say it is of that class and some more. \nThe class resulting from being EXTENDS from from a parent remains connected to\nthe parent branch and shares its attributes. A class that INHERITS a base\nclass should be independent of the base. The base should be DROPpable\nafter the derived class has been CREATE?\n\n\n-- \nRobert B. Easter\[email protected]\n", "msg_date": "Tue, 9 May 2000 02:05:21 -0400", "msg_from": "\"Robert B. Easter\" <[email protected]>", "msg_from_op": true, "msg_subject": "inheritance and primary and foreign keys" }, { "msg_contents": "On Tue, 09 May 2000, Robert B. Easter wrote:\n> I'm new to RDBMS so what follows is probably old crusty questions but\n> might have some relation to the new foreign key implementation:\n\n[snip]\n\nI didn't mean to send this email. It was just a draft that I was playing with! \nThere are probaby very good reasons why INHERITS works the way it does.\nSorry.\n\nAnyway, I like the idea of a separate treatement of INHERITS and EXTENDS for\nimplementing object hierarchy. For INHERIT, a child table just gets a\nCOPY of the structure of the parent with maybe some possibility to take \ninherited attribute(s) and/or new attributes as a primary key. The parent can\nbe dropped since the child is independent of its parent. The parent would\n'know' about its children, but the child need not know about the parent. \nSELECT * from parent*; would work.\n\nIn EXTENDS, parent and child are connected branches that share attributes and\nstorage so that you can't drop the parent unless you drop dependent children\nfirst. The children would again, have an ability to use inherited attribs as a\nprimary key, possibily in combination with new attributes. The default\nmight be that if the parent has a primary key, it will also be the\nprimary key of the child. The child and parent would be using the SAME key\nwith indexes etc shared. Inserting into the child results in insertion into the\nparent branch of the inherited attribs and an insert into the child of just its\nunique attribs. The child just extends its parent with more attributes. \nSELECT * from parent*; would act just like it does in INHERITS.\n\nAgain, INHERITS is like starting a new independent trunk that initially gets the\nstructure of what it inherits. EXTENDS adds a branch to a connected tree\nstructure to create more specialization.\n\nAnyhow, this kind of topic probably bores people and has been beaten into the\nground in the past. If there is an archive about topics like this in\nPostgreSQL hackers, I'd like to know the time periods and I'd go read it.\n\nI am able to get the system to act almost the way I want by doing this:\n\nCREATE TABLE employee (\n\tem_id\t\tSERIAL PRIMARY KEY,\n\tname\t\tTEXT,\n\t...\n);\n\nCREATE TABLE manager (\n\t...\n) INHERITS(employee);\n\nThe SERIAL type gets inherited with its modifier to use the same sequence as\nemployee does. Only thing missing is that em_id is not the PRIMARY KEY in\nmanager and I don't see how to do it.\n\n-- \nRobert B. Easter\[email protected]\n", "msg_date": "Tue, 9 May 2000 16:38:02 -0400", "msg_from": "\"Robert B. Easter\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [HACKERS] inheritance and primary and foreign keys" } ]
[ { "msg_contents": "> Peter Eisentraut <[email protected]> writes:\n> > Tom Lane writes:\n> >> We already have the ability to work with an externally provided SSL\n> >> library.\n> \n> > Does it actually work? Has anybody tried it? Is it \n> documented anywhere?\n> \n> Picky, picky ;-)\n\nWell, since I'm responsible for putting the stuff in, I shuold probably have\ntested it before we got this far into the beta. But I haven't had the time\n:-(\nIt worked fine right after it was introduced, I tried that :-) But the\nmachine I have it running on is still running that old version (you can tell\nit's not a heavily used machine right now).\nIf there's any major breakage it's probably too late to go messing around in\nit before 7.0. I'll try to check it out and fix anything that's broken\nbefore 7.0.1.\n\n\n> It looks like you compile with USE_SSL (which ought to be listed as an\n> available option in config.h.in, but isn't; someday it should be a\n> configure option, perhaps) and then add \"-l\" to the \n> postmaster switches.\n> At least \"-l\" is documented.\n:-)\n\n\n> There are some interactions between \n> SSL-client-and-non-SSL-server, etc,\n> which you can read about in the pghackers archives from last year, if\n> not in the docs. \nI don't think it ever made it into the docs. Probably because I never\ncleaned it up enough. I have a draft around somewhere, I think.\n\n\n> Also, I thought there was supposed to be a \n> postmaster option to refuse non-SSL connections, but I don't see it now...\nThere was. :-)\nAt least in my patch, if you specify \"-is\", it will run as\n\"SecureNetServer\", which shuold refuse any non-SSL INET connections. It will\ndrop non-SSL connections with the error \"Backend requires secure\nconnection.\"\nBut it seems this is replaced with \"-l\" now. \n\nSeems like:\n-i means listen on standard *AND* SSL if compiled with SSL.\n-l means listen on SSL only (fail if SSL not compiled in).\n\n\nYou can also specify in pg_hba with \"hostssl\" instead of \"host\". \n\n//Magnus\n", "msg_date": "Tue, 9 May 2000 09:50:18 +0200 ", "msg_from": "Magnus Hagander <[email protected]>", "msg_from_op": true, "msg_subject": "RE: You're on SecurityFocus.com for the cleartext passw\n\tords." } ]
[ { "msg_contents": "\nlook at this\n\nOpen source start-up to take on database market \nhttp://news.cnet.com/news/0-1003-200-1841316.html?tag=st.ne.1002.tgif.ni\n\nsergio\n\n", "msg_date": "Tue, 9 May 2000 10:28:57 -0300", "msg_from": "\"Sergio A. Kessler\" <[email protected]>", "msg_from_op": true, "msg_subject": "hey ..." } ]
[ { "msg_contents": "Lamar, I'd like to test the 7.0 RPM on Mandrake to see if I can avoid\nposting a separate one. afaik there is the candidate->release\navailable on the ftp site in a v7.0 directory. Let me know when\nsomething is available...\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Tue, 09 May 2000 13:56:33 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": true, "msg_subject": "v7.0 release" }, { "msg_contents": "Thomas Lockhart wrote:\n \n> Lamar, I'd like to test the 7.0 RPM on Mandrake to see if I can avoid\n> posting a separate one. afaik there is the candidate->release\n> available on the ftp site in a v7.0 directory. Let me know when\n> something is available...\n\n'Something' will be available shortly. The RC5 RPM is there -- and\nthere are not many differences -- try that one and let me know if you\nhave problems.\n\n--\nLamar Owen\nWGCR Internet Radio\n1 Peter 4:11\n", "msg_date": "Wed, 10 May 2000 16:19:41 -0400", "msg_from": "Lamar Owen <[email protected]>", "msg_from_op": false, "msg_subject": "Re: v7.0 release" } ]
[ { "msg_contents": "\nWhat do people think about this?\n\n\thttp://news.cnet.com/news/0-1003-200-1841316.html?tag=st.ne.ron.lthd.ni\n\nIt makes me uneasy.\n\n-- cary\n\nCary O'Brien\[email protected]\nLong time (4 yr!) PostgreSQL user.\nGrrr...Must...Not...Start...License...Flame...War...\n\n", "msg_date": "Tue, 9 May 2000 10:21:43 -0400 (EDT)", "msg_from": "\"Cary O'Brien\" <[email protected]>", "msg_from_op": true, "msg_subject": "Commercializing PostgreSQL: What do you thing?" }, { "msg_contents": "\"Cary O'Brien\" <[email protected]> writes:\n> What do people think about this?\n\nThere are announcements about this in the pgsql-announce mail queue\nright now. Followup discussion should probably be in pgsql-general,\nnot pghackers, because it's not really a coding issue...\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 09 May 2000 11:02:59 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Commercializing PostgreSQL: What do you thing? " }, { "msg_contents": ">>>\"Cary O'Brien\" said:\n > \n > What do people think about this?\n > \n > \thttp://news.cnet.com/news/0-1003-200-1841316.html?tag=st.ne.ron.lthd.ni\n > \n > It makes me uneasy.\n\nMe too. Especially the last sentence about PostgreSQL 7.0 being released \ntoday. But hey... this is commercial announcement anyway :)\n\nDaniel\n\n\n\n\n\n", "msg_date": "Tue, 09 May 2000 21:18:35 +0300", "msg_from": "Daniel Kalchev <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Commercializing PostgreSQL: What do you thing? " }, { "msg_contents": "On Tue, 9 May 2000, Daniel Kalchev wrote:\n\n> >>>\"Cary O'Brien\" said:\n> > \n> > What do people think about this?\n> > \n> > \thttp://news.cnet.com/news/0-1003-200-1841316.html?tag=st.ne.ron.lthd.ni\n> > \n> > It makes me uneasy.\n> \n> Me too. Especially the last sentence about PostgreSQL 7.0 being released \n> today. But hey... this is commercial announcement anyway :)\n\nHuh? What about PgSQL 7.0 being released today? *raised eyebrow*\n\n\n", "msg_date": "Tue, 9 May 2000 14:26:29 -0400 (EDT)", "msg_from": "\"Marc G. Fournier\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Commercializing PostgreSQL: What do you thing? " } ]
[ { "msg_contents": "Hi all,\n\nWhile testing vacuum,I noticed that dirty buffers aren't\nnecessarily written to disk in case of abort.\nIn addtion they have no guarantee to be flushed before\nthe shutdown of postmaster. The recent bufmgr changes\nseems to have increased the possibility much more than\nbefore.\nCertainly it's not bad unless there are indexes. However\nif heap data wasn't flushed while corresponding indices\nare written to disk,the indices would point to non-existence\nheap block. It would be the cause of inconsistency after the\nrestart of postmaster. Shouldn't there be a mechanism to\nflush dirty buffers at(or before) the shutdown of postmaster ?\n\nComments ?\n\nRegards. \n\nHiroshi Inoue\[email protected]\n", "msg_date": "Tue, 9 May 2000 23:34:17 +0900", "msg_from": "\"Hiroshi Inoue\" <[email protected]>", "msg_from_op": true, "msg_subject": "Shouldn't flush dirty buffers at shutdown ?" }, { "msg_contents": "\"Hiroshi Inoue\" <[email protected]> writes:\n> if heap data wasn't flushed while corresponding indices\n> are written to disk,the indices would point to non-existence\n> heap block. It would be the cause of inconsistency after the\n> restart of postmaster. Shouldn't there be a mechanism to\n> flush dirty buffers at(or before) the shutdown of postmaster ?\n\nHmm, good point, but that doesn't seem like the right answer.\nSuppose the system crashes before we are able to flush the\ndirty buffers? I think you have identified a problem that needs\na more general solution: we need to be robust in the case that\nan index entry is on disk that points to a tuple that never made\nit to disk. We can legitimately assume that the tuple is uncommitted\nand ignore the index entry --- we just have to not fail ;-)\n\nNot sure how to do it offhand; maybe some additional checking in the\nindex fetch code will do?\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 09 May 2000 10:49:31 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Shouldn't flush dirty buffers at shutdown ? " }, { "msg_contents": "> -----Original Message-----\n> From: Tom Lane [mailto:[email protected]]\n> Sent: Tuesday, May 09, 2000 11:50 PM\n> \n> \"Hiroshi Inoue\" <[email protected]> writes:\n> > if heap data wasn't flushed while corresponding indices\n> > are written to disk,the indices would point to non-existence\n> > heap block. It would be the cause of inconsistency after the\n> > restart of postmaster. Shouldn't there be a mechanism to\n> > flush dirty buffers at(or before) the shutdown of postmaster ?\n> \n> Hmm, good point, but that doesn't seem like the right answer.\n> Suppose the system crashes before we are able to flush the\n> dirty buffers?\n\nYou are right but we could hardly expect the completeness\nof indexes in case of system crash because indexes are out\nof transactional control currently. What surprized me was that\nsuch problems could easily occur even in case of graceful\nshutdown of postmaster.\n \n> I think you have identified a problem that needs\n> a more general solution: we need to be robust in the case that\n> an index entry is on disk that points to a tuple that never made\n> it to disk.\n\nProbably an index entry that points to a non-existent heap\nblock doesn't cause a problem immediately because heap_\nfetch() ignores UNUSED heap blocks.\nHowever it will not be long before the heap block is filled with\nanother tuple. heap_insert/update() could hardly check that\nthe inserting heap block is already pointed from some index\nentry.\n\nThere could be another case which I came across while\ntesting vacuum abort. i.e,index_delete() wasn't flushed while\nthe corresponding heap block is cleaned(set to UNUSED) \nand flushed. \n\nRegards.\n\nHiroshi Inoue\[email protected] \n", "msg_date": "Wed, 10 May 2000 02:14:43 +0900", "msg_from": "\"Hiroshi Inoue\" <[email protected]>", "msg_from_op": true, "msg_subject": "RE: Shouldn't flush dirty buffers at shutdown ? " }, { "msg_contents": "\"Hiroshi Inoue\" <[email protected]> writes:\n>> Hmm, good point, but that doesn't seem like the right answer.\n>> Suppose the system crashes before we are able to flush the\n>> dirty buffers?\n\n> You are right but we could hardly expect the completeness\n> of indexes in case of system crash because indexes are out\n> of transactional control currently.\n\nWhat? We do flush the index blocks before committing, just the\nsame as heap blocks, so I do not see the risk there. If we have\ncommitted a tuple then its index entries should be on disk too.\nThe risk I think you have shown is that there may be extra index\nentries that correspond to no tuple because we wrote the index\nblocks first and then crashed before writing the tuple.\n\n> Probably an index entry that points to a non-existent heap\n> block doesn't cause a problem immediately because heap_\n> fetch() ignores UNUSED heap blocks.\n> However it will not be long before the heap block is filled with\n> another tuple. heap_insert/update() could hardly check that\n> the inserting heap block is already pointed from some index\n> entry.\n\nYes. We need some way of cross-checking that an index entry actually\ndoes match the tuple it thinks it's pointing at. The first thought that\ncomes to mind is that the index tuple should contain the OID of the\ntuple it is for, and then we can check that against the pointed-to\ntuple. If they don't match, the index entry is bogus and can be\ndiscarded at the next VACUUM.\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 09 May 2000 13:20:07 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Shouldn't flush dirty buffers at shutdown ? " } ]
[ { "msg_contents": "\nJust sent out the announcement for v7.0 ... the tree is now tag'd for v7.0\nas REL7_0 ... \n\nI would like to do a version v7.0.1 followup release by June 1st, and\ncreate a branch at that time so that work can begin on v7.1 ... \n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Tue, 9 May 2000 13:43:41 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "She's out the door ..." }, { "msg_contents": "Vince Vielhaber wrote:\n> \n> The md5 sources I got from Sverre (think I got that name right) were ready\n> out of the box. I redid the test program to take just a string and\n> return the md5 hash. I tested it on HP 9 & 10 (the HP8 machine with the\n> ansi compiler on it disappeared so I'll test it when it resurfaces), IRIX,\n> FreeBSD 3.2 and DOS/95/98/2k/NT - compiles cleanly and runs on each. I'd\n> like to see if it still compiles and runs on some other platforms. I have\n> the tarball sitting at:\n> \n> http://www.pop4.net/~vev/mdstuff.tar.gz\n> \n> To build and test it, unpack it, run make then try it:\n> \n> $ test asdf\n\nor better try \n\n$ ./test asf\n\nif you are on any unix platform\n\n----------------\nHannu\n", "msg_date": "Tue, 09 May 2000 19:50:48 +0300", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": false, "msg_subject": "Re: MD5" }, { "msg_contents": "\nThe md5 sources I got from Sverre (think I got that name right) were ready\nout of the box. I redid the test program to take just a string and\nreturn the md5 hash. I tested it on HP 9 & 10 (the HP8 machine with the\nansi compiler on it disappeared so I'll test it when it resurfaces), IRIX,\nFreeBSD 3.2 and DOS/95/98/2k/NT - compiles cleanly and runs on each. I'd\nlike to see if it still compiles and runs on some other platforms. I have\nthe tarball sitting at:\n\n http://www.pop4.net/~vev/mdstuff.tar.gz\n\nTo build and test it, unpack it, run make then try it:\n\n$ test asdf\n912ec803b2ce49e4a541068d495ab570 asdf\n\nAn ansi compiler is required - do we support any non-ansi compilers? If\nso I'll make some changes to the sources.\n\nAnyone who tests, please send me the platform you tried it on and the\nresults. I'd like to find a long word list to make some comparison \ntests with, but it doesn't look like I ever got around to installing\na dictionary or spellchecker on any of my machines!!\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Tue, 9 May 2000 13:03:52 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "MD5" }, { "msg_contents": "Vince Vielhaber <[email protected]> writes:\n> An ansi compiler is required - do we support any non-ansi compilers? If\n> so I'll make some changes to the sources.\n\nWe've required ANSI-style prototypes all along. There are some other\nANSI features we're willing to work around the lack of, like token\npasting in macros --- so the real question is *what* ANSI features\ndoes the code require?\n\n> I'd like to find a long word list to make some comparison \n> tests with, but it doesn't look like I ever got around to installing\n> a dictionary or spellchecker on any of my machines!!\n\nJust feed it a bunch of files. MD5 is supposed to work on any length\ninput ...\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 09 May 2000 13:26:27 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: MD5 " }, { "msg_contents": "Tom Lane writes:\n\n> We've required ANSI-style prototypes all along. There are some other\n> ANSI features we're willing to work around the lack of, like token\n> pasting in macros ---\n\nYou must mean this stuff: :-)\n\n[src/include/nodes/nodes.h]\n| #define nodeTag(nodeptr) (((Node*)(nodeptr))->type)\n| \n| #define makeNode(_type_) ((_type_*) newNode(sizeof(_type_),T_##_type_))\n| #define NodeSetTag(nodeptr,t) (((Node*)(nodeptr))->type = (t))\n| \n| #define IsA(nodeptr,_type_) (nodeTag(nodeptr) == T_##_type_)\n\nThere are some provisions for working around this, but evidently they're\nnot used uniformly (which leads me to believe that there's little need to\ndo so).\n\n> so the real question is *what* ANSI features does the code require?\n\nI think it's fair to assume an ANSI C89 compiler in the year 2000, based\non the fact that we don't actually seem to consciously avoid any\nconstructs I know of, modulo the Autoconf safety net.\n\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Wed, 10 May 2000 18:32:45 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: MD5 " }, { "msg_contents": "Peter Eisentraut <[email protected]> writes:\n> Tom Lane writes:\n>> We've required ANSI-style prototypes all along. There are some other\n>> ANSI features we're willing to work around the lack of, like token\n>> pasting in macros ---\n\n> You must mean this stuff: :-)\n\nHmm, good point. I guess that HAVE_STRINGIZE stuff in c.h is dead code\nafter all, at least on the platforms people have tried Postgres on.\n\n> I think it's fair to assume an ANSI C89 compiler in the year 2000, based\n> on the fact that we don't actually seem to consciously avoid any\n> constructs I know of, modulo the Autoconf safety net.\n\nThis is really a consequence of our development process: since we accept\npatches from people who haven't studied the source very carefully, the\nlevel of adherence to coding standards is pretty variable. Portability\nproblems get flushed out when someone reports \"it doesn't work here\",\nbut there's no process for removing no-longer-needed portability hacks.\nLooks like HAVE_STRINGIZE is in that category now...\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 10 May 2000 12:38:37 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: MD5 " } ]
[ { "msg_contents": "> > I think you have identified a problem that needs\n> > a more general solution: we need to be robust in the case that\n> > an index entry is on disk that points to a tuple that never made\n> > it to disk.\n\nAnd this general solution is WAL.\n\nVadim\n", "msg_date": "Tue, 9 May 2000 10:22:06 -0700 ", "msg_from": "\"Mikheev, Vadim\" <[email protected]>", "msg_from_op": true, "msg_subject": "RE: Shouldn't flush dirty buffers at shutdown ? " }, { "msg_contents": "> -----Original Message-----\n> From: Mikheev, Vadim [mailto:[email protected]]\n> \n> > > I think you have identified a problem that needs\n> > > a more general solution: we need to be robust in the case that\n> > > an index entry is on disk that points to a tuple that never made\n> > > it to disk.\n> \n> And this general solution is WAL.\n>\n\nYes exactly.\nBut I've thought it's mainly for aborts in the middle of btree page\nsplitting or for system crash in which we couldn't expect synchronous\nflushing of dirty buffers.\n \nNow I feel I couldn't stop postmaster easily.\nFor example I have to read a sufficiently large table to\nflush dirty buffers before shutdown of postmaster in my\ntest case. Must I recommend everyone to do so ?\n\nRegards.\n\nHiroshi Inoue\[email protected] \n", "msg_date": "Wed, 10 May 2000 08:38:31 +0900", "msg_from": "\"Hiroshi Inoue\" <[email protected]>", "msg_from_op": false, "msg_subject": "RE: Shouldn't flush dirty buffers at shutdown ? " } ]
[ { "msg_contents": "Hi folks\n\nFew questions..\n\n1: Has anyone found a way to fake INNER JOINS, basically I'm helping someone\nconvert some MSSQL code over to Postgres and they use INNER JOINS heavly\n\n2: Have any of y'all ever seeen this error\n\n\"\"transformExpr: does not know how to transform node 501 (internal error)\"\n\nfrom statement:\n\n\"SELECT DISTINCT ss.stateID, ss.stateValue FROM State ss INNER JOIN Standard\nst ON ss.stateID = st.stateID\"\n\n It stikes me as kinda strange because first and formost it should complain about\nthe INNER JOIN and not this other thing. \n\n\n3: what is the maximum depth of nested sub queries ?\n\n4: just out of the blue, how great or not great is our alpha support ?\n\nJeff\n\n\n", "msg_date": "Tue, 9 May 2000 15:53:43 -0300 (ADT)", "msg_from": "Jeff MacDonald <[email protected]>", "msg_from_op": true, "msg_subject": "misc questions" }, { "msg_contents": "Jeff MacDonald <[email protected]> writes:\n> 1: Has anyone found a way to fake INNER JOINS, basically I'm helping someone\n> convert some MSSQL code over to Postgres and they use INNER JOINS heavly\n\nYou shouldn't have to fake it --- Thomas alleges that INNER JOIN syntax\nworks now.\n\n> 2: Have any of y'all ever seeen this error\n\n> \"\"transformExpr: does not know how to transform node 501 (internal error)\"\n\n> from statement:\n\n> \"SELECT DISTINCT ss.stateID, ss.stateValue FROM State ss INNER JOIN Standard\n> st ON ss.stateID = st.stateID\"\n\nCongratulations, our first 7.0 bug report! It fails for me too. 501 is\ntype T_List, so it looks like some list-slinging is going wrong.\n\n> 3: what is the maximum depth of nested sub queries ?\n\nNo hard and fast limit, but they might be pretty slow if you nest them\nreal deep ... sub-selects aren't implemented especially efficiently ...\n\n> 4: just out of the blue, how great or not great is our alpha support ?\n\nEr ... what?\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 09 May 2000 16:39:35 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: misc questions " }, { "msg_contents": "On Tue, 9 May 2000, Tom Lane wrote:\n\n> > 4: just out of the blue, how great or not great is our alpha support ?\n> \n> Er ... what?\n\nAlpha, as in the computer ... \n\nAccording to:\n\nhttp://www.postgresql.org/users-lounge/7.0/docs/admin/ports.htm#AEN284\n\nwe're good to go on:\n\nCompaq Tru64 5.0\nLinux 2.0.x\n\n\n", "msg_date": "Tue, 9 May 2000 18:13:29 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: misc questions " }, { "msg_contents": "> http://www.postgresql.org/users-lounge/7.0/docs/admin/ports.htm#AEN284\n> we're good to go on:\n> Compaq Tru64 5.0\n> Linux 2.0.x\n\nAs noted on that page, published patches are required for the Linux\nversion (probably due to 64 bit issues with the function manager).\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Wed, 10 May 2000 05:44:02 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: misc questions" }, { "msg_contents": "Thomas,\n\nI looked at Jeff MacDonald's gripe:\n\nJeff MacDonald <[email protected]> writes:\n> 2: Have any of y'all ever seeen this error\n> \"\"transformExpr: does not know how to transform node 501 (internal error)\"\n> from statement:\n> \"SELECT DISTINCT ss.stateID, ss.stateValue FROM State ss INNER JOIN Standard\n> st ON ss.stateID = st.stateID\"\n\n(which behavior is in fact duplicated in the join regress test!) and\nfind that it looks like it would work, except that there is confusion in\nthe parser about whether pstate->p_join_quals is a list of expressions\nor just an expression.\n\nAs far as I can see, there is no need for it to be a list, so we have\na choice of fixing it either by consistently making it be a list, or\nconsistently making it *not* be a list. I'd lean to the latter on\ngrounds of simplicity, but I wonder whether you intended it to be\na list because you were looking forward to some currently-unimplemented\nfeature that does need it to be a list.\n\nComments?\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 10 May 2000 20:58:38 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: misc questions " }, { "msg_contents": "> > 2: Have any of y'all ever seeen this error\n> > \"\"transformExpr: does not know how to transform node 501 (internal error)\"\n> > from statement:\n> > \"SELECT DISTINCT ss.stateID, ss.stateValue FROM State ss INNER JOIN Standard\n> > st ON ss.stateID = st.stateID\"\n> \n> (which behavior is in fact duplicated in the join regress test!) and\n> find that it looks like it would work, except that there is confusion in\n> the parser about whether pstate->p_join_quals is a list of expressions\n> or just an expression.\n> \n> As far as I can see, there is no need for it to be a list, so we have\n> a choice of fixing it either by consistently making it be a list, or\n> consistently making it *not* be a list. I'd lean to the latter on\n> grounds of simplicity, but I wonder whether you intended it to be\n> a list because you were looking forward to some currently-unimplemented\n> feature that does need it to be a list.\n\nI'm not recalling anything requiring a list here. Lists are floating\naround for other cases (e.g. the USING clause). Not sure why this\nwasn't caught in the regression test earlier (but clearly it was\nbecause I didn't spot it :(\n\nI'd be inclined to go with the non-list, simplest solution; we know\nwhere to look if it needs to be augmented later.\n\n - Thomas\n\n-- \nThomas Lockhart\t\t\t\[email protected]\nSouth Pasadena, California\n", "msg_date": "Thu, 11 May 2000 05:47:45 +0000", "msg_from": "Thomas Lockhart <[email protected]>", "msg_from_op": false, "msg_subject": "Re: misc questions" }, { "msg_contents": "Thomas Lockhart <[email protected]> writes:\n> I'd be inclined to go with the non-list, simplest solution; we know\n> where to look if it needs to be augmented later.\n\nRoger, will work on that.\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 11 May 2000 02:26:50 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: misc questions " } ]
[ { "msg_contents": "Hi,\n\nI was trying to create a table that inherites from a parent table. I have\nto use the fields both from the parent table and the child table to define\nthe primary key. Unfortunately I was not able to do that. It can not find\nthe fields from the parent table and give me the error \"column .. does not\nexist\". I can not specify the fields by using parenttable.column either. I\nhave read the documentations and there is nothing in the inheritance chapter\ntalking about primary key. Is there a way to specify primary key in the\nchild table using columns from parent table? I am using 6.5.0. Helps will\nbe greatly appreciated.\n\nWenjin Zheng\nBioinformatic Analyst\nLarge Scale Biology\n3333 Vaca Valley Parkway\nVacaville, CA 95688\n(707)469-2353\nemail: [email protected] \n\n", "msg_date": "Tue, 9 May 2000 12:00:50 -0700 ", "msg_from": "Wenjin Zheng <[email protected]>", "msg_from_op": true, "msg_subject": "Primary Key on Inherited Table" }, { "msg_contents": "Wenjin Zheng <[email protected]> writes:\n> Is there a way to specify primary key in the child table using columns\n> from parent table? I am using 6.5.0.\n\nIt sounds like the PRIMARY KEY spec is getting processed before the\nparent table reference is expanded. That's probably a bug, but it's\nnot going to get fixed in 6.5 ;-). What I'd suggest is not relying\non the PRIMARY KEY syntax, but just writing out the equivalent CREATE\nUNIQUE INDEX command separately after you create the child table.\n\n(Strictly speaking, PRIMARY KEY also implies NOT NULL on each column,\nwhich might be hard to duplicate if you don't want the same columns\nto be NOT NULL in the parent, but as long as you can set them that\nway in the parent you don't need PRIMARY KEY.)\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 09 May 2000 17:10:28 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Primary Key on Inherited Table " }, { "msg_contents": "Tom Lane wrote:\n> \n> Wenjin Zheng <[email protected]> writes:\n> > Is there a way to specify primary key in the child table using columns\n> > from parent table? I am using 6.5.0.\n> \n> It sounds like the PRIMARY KEY spec is getting processed before the\n> parent table reference is expanded. That's probably a bug, but it's\n> not going to get fixed in 6.5 ;-). What I'd suggest is not relying\n> on the PRIMARY KEY syntax, but just writing out the equivalent CREATE\n> UNIQUE INDEX command separately after you create the child table.\n> \n> (Strictly speaking, PRIMARY KEY also implies NOT NULL on each column,\n> which might be hard to duplicate if you don't want the same columns\n> to be NOT NULL in the parent, but as long as you can set them that\n> way in the parent you don't need PRIMARY KEY.)\n\nIMHO primary key itself should be one of inherited \"attributes\", and \nit should be unique over all parents and children.\n\nThis is hard to enforce under current \"inheritance\".\n\nI think that use of inheritance as it is in current PostgreSQL should \nbe discouraged.\n\nThere has been some discussion about making PostgreSQL a real ORDBMS\nbut as I understood the work was pushed back to wait for 7.0.\n\nDoing small incremental \"fixes\" like the above would make it harder \nto get true OO features in the main code later, as people start to \nrely on \"inheritance\" for convenience features (like creating some \ntables with similar fields) some of which will have to be altered \nwhen fixing some more fundamental flaws in current PostgreSQL OO \narchitecture (inheriting primary and foreign keys and other \nconstraints, making alter table add column work, making it \npossible to dump/reload inherited tables that have added columns, \netc.).\n\n------------\nHannu\n", "msg_date": "Wed, 10 May 2000 12:15:21 +0300", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Primary Key on Inherited Table" }, { "msg_contents": "On Wed, 10 May 2000, Hannu Krosing wrote:\n> Tom Lane wrote:\n> > \n> > Wenjin Zheng <[email protected]> writes:\n> > > Is there a way to specify primary key in the child table using columns\n> > > from parent table? I am using 6.5.0.\n> \n> IMHO primary key itself should be one of inherited \"attributes\", and \n> it should be unique over all parents and children.\n> \n> I think that use of inheritance as it is in current PostgreSQL should \n> be discouraged.\n> \n> There has been some discussion about making PostgreSQL a real ORDBMS\n> but as I understood the work was pushed back to wait for 7.0.\n> \n\nI also ran into this problem of not being able to use an inherited attrib\nas a primary key. I sent out some email (by accident when I wasn't really even\nfinished with it (strange)!) about the distinction between inheriting and\nextending a class. Inherit is a very general term. I have broken it down into\nCLONES, EXTENDS, and ASSIMILATES (please consider):\n\nEXTENDS is the case where a child shares the same primary key as one of its\nparents. The parent and child use the same storage of\ncommon attributes and the child table really only stores the unique information\nwith row references back to its parent(s) to get the other attribs. EXTENDS\ncreates a connected tree where the parent can't be dropped because its dependent\nchildren are connected to it. The child IS the parent(s), just concatenated\ntogether and with some (possibly) new attributes. In a way, this might be like\na special VIEW that also has its own new attributes.\n\nIn INHERITS (CLONES), the child just gets a COPY of the parent(s) structure with\noptions to specify inherited attribs in a primary key. The child's primary key\nvalues, like all its other attribs, are not shared with the parent. The child\ncould use the same sequence as a parent from which to get unique id values. The\nchild would be independent of the parent after being created so that the parent\ncould be dropped without any problem. This is like a new tree or cloning a\ntree. The parent would store a reference to the children so that select * from\nparent*; would work. This seems to be about how the current implementation of\nINHERITS works now except you can't drop the parent. It will give you an error\nif you try. Instead of saying INHERITS, the word CLONES might be more clear.\nThe original is the master of its clones - it can see them. But like real\ncloning, the originals can die, leaving just the clones.\n\nASSIMILATES might be a combination of CLONES and EXTENDS, where\nreference counts on attributes would be used to keep track of them. When the\nreference count on an attribute is 0, no parent or child uses it, and it can be\ndropped. A child could assimilate a parent, but the parent could still be\ndropped. The child would continue to keep a reference on the attributes of the\nparent. Only data rows used by just the parent alone would get deleted from the\nattributes when the parent is dropped. You might say something like CREATE\nTABLE child () ASSIMILATES(parent); This method allows the ability to exclude\nsome of the parents attributes from being inherited by the child. SELECT\nattrib1, attrib2, ... from child*; would output all of the selected\nattributes values, not just the instances it contributed to the columns. Of\ncourse, when doing the select above, it would have to output entire rows. The\nsystem would have to find all classes that use the same rows together and make a\nunion. The storage of the attributes might involve maintaining\nsections for each class that uses it. Actually, all classes that share\nattributes using this method form a collective, not really a parent/child\nrelationship. For this to work, the attributes have to be more\nobject-oriented, independent, and external to the classes that actually use\nthem. So, when creating a table, you are in the process of creating new\nattribute objects that other new classes can assimilate.\n\nHere are some examples of cases using all three of these:\n\nEx. 1 CLONES\nI want to create a child based on parent. All attributes are inherited. Parent\nshould be able to see all the children and select common attributes recursively\nthrough the children and grandchildren etc. The parent should be able to die\nand the children remain independent.\nSolution: CREATE TABLE child (...) CLONES(parent);\n\nEx. 2 EXTENDS\nI want to create a child based on parent. I want to share the primary key and\nattributes inherited from the parent with the parent. All attributes are\ninherited. The child simply extends the parent with additional attributes that\nmake it more specialized. The child will depend on the parent for storage of\nattributes it inherits(uses). When I insert into child, I want the parents\nattributes inserted into the parent, and just the extended attributes stored in\nthe child. The child can be dropped and the attributes it added to the parent\nmay persist or be deleted by option of child (the child may leave an\ninheritance to the parent!).\nSolution: CREATE TABLE child (...) EXTENDS(parent);\n\nEx. 3 ASSIMILATES\nI want to create a child based on parent. I might not want to inherit all\nattributes of parent. I don't care if the parent is later dropped - the child\nshares the parents attributes with the other survivers. I want to share\nattributes storage with the parent (while it exists) and its other siblings,\nthat is, the parent see the data it has in common with the child. The child\ncan select attributes in common with the parent and all its other siblings! I\nmight want the child to share a primary key with the parent (which might also\nbe a primary key of other siblings) by choosing to inherit it. I want the\nchild to join the parent (and its other siblings) as a collective. Solution: \nCREATE TABLE child (...) ASSIMILATES(parent);\n\nAll the methods above use inheritance of attributes from a base class, just in\ndifferent ways. INHERIT may be too general a term to use in describing all the\npossibilities.\n\nWell, anyhow, I hope some of this will be considered when the inheritance\nsystem in PostgreSQL is maybe redesigned.\n\n-- \nRobert B. Easter\[email protected]\n", "msg_date": "Wed, 10 May 2000 10:22:06 -0400", "msg_from": "\"Robert B. Easter\" <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Primary Key on Inherited Table" }, { "msg_contents": "\"Robert B. Easter\" <[email protected]> writes:\n> Inherit is a very general term. I have broken it down into\n> CLONES, EXTENDS, and ASSIMILATES (please consider):\n> [ much snipped ]\n\nI think you've put your finger on a fundamental issue: \"inheritance\"\nseems to mean different things to different people, depending on how\nthey are trying to use it. Rather than arguing about who is right,\nwe have to recognize that they're all right in their own contexts.\nThe trick is to figure out how to support all those variant usages.\n\nI'm not sure that you've proposed quite the right conceptual breakdown.\nMy inclination would be to try to specify several independent\nimplementation properties that can be mixed & matched to create the\nbehaviors that different applications want. But clearly you are\nthinking about the right problem.\n\nI hope that Chris Bitmead will pop up and contribute to this thread;\nawhile ago he was bugging us regularly about shortcomings in Postgres'\ninheritance support, but I'm afraid he might've got discouraged and\ngone away :-(. (If you have not done so already, I suggest you search\nthe pghackers archives for threads mentioning inheritance. Chris\npointed out a lot of problems and interesting application examples\na year or so ago.)\n\nI do have to tell you that most of the core developers are not thinking\nmuch about inheritance --- we are busy with SQL92 compatibility,\nperformance, reliability, and other low-level concerns. I'd love to see\nsomeone step up to the plate and start working on inheritance as such.\n\n> Well, anyhow, I hope some of this will be considered when the inheritance\n> system in PostgreSQL is maybe redesigned.\n\nDo I hear a volunteer? ;-)\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 11 May 2000 01:23:19 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Primary Key on Inherited Table " } ]
[ { "msg_contents": "I'm getting an odd error in the configure scripts:\n\n. . .\nchecking for gzcat... (cached) /usr/local/gnu/bin/gzcat\nchecking for perl... (cached) perl\nconfigure: error: Can't find method to convert from upper to lower case\nwith tr\n\nI'm compiling this in Red Hat 6.0\n\n----------------------------------------------------------------\nTravis Bauer | CS Grad Student | IU |www.cs.indiana.edu/~trbauer\n----------------------------------------------------------------\n\n", "msg_date": "Tue, 9 May 2000 17:45:12 -0500 (EST)", "msg_from": "Travis Bauer <[email protected]>", "msg_from_op": true, "msg_subject": "Problems compiling version 7" }, { "msg_contents": "Travis Bauer <[email protected]> writes:\n> I'm getting an odd error in the configure scripts:\n> . . .\n> checking for gzcat... (cached) /usr/local/gnu/bin/gzcat\n> checking for perl... (cached) perl\n> configure: error: Can't find method to convert from upper to lower case\n> with tr\n\n> I'm compiling this in Red Hat 6.0\n\nWeird. Do you not have 'tr' in your PATH? You wouldn't be running with\nsome bizarre LOCALE setting, by any chance?\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 09 May 2000 19:10:16 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Problems compiling version 7 " }, { "msg_contents": "I have tr version 1.22 (GNU texutils). It is located in /usr/bin, and is\nfound by my login shell (cshrc).\n\nHow could I check the locale setting? \n\nThanks,\n\n----------------------------------------------------------------\nTravis Bauer | CS Grad Student | IU |www.cs.indiana.edu/~trbauer\n----------------------------------------------------------------\n\nOn Tue, 9 May 2000, Tom Lane wrote:\n\n> > checking for gzcat... (cached) /usr/local/gnu/bin/gzcat\n> > checking for perl... (cached) perl\n> > configure: error: Can't find method to convert from upper to lower case\n> > with tr\n> \n> > I'm compiling this in Red Hat 6.0\n> \n> Weird. Do you not have 'tr' in your PATH? You wouldn't be running with\n> some bizarre LOCALE setting, by any chance?\n> \n\n", "msg_date": "Tue, 9 May 2000 22:21:15 -0500 (EST)", "msg_from": "Travis Bauer <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Problems compiling version 7 " }, { "msg_contents": "Travis Bauer <[email protected]> writes:\n> I have tr version 1.22 (GNU texutils). It is located in /usr/bin, and is\n> found by my login shell (cshrc).\n\nThat was a weak theory, but worth checking ...\n\n> How could I check the locale setting? \n\necho $LOCALE I think --- someone who actually uses non-ASCII locales\nwould be a better reference than I. But the critical bit here is the\npart of configure.in that's trying to find the right platform-specific\ntr invocation:\n\ndnl Check tr flags to convert from lower to upper case\nTRSTRINGS=\"`echo ABCdef | $TR '[[a-z]]' '[[A-Z]]' 2>/dev/null | grep ABCDEF`\"\nTRCLASS=\"`echo ABCdef | $TR '[[:lower:]]' '[[:upper:]]' 2>/dev/null | grep ABCDEF`\"\n\nif test \"$TRSTRINGS\" = \"ABCDEF\"; then\n\tTRARGS=\"'[[a-z]]' '[[A-Z]]'\"\nelif test \"$TRCLASS\" = \"ABCDEF\"; then\n\tTRARGS=\"'[[:lower:]]' '[[:upper:]]'\"\nelse\n\tAC_MSG_ERROR(\"Can\\'t find method to convert from upper to lower case with tr\")\nfi\n\n(hmm ... the error message is exactly backwards from what's actually\nbeing tested, isn't it? Minor point but...) Anyway, try these out\nand see what's happening with your 'tr'. Note that the apparently\ndoubled square brackets are a quoting artifact of autoconf --- you\nshould actually test [a-z] and so on, not [[a-z]].\n\nThe really silly bit is that configure.in has several other invocations\nof tr that pay no attention at all to the results so painfully extracted\n(or mis-extracted) here. So it kinda looks to me like we could rip out\nthis test, hardwire the translation as\n\ttr '[a-z]' '[A-Z]'\nand be no worse off. Does anyone recall why this test is in there to\nbegin with?\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 09 May 2000 23:43:55 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Problems compiling version 7 " } ]
[ { "msg_contents": "> > > > I think you have identified a problem that needs\n> > > > a more general solution: we need to be robust in the case that\n> > > > an index entry is on disk that points to a tuple that never made\n> > > > it to disk.\n> > \n> > And this general solution is WAL.\n> >\n> Yes exactly.\n> But I've thought it's mainly for aborts in the middle of btree page\n> splitting or for system crash in which we couldn't expect synchronous\n> flushing of dirty buffers.\n\nCentral idea of WAL - write (and flush) to log all changes made in data\nbuffers _before_ data files will be changed. Buffer mgmr will be\nresponsible for this. Changes made in table buffers will be logged before\nchanges made in index ones, redo will insert un-inserted table rows and\nindex rows will not point to unexistent tuples in table. Undo will erase\nall uncommitted changes (but will not shrink tables/indices).\n\nVadim\n \n\n", "msg_date": "Tue, 9 May 2000 17:06:30 -0700 ", "msg_from": "\"Mikheev, Vadim\" <[email protected]>", "msg_from_op": true, "msg_subject": "RE: Shouldn't flush dirty buffers at shutdown ? " }, { "msg_contents": "> -----Original Message-----\n> From: Mikheev, Vadim [mailto:[email protected]]\n> \n> > > > > I think you have identified a problem that needs\n> > > > > a more general solution: we need to be robust in the case that\n> > > > > an index entry is on disk that points to a tuple that never made\n> > > > > it to disk.\n> > > \n> > > And this general solution is WAL.\n> > >\n> > Yes exactly.\n> > But I've thought it's mainly for aborts in the middle of btree page\n> > splitting or for system crash in which we couldn't expect synchronous\n> > flushing of dirty buffers.\n> \n> Central idea of WAL - write (and flush) to log all changes made in data\n> buffers _before_ data files will be changed. Buffer mgmr will be\n> responsible for this. Changes made in table buffers will be logged before\n> changes made in index ones, redo will insert un-inserted table rows and\n> index rows will not point to unexistent tuples in table. Undo will erase\n> all uncommitted changes (but will not shrink tables/indices).\n>\n\nYes WAL would naturally solve a current flaw of index updation as a part\nof its effect.\nWhat I've never understood until recently is that even normal aborts(not\nin the middle of b-tree splitting) and normal shutdown could cause an\ninconsistency between heap and indices. \n\nRegards.\n\nHiroshi Inoue\[email protected]\n", "msg_date": "Wed, 10 May 2000 12:27:56 +0900", "msg_from": "\"Hiroshi Inoue\" <[email protected]>", "msg_from_op": false, "msg_subject": "RE: Shouldn't flush dirty buffers at shutdown ? " }, { "msg_contents": "\"Hiroshi Inoue\" <[email protected]> writes:\n> What I've never understood until recently is that even normal aborts(not\n> in the middle of b-tree splitting) and normal shutdown could cause an\n> inconsistency between heap and indices. \n\nYes. Since WAL will provide the real solution in 7.1, I think we need\nonly look for a simple stopgap answer for 7.0.x. Perhaps we could just\ntweak bufmgr.c so that dirty buffers are flushed out on both transaction\ncommit and abort. That doesn't solve the consistency-after-crash issue,\nbut at least you can do an orderly shutdown of a postmaster without\nfear. Is it worth trying to do more now, rather than working on WAL?\n\n\t\t\tregards, tom lane\n", "msg_date": "Tue, 09 May 2000 23:47:39 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Shouldn't flush dirty buffers at shutdown ? " }, { "msg_contents": "> -----Original Message-----\n> From: Tom Lane [mailto:[email protected]]\n>\n> \"Hiroshi Inoue\" <[email protected]> writes:\n> > What I've never understood until recently is that even normal aborts(not\n> > in the middle of b-tree splitting) and normal shutdown could cause an\n> > inconsistency between heap and indices.\n>\n> Yes. Since WAL will provide the real solution in 7.1, I think we need\n> only look for a simple stopgap answer for 7.0.x. Perhaps we could just\n> tweak bufmgr.c so that dirty buffers are flushed out on both transaction\n> commit and abort. That doesn't solve the consistency-after-crash issue,\n> but at least you can do an orderly shutdown of a postmaster without\n> fear. Is it worth trying to do more now, rather than working on WAL?\n>\n\nHmm,performance vs. consistency.\nI vote for consistency this time.\nHowever other people may prefer performance because the\nconsistency isn't complete in any case and 7.1 would provide\na real solution.\n\nRegards.\n\nHiroshi Inoue\[email protected]\n\n", "msg_date": "Wed, 10 May 2000 14:39:06 +0900", "msg_from": "\"Hiroshi Inoue\" <[email protected]>", "msg_from_op": false, "msg_subject": "RE: Shouldn't flush dirty buffers at shutdown ? " }, { "msg_contents": "> -----Original Message-----\n> From: Tom Lane [mailto:[email protected]]\n>\n> \"Hiroshi Inoue\" <[email protected]> writes:\n> > What I've never understood until recently is that even normal aborts(not\n> > in the middle of b-tree splitting) and normal shutdown could cause an\n> > inconsistency between heap and indices.\n>\n> Yes. Since WAL will provide the real solution in 7.1, I think we need\n> only look for a simple stopgap answer for 7.0.x. Perhaps we could just\n> tweak bufmgr.c so that dirty buffers are flushed out on both transaction\n> commit and abort. That doesn't solve the consistency-after-crash issue,\n> but at least you can do an orderly shutdown of a postmaster without\n> fear. Is it worth trying to do more now, rather than working on WAL?\n>\n\nI have another anxiety now.\nAs far as I see,PostgreSQL doesn't call LockBuffer() before\ncalling smgrwrite(). This seems to mean that smgrwrite()\ncould write buffers to disk which are being changed by\nanother backend. If the(another) backend was aborted by\nsome reason the buffer page would remain half-changed.\n\nIs it well known ? Please correct me if I'm wrong.\n\nRegards.\n\nHiroshi Inoue\[email protected]\n\n", "msg_date": "Fri, 26 May 2000 12:17:18 +0900", "msg_from": "\"Hiroshi Inoue\" <[email protected]>", "msg_from_op": false, "msg_subject": "smgrwrite() without LockBuffer(was RE: Shouldn't flush dirty buffers\n\tat shutdown ?)" }, { "msg_contents": "\"Hiroshi Inoue\" <[email protected]> writes:\n> As far as I see,PostgreSQL doesn't call LockBuffer() before\n> calling smgrwrite(). This seems to mean that smgrwrite()\n> could write buffers to disk which are being changed by\n> another backend. If the(another) backend was aborted by\n> some reason the buffer page would remain half-changed.\n\nHmm ... looks fishy to me too. Seems like we ought to hold\nBUFFER_LOCK_SHARE on the buffer while dumping it out. It\nwouldn't matter under normal circumstances, but as you say\nthere could be trouble if the other backend crashed before\nit could mark the buffer dirty again, or if we had a system\ncrash before the dirtied page got written again.\n\nVadim, what do you think?\n\n\t\t\tregards, tom lane\n", "msg_date": "Thu, 25 May 2000 23:40:13 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: smgrwrite() without LockBuffer(was RE: Shouldn't flush dirty\n\tbuffers at shutdown ?)" } ]
[ { "msg_contents": "On Tue, 9 May 2000, Merrill Oveson wrote:\n\n> Jan Wieck wrote:\n> \n> > Hi all,\n> >\n> > during the past hours I had severe problems with email.\n> > Somehow hub.org seemed to have forgotten my subscriptions to\n> > the PostgreSQL GENERAL, HACKERS and SQL lists.\n> >\n> > Actually I'm scanning the mail archives for anything of\n> > interest. If someone feels I've missed something, give me a\n> > kick.\n> >\n> > Jan\n> >\n> > --\n> >\n> > #======================================================================#\n> > # It's easier to get forgiveness for being wrong than for being right. #\n> > # Let's break this rule - forgive me. #\n> > #================================================== [email protected] #\n> \n> I haven't been able to subscribe to the digest. I get the following error:\n> \n> >>>> subscribe pgsql-sql-digest\n> Illegal list \"pgsql-sql-digest\".\n> No valid commands processed.\n> \n> I am subscribed to the general mailing list however.\n\nThe whole subscription thing changed over a month ago ... there is no\nlonger a '-digest' list to subscribe to. Instead, you have to subscribe\nto the central list and then change your state to 'digest' ...\n\nI *believe* that:\n\nsubscribe-digest pgsql-sql\n\nwill do it all in one step now ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Tue, 9 May 2000 22:12:37 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: [SQL] Mail problems" } ]
[ { "msg_contents": "\nHello,\n\nI just installed PG 7.0 and did some testing. I found what I believe is\na strange behaviour:\n\nxtnet=# \\d telecom\n Table \"telecom\"\n Attribute | Type | Modifier \n-----------+-------------+----------\n regione | varchar(20) | \n distretto | varchar(20) | \n settore | varchar(20) | \n descriz | varchar(60) | \n cor_x | float8 | \n cor_y | float8 | \n cod_dis | varchar(4) | \n rete_urb | varchar(24) | \n\nxtnet=# create index telecom_regione on telecom ( regione );\nCREATE\n\nxtnet=# explain select distinct on (regione) * from telecom;\nNOTICE: QUERY PLAN:\n\nUnique (cost=0.00..4777.43 rows=3910 width=88)\n -> Index Scan using telecom_regione on telecom (cost=0.00..4679.68\nrows=39100 width=88)\n\nEXPLAIN\n\nxtnet=# explain select distinct on (regione) regione from telecom;\nNOTICE: QUERY PLAN:\n\nUnique (cost=4370.91..4468.66 rows=3910 width=12)\n -> Sort (cost=4370.91..4370.91 rows=39100 width=12)\n -> Seq Scan on telecom (cost=0.00..1079.00 rows=39100\nwidth=12)\n\nEXPLAIN\n\nxtnet=# explain select distinct on (regione) distretto,regione from\ntelecom;\nNOTICE: QUERY PLAN:\n\nUnique (cost=4492.72..4590.47 rows=3910 width=24)\n -> Sort (cost=4492.72..4492.72 rows=39100 width=24)\n -> Seq Scan on telecom (cost=0.00..1079.00 rows=39100\nwidth=24)\n\nEXPLAIN\n\nIt seems like the index is used only if * appears in the target list.\n???\n\nBye!\n\n-- \n Daniele\n\n-------------------------------------------------------------------------------\n Daniele Orlandi - Utility Line Italia - http://www.orlandi.com\n Via Mezzera 29/A - 20030 - Seveso (MI) - Italy\n-------------------------------------------------------------------------------\n", "msg_date": "Wed, 10 May 2000 05:07:38 +0200", "msg_from": "Daniele Orlandi <[email protected]>", "msg_from_op": true, "msg_subject": "Not using index" }, { "msg_contents": "Daniele Orlandi <[email protected]> writes:\n> [ example snipped ]\n> It seems like the index is used only if * appears in the target list.\n\nThere is certainly not a dependence on * as such. However, the\nestimated row width does affect the cost estimate for operations like\nSORT, where we have to guess how many rows will fit in memory. It looks\nto me like your example case is right near the boundary where the system\nthinks that index scan and sort are of roughly equal cost, so relatively\nsmall changes will push the choice in one direction or the other.\nThis should not be taken as an indication that someone actually\nconsidered the specific examples and decided it should act that way!\nIt just falls out of the behavior of the cost-estimate-driven planner\nstructure. Ideally, the hope is not that this sort of choice is\nperfectly right all the time; my ambition only extends to the hope that\nif the system thinks index scan and sort are of roughly equal cost,\nthen indeed they are, and so it wouldn't matter a whole lot which one\ngets picked.\n\nOf course we aren't all that close to meeting the ideal goal :-(.\nI'm assuming that you are complaining because one or the other of\nthese plans is actually much cheaper than the other in your example.\nYou have, however, carefully refrained from giving us any hint which.\nCare to fess up with more details?\n\n\t\t\tregards, tom lane\n", "msg_date": "Wed, 10 May 2000 02:18:23 -0400", "msg_from": "Tom Lane <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Not using index " }, { "msg_contents": "Tom Lane wrote:\n> \n> There is certainly not a dependence on * as such.\n\nYes, that was pretty strange, but, not knowing the internals of the\noptimizer, I wondered why a change in the target list could have changed\nthe decision of the optimizer.\n\n> However, the estimated row width does affect the cost estimate for operations\n> like SORT, where we have to guess how many rows will fit in memory. It looks\n> to me like your example case is right near the boundary where the system\n> thinks that index scan and sort are of roughly equal cost, so relatively\n> small changes will push the choice in one direction or the other.\n\nYes this is what's happening. I progressively adding attributes to the\ntargets list and, at some point, the optimizer choosed the other\nalternative.\n\n> I'm assuming that you are complaining because one or the other of\n> these plans is actually much cheaper than the other in your example.\n\nYes, more than 12:1 ratio.\n\n> You have, however, carefully refrained from giving us any hint which.\n> Care to fess up with more details?\n\nYes, of course, I hope the following statistics can help you :\n\nThis one is the result of vacuum on the table:\n\nNOTICE: Pages 688: Changed 0, reaped 0, Empty 0, New 0; Tup 39100: Vac\n0, Keep/VTL 0/0, Crash 0, UnUsed 0, MinLen 100, MaxLen 201; Re-using:\nFree/Avail. Space 0/0; EndEmpty/Avail. Pages 0/0. CPU 0.04s/3.37u sec.\nNOTICE: Index telecom_settore: Pages 145; Tuples 39100. CPU 0.01s/0.07u\nsec.\nNOTICE: Index telecom_distretto: Pages 156; Tuples 39100. CPU\n0.01s/0.06u sec.\nNOTICE: Index telecom_regione: Pages 136; Tuples 39100. CPU 0.01s/0.06u\nsec.\n\nThis one is with the index:\n! system usage stats:\n!\t0.909758 elapsed 0.830000 user 0.050000 system sec\n!\t[0.870000 user 0.060000 sys total]\n!\t0/0 [0/0] filesystem blocks in/out\n!\t282/14 [429/279] page faults/reclaims, 0 [0] swaps\n!\t0 [0] signals rcvd, 0/0 [0/0] messages rcvd/sent\n!\t0/0 [0/0] voluntary/involuntary context switches\n! postgres usage stats:\n!\tShared blocks: 845 read, 0 written, buffer hit rate =\n97.86%\n!\tLocal blocks: 0 read, 0 written, buffer hit rate =\n0.00%\n!\tDirect blocks: 0 read, 0 written\n\nThis one is without the index:\n! system usage stats:\n!\t12.529637 elapsed 12.360000 user 0.150000 system sec\n!\t[12.380000 user 0.190000 sys total]\n!\t0/0 [0/0] filesystem blocks in/out\n!\t508/360 [695/657] page faults/reclaims, 0 [0] swaps\n!\t0 [0] signals rcvd, 0/0 [0/0] messages rcvd/sent\n!\t0/0 [0/0] voluntary/involuntary context switches\n! postgres usage stats:\n!\tShared blocks: 688 read, 1 written, buffer hit rate =\n0.72%\n!\tLocal blocks: 0 read, 0 written, buffer hit rate =\n0.00%\n!\tDirect blocks: 0 read, 0 written\n\nIf you need other statistics/tests, just ask and I will be happy to help\nyou.\n\nBye!\n\n-- \n Daniele\n\n-------------------------------------------------------------------------------\n Daniele Orlandi - Utility Line Italia - http://www.orlandi.com\n Via Mezzera 29/A - 20030 - Seveso (MI) - Italy\n-------------------------------------------------------------------------------\n", "msg_date": "Thu, 11 May 2000 03:09:20 +0200", "msg_from": "Daniele Orlandi <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Not using index" } ]
[ { "msg_contents": "\"Henry B. Hotz\" <[email protected]> writes:\n>If I understand the original objection it's that passwords are stored \n>in cleartext on the postmaster machine.\n\nYou understand the original objection, but you don't understand the basis for\nthe objection.\n\n>That's not much of an \n>objection since you have to have your secrets available in the clear \n>on both ends of a connection if you want the traffic on the \n>connection secured.\n\nThis is true. However, the problem is that people reuse passwords. By \nhashing the password on both ends of the connection with a known random \nsalt, you achieve the same result as if people did not reuse passwords,\ni.e., a root compromise of the postgres server will not give the perpetrator\naccess to anything other than the specific postgres account on that server.\n\nWithout encryption, such a compromise would very likely lead to further \ncompromises of other services secured by the same password as was used for\npostgres access.\n\nUsers are their own worst enemy. This is a small thing we can do to protect\nthem from themselves.\n\n\t-Michael\n\n", "msg_date": "Wed, 10 May 2000 12:48:48 +0800 (+0800)", "msg_from": "Michael Robinson <[email protected]>", "msg_from_op": true, "msg_subject": "Re:" } ]
[ { "msg_contents": "I'v ebeen asked to write an article comparing these two. Before I agree I'd\nlike to know if anyone's having some pointers for me.\n\nMichael\n-- \nMichael Meskes | Go SF 49ers!\nTh.-Heuss-Str. 61, D-41812 Erkelenz | Go Rhein Fire!\nTel.: (+49) 2431/72651 | Use Debian GNU/Linux!\nEmail: [email protected] | Use PostgreSQL!\n", "msg_date": "Wed, 10 May 2000 09:38:54 +0200", "msg_from": "Michael Meskes <[email protected]>", "msg_from_op": true, "msg_subject": "Comparison PostgreSQL 7.0 vs. Interbase2000" }, { "msg_contents": "\nI get this while trying to search the hackers mailing list:\n\nAn error occured! \n\nconnectDB() -- connect() failed: Connection refused Is the postmaster\nrunning (with -i) at 'pgsql.tht.net' and accepting connections on TCP/IP\nport '5432'? \n", "msg_date": "Wed, 10 May 2000 07:54:49 GMT", "msg_from": "\"Kaare Rasmussen\" <[email protected]>", "msg_from_op": false, "msg_subject": "Oops! Searching mailing lists..." } ]
[ { "msg_contents": "\n> I'v ebeen asked to write an article comparing these two. Before I agree \n> like to know if anyone's having some pointers for me.\n\nThere has been some discussion on this list some time ago. You can look in\nthe archices on www.postgresql.org for Jan-Feb-Mar 2000.\n\nUnfortunately, the search engine is down, and the overview by index and\ndate only has the last week of each month, so your only option right now is\nto take the mbox format and wade through it.\n", "msg_date": "Wed, 10 May 2000 10:37:42 GMT", "msg_from": "\"Kaare Rasmussen\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Comparison PostgreSQL 7.0 vs. Interbase2000 (fwd)" }, { "msg_contents": "On Wed, 10 May 2000, Kaare Rasmussen wrote:\n\n> \n> > I'v ebeen asked to write an article comparing these two. Before I agree \n> > like to know if anyone's having some pointers for me.\n> \n> There has been some discussion on this list some time ago. You can look in\n> the archices on www.postgresql.org for Jan-Feb-Mar 2000.\n> \n> Unfortunately, the search engine is down, and the overview by index and\n> date only has the last week of each month, so your only option right now is\n> to take the mbox format and wade through it.\n\nI just checked now, and other then being slower then it was (am\ninvestigating that), it just returned results for me ... we are havign a\nproblem that is under investigation where the postmaster freezes up for no\napparent reason, requiring a manual restart, so its possible that you got\ncaught by that :(\n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 10 May 2000 08:54:53 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Comparison PostgreSQL 7.0 vs. Interbase2000 (fwd)" }, { "msg_contents": "\n> > Unfortunately, the search engine is down, and the overview by index and\n> > date only has the last week of each month, so your only option right now > > to take the mbox format and wade through it.\n\n> I just checked now, and other then being slower then it was (am\n> investigating that), it just returned results for me ... we are havign a\n> problem that is under investigation where the postmaster freezes up for no\n> apparent reason, requiring a manual restart, so its possible that you got\n> caught by that :(\n\nIt _is_ slow alright! I'm trying a search and after a couple of minutes I\nstill haven't received a reply. Did you remember to vacuum the dabasase? \n:-)\n\nOK, now I got an answer, but what about the second problem, that if you go\nto the hackers mailing list and select by index or by thread, you only get\nthe last week of each month?\n\n-- \nKaare Rasmussen --Linux, spil,-- Tlf: 3816 2582\nKaki Data tshirts, merchandize Fax: 3816 2582\nHowitzvej 75 ���ben 14.00-18.00 Email: [email protected]\n2000 Frederiksberg L���rdag 11.00-17.00 Web: www.suse.dk\n", "msg_date": "Wed, 10 May 2000 12:03:01 GMT", "msg_from": "\"Kaare Rasmussen\" <[email protected]>", "msg_from_op": true, "msg_subject": "Re: Comparison PostgreSQL 7.0 vs. Interbase2000 (fwd)" }, { "msg_contents": "On Wed, 10 May 2000, Kaare Rasmussen wrote:\n\n> \n> > > Unfortunately, the search engine is down, and the overview by index and\n> > > date only has the last week of each month, so your only option right now > > to take the mbox format and wade through it.\n> \n> > I just checked now, and other then being slower then it was (am\n> > investigating that), it just returned results for me ... we are havign a\n> > problem that is under investigation where the postmaster freezes up for no\n> > apparent reason, requiring a manual restart, so its possible that you got\n> > caught by that :(\n> \n> It _is_ slow alright! I'm trying a search and after a couple of minutes I\n> still haven't received a reply. Did you remember to vacuum the dabasase? \n> :-)\n\nYup *nod* \n\n> OK, now I got an answer, but what about the second problem, that if\n> you go to the hackers mailing list and select by index or by thread,\n> you only get the last week of each month?\n\nAs I mentioned to someone else recently, you might want to check out that\nlink at the top of the page, that has always been there, that says \"next\npage\"? :)\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 10 May 2000 09:18:41 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": false, "msg_subject": "Re: Comparison PostgreSQL 7.0 vs. Interbase2000 (fwd)" } ]
[ { "msg_contents": "\nTom Lane writes:\n>Vince Vielhaber <[email protected]> writes:\n>> An ansi compiler is required - do we support any non-ansi compilers? If\n>> so I'll make some changes to the sources.\n>\n>We've required ANSI-style prototypes all along. There are some other\n>ANSI features we're willing to work around the lack of, like token\n>pasting in macros --- so the real question is *what* ANSI features\n>does the code require?\n\nCouldn't check yesterday, so I just did. It appears to be mainly the\nprototypes, size_t and void - although size_t and void were in the \nprototypes, so we should be ok. But I would like to see what other\nplatforms are seeing - just in case. So far I have:\n\nFreeBSD 2.2.6-R, 3.2-R, 4.0-R\nHP-UX 9.x, 10.x\nIRIX64 6.4\nLinux 2.2.13 (mandrake)\nWindows 95/98/2k/nt/DOS\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n\n", "msg_date": "Wed, 10 May 2000 07:19:57 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": true, "msg_subject": "Re: MD5" } ]
[ { "msg_contents": "On Wed, 10 May 2000, Peter Eisentraut wrote:\n\n> On Tue, 9 May 2000, Tom Lane wrote:\n> \n> > > 1) You have a bootstrapping problem, because how are you going to set\n> > > these privileges if you can't connect?\n> > \n> > Presumably the database superuser can connect to anything anytime, and\n> > I'd also expect a newly-minted database to be preconfigured to let its\n> > owner in.\n> \n> Let's say your database is password protected (as was Marc's original\n> setup). Somebody connects. There's no password set up for him (because\n> he didn't have access to modify pg_hba.conf). What do you do? Leave\n> him through anyway to check whether he's a superuser or database\n> owner? How do you know *who* he is at all without doing a password\n> check?\n\nHuh? Since when are passwords setup in pg_hba.conf? If a database has\npassword set, and user doesn't have password to make the initial connect,\nthey should be refused at the postmaster end of things, and never get to\nthe backend. If they have a passwd and its right, then they should get\ninto the backend, where the first check is to see if they are allowed to\naccess the database itself ...\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 10 May 2000 08:47:58 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??'; " }, { "msg_contents": "The Hermit Hacker writes:\n\n> Huh? Since when are passwords setup in pg_hba.conf?\n\nThe fact that password authenticaton is to be used for a given (set\nof) databases is communicated through pg_hba.conf. Furthermore, the use of\na separate password file can be specified in pg_hba.conf (which is\ncurrently the only way to disallow access to certain users when using\npasswords).\n\n> If a database has password set,\n\nA database doesn't \"have a password set\", a user does. A database may be\naccessible through password authentication (see above).\n\n> and user doesn't have password to make the initial connect, they\n> should be refused at the postmaster end of things, and never get to\n> the backend.\n\nBut this is not what you said earlier. You said superusers or database\nowners should get through either way. I said that doesn't work under this\nmodel because you must pass password authentication first to be allowed to\npose as a particular user. \n\n> If they have a passwd and its right, then they should get into the\n> backend, where the first check is to see if they are allowed to access\n> the database itself ...\n\nThat makes a lot of sense but as I mentioned earlier you would have to\nstart up backends for a much higher fraction of potential connections, to\nwhich you objected. Tom pointed out that trying to avoid this might be\npretty pointless though. I concur.\n\nOn the implementation side this would probably mean some shared system\nrelation pg_dbaccess ( dbid, userid ). Then you could overload GRANT and\nREVOKE to act on this table. We could replace the database name field in\npg_hba.conf with some special character (e.g., `-') to indicate \"look in\npg_dbaccess\".\n\nI think I'd like that. It cleanly separates host-based authentication from\ndatabase-based authorization...\n\n(On the other hand, what it doesn't accomplish is `use this auth. method\nonly for these users' or `use this method, or failing that this other\nmethod'-- as people occasionally request -- but IMHO this is better left\nto something like PAM.)\n\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Wed, 10 May 2000 23:25:45 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??'; " } ]
[ { "msg_contents": "On Wed, 10 May 2000, Peter Eisentraut wrote:\n\n> On Tue, 9 May 2000, The Hermit Hacker wrote:\n> \n> > CREATE DATABASE WITH OWNER?\n> \n> Databases already have owners, so this syntax extensions (not a bad idea\n> IMHO) isn't going to change the substance of things really.\n\ntables have owners .. right now, as far as I can tell, the database itself\ndoesn't have an owner. Unless I'm missing something, any user that can\nconnect to a database can create new tables in that database, regardless\nof what they can do to the existing tables in that database ...\n\n\n", "msg_date": "Wed, 10 May 2000 08:49:09 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??';" }, { "msg_contents": "The Hermit Hacker wrote:\n> \n> On Wed, 10 May 2000, Peter Eisentraut wrote:\n> \n> > On Tue, 9 May 2000, The Hermit Hacker wrote:\n> >\n> > > CREATE DATABASE WITH OWNER?\n> >\n> > Databases already have owners, so this syntax extensions (not a bad idea\n> > IMHO) isn't going to change the substance of things really.\n> \n> tables have owners .. right now, as far as I can tell, the database itself\n> doesn't have an owner. Unless I'm missing something, any user that can\n> connect to a database can create new tables in that database, regardless\n> of what they can do to the existing tables in that database ...\n\nhannu=# select * from pg_database;\n datname | datdba | encoding | datpath \n-----------+--------+----------+-----------\n template1 | 501 | 0 | template1\n hannu | 501 | 0 | hannu\n(2 rows)\n\nI'm pretty sure that the datdba field is the owner id.\n\nThat anyone is allowed to do anything is another matter.\n\n-----------------\nHannu\n", "msg_date": "Wed, 10 May 2000 15:47:31 +0300", "msg_from": "Hannu Krosing <[email protected]>", "msg_from_op": false, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??';" }, { "msg_contents": "The Hermit Hacker writes:\n\n> tables have owners .. right now, as far as I can tell, the database itself\n> doesn't have an owner.\n\npeter ~/pg-install/bin$ ./psql -l\n List of databases\n Database | Owner\n-----------+-------\n peter | peter\n template1 | peter\n(2 rows)\n\n> Unless I'm missing something, any user that can connect to a database\n> can create new tables in that database, regardless of what they can do\n> to the existing tables in that database ...\n\nThat is true, but IMHO schemas are are much better way to handle that.\n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Wed, 10 May 2000 23:24:59 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: CREATE DATABASE WITH OWNER '??';" } ]
[ { "msg_contents": "\nWell, that would explain that, now, wouldn't it? did we remove this\nsomewhere along the way? *raised eyebrow*\n\npgsql% find . -name \"*.[ch]\" -exec grep setproctitle {} \\; -print\npgsql% pwd\n/pgsql/src/pgsql/src\npgsql% \n\n\nMarc G. Fournier ICQ#7615664 IRC Nick: Scrappy\nSystems Administrator @ hub.org \nprimary: [email protected] secondary: scrappy@{freebsd|postgresql}.org \n\n", "msg_date": "Wed, 10 May 2000 08:57:12 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "setproctitle() no longer used?" }, { "msg_contents": "The Hermit Hacker writes:\n\n> Well, that would explain that, now, wouldn't it? did we remove this\n> somewhere along the way? *raised eyebrow*\n\nThere was no setproctitle in 6.5.* either.\n\nI'm guessing that the argv[0] = \"the string you want\" method no longer\nworks in FreeBSD 4.0??? In any case, as per previous discussion, I did\nwrite up a more portable and robust setproctitle-like implementation for\nour use (which actually uses setproctitle if available), so if this is the\nproblem it's at least being worked on.\n\n> pgsql% find . -name \"*.[ch]\" -exec grep setproctitle {} \\; -print\n> pgsql% pwd\n> /pgsql/src/pgsql/src\n> pgsql% \n\n-- \nPeter Eisentraut Sernanders v�g 10:115\[email protected] 75262 Uppsala\nhttp://yi.org/peter-e/ Sweden\n\n", "msg_date": "Wed, 10 May 2000 23:25:15 +0200 (CEST)", "msg_from": "Peter Eisentraut <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "[Charset ISO-8859-1 unsupported, filtering to ASCII...]\n> The Hermit Hacker writes:\n> \n> > Well, that would explain that, now, wouldn't it? did we remove this\n> > somewhere along the way? *raised eyebrow* \n> \n> There was no setproctitle in 6.5.* either.\n> \n> I'm guessing that the argv[0] = \"the string you want\" method no longer\n> works in FreeBSD 4.0??? In any case, as per previous discussion, I did\n\nI am quite surprised. I though all BSD's allows this. It is done using\nkvm. I am not sure the ps thing works in the backend process is swapped\nout.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Wed, 10 May 2000 17:35:25 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "On Wed, 10 May 2000, Peter Eisentraut wrote:\n\n> The Hermit Hacker writes:\n> \n> > Well, that would explain that, now, wouldn't it? did we remove this\n> > somewhere along the way? *raised eyebrow*\n> \n> There was no setproctitle in 6.5.* either.\n> \n> I'm guessing that the argv[0] = \"the string you want\" method no longer\n> works in FreeBSD 4.0??? In any case, as per previous discussion, I did\n> write up a more portable and robust setproctitle-like implementation for\n> our use (which actually uses setproctitle if available), so if this is the\n> problem it's at least being worked on.\n\nD'oh, okay...I ended up going through the v6.5.* source code too, and\ncouldn't find it there. I forget how Bruce had implemented it using\nargv[0], and yes, it is definitely broken on FreeBSD 4.0 ...\n\nI'll look at doing the change here locally, since I know\nsetproctitle() does work, as I find it invaluable to know what is running,\nand where ...\n\n\n", "msg_date": "Wed, 10 May 2000 19:16:54 -0300 (ADT)", "msg_from": "The Hermit Hacker <[email protected]>", "msg_from_op": true, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "> D'oh, okay...I ended up going through the v6.5.* source code too, and\n> couldn't find it there. I forget how Bruce had implemented it using\n> argv[0], and yes, it is definitely broken on FreeBSD 4.0 ...\n> \n> I'll look at doing the change here locally, since I know\n> setproctitle() does work, as I find it invaluable to know what is running,\n> and where ...\n\nCan you find out if it is broken, or they have stopped supporting it in\nFreeBSD.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Wed, 10 May 2000 18:30:17 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "On Wed, 10 May 2000, Bruce Momjian wrote:\n\n> > D'oh, okay...I ended up going through the v6.5.* source code too, and\n> > couldn't find it there. I forget how Bruce had implemented it using\n> > argv[0], and yes, it is definitely broken on FreeBSD 4.0 ...\n> > \n> > I'll look at doing the change here locally, since I know\n> > setproctitle() does work, as I find it invaluable to know what is running,\n> > and where ...\n> \n> Can you find out if it is broken, or they have stopped supporting it in\n> FreeBSD.\n\nIn 4.0-Rel they're not saying it's gone or going away, just that you \nneed to link with -lutil if you use it. They also state that there's\nno standard but that they believe they're using the predominant\nconvention.\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Wed, 10 May 2000 18:59:38 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "> On Wed, 10 May 2000, Bruce Momjian wrote:\n> \n> > > D'oh, okay...I ended up going through the v6.5.* source code too, and\n> > > couldn't find it there. I forget how Bruce had implemented it using\n> > > argv[0], and yes, it is definitely broken on FreeBSD 4.0 ...\n> > > \n> > > I'll look at doing the change here locally, since I know\n> > > setproctitle() does work, as I find it invaluable to know what is running,\n> > > and where ...\n> > \n> > Can you find out if it is broken, or they have stopped supporting it in\n> > FreeBSD.\n> \n> In 4.0-Rel they're not saying it's gone or going away, just that you \n> need to link with -lutil if you use it. They also state that there's\n> no standard but that they believe they're using the predominant\n> convention.\n\nSo if you use -lutil, the argv[0] trick works, and if you don't, it\ndoesn't? If so, we can get that into the FreeBSD template.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Wed, 10 May 2000 19:02:20 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "On Wed, 10 May 2000, Bruce Momjian wrote:\n\n> > On Wed, 10 May 2000, Bruce Momjian wrote:\n> > \n> > > > D'oh, okay...I ended up going through the v6.5.* source code too, and\n> > > > couldn't find it there. I forget how Bruce had implemented it using\n> > > > argv[0], and yes, it is definitely broken on FreeBSD 4.0 ...\n> > > > \n> > > > I'll look at doing the change here locally, since I know\n> > > > setproctitle() does work, as I find it invaluable to know what is running,\n> > > > and where ...\n> > > \n> > > Can you find out if it is broken, or they have stopped supporting it in\n> > > FreeBSD.\n> > \n> > In 4.0-Rel they're not saying it's gone or going away, just that you \n> > need to link with -lutil if you use it. They also state that there's\n> > no standard but that they believe they're using the predominant\n> > convention.\n> \n> So if you use -lutil, the argv[0] trick works, and if you don't, it\n> doesn't? If so, we can get that into the FreeBSD template.\n\n'splain the \"argv[0] trick\" briefly.\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Wed, 10 May 2000 19:06:21 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "> > So if you use -lutil, the argv[0] trick works, and if you don't, it\n> > doesn't? If so, we can get that into the FreeBSD template.\n> \n> 'splain the \"argv[0] trick\" briefly.\n\nIt is a nifty BSD one. If you assign argv[0] in the program to a\nstring, it shows in ps.\n\n\targv[0] = \"new ps string\";\n\nThe Linux method is:\n\n\tstrcpy(argv[0], \"new ps string\");\n\nIn the second case, you are actually writing into the environment area\nuse to store args. Not real great, but it works on Linux.\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Wed, 10 May 2000 19:07:46 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "On Wed, 10 May 2000, Bruce Momjian wrote:\n\n> > > So if you use -lutil, the argv[0] trick works, and if you don't, it\n> > > doesn't? If so, we can get that into the FreeBSD template.\n> > \n> > 'splain the \"argv[0] trick\" briefly.\n> \n> It is a nifty BSD one. If you assign argv[0] in the program to a\n> string, it shows in ps.\n> \n> \targv[0] = \"new ps string\";\n> \n> The Linux method is:\n> \n> \tstrcpy(argv[0], \"new ps string\");\n> \n> In the second case, you are actually writing into the environment area\n> use to store args. Not real great, but it works on Linux.\n\nThis does not:\n\n#include <stdio.h>\n#include <sys/types.h>\n#include <libutil.h>\n\n\nint main(int numargs, char *argv[])\n{\nint ii;\n\n argv[0] = \"Postgres Power!\";\n\n for(ii=0;ii<100;ii++) sleep(1);\n\nreturn 0;\n}\n\n$ cc test.c -lutil -o test\n$ ./test\n\nmaking it strcpy(argv[0],\"Postgres Power!\"); didn't either.\n\nBut:\n\nmaking it: setproctitle(\"Postgres Power!\"); gives this:\n\n34273 p3 S 0:00.00 test: Postgres Power! (test)\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Wed, 10 May 2000 19:48:22 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "> On Wed, 10 May 2000, Bruce Momjian wrote:\n> \n> > > > So if you use -lutil, the argv[0] trick works, and if you don't, it\n> > > > doesn't? If so, we can get that into the FreeBSD template.\n> > > \n> > > 'splain the \"argv[0] trick\" briefly.\n> > \n> > It is a nifty BSD one. If you assign argv[0] in the program to a\n> > string, it shows in ps.\n> > \n> > \targv[0] = \"new ps string\";\n> > \n> > The Linux method is:\n> > \n> > \tstrcpy(argv[0], \"new ps string\");\n> > \n> > In the second case, you are actually writing into the environment area\n> > use to store args. Not real great, but it works on Linux.\n> \n> This does not:\n> \n> #include <stdio.h>\n> #include <sys/types.h>\n> #include <libutil.h>\n> \n> \n> int main(int numargs, char *argv[])\n> {\n> int ii;\n> \n> argv[0] = \"Postgres Power!\";\n> \n> for(ii=0;ii<100;ii++) sleep(1);\n> \n> return 0;\n> }\n> \n> $ cc test.c -lutil -o test\n> $ ./test\n> \n> making it strcpy(argv[0],\"Postgres Power!\"); didn't either.\n> \n> But:\n> \n> making it: setproctitle(\"Postgres Power!\"); gives this:\n> \n> 34273 p3 S 0:00.00 test: Postgres Power! (test)\n\nWell, that's interesting. Our issue with setproctitle is how fast it\nis. Every query changes its proctitle, so it has to be fast. Tom want\nto have setproctitle on backend startup, then use the fast method on\nplatforms that support it.\n\nDoes the existing postgres ps title code work on your Linux?\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Wed, 10 May 2000 19:56:22 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "On Wed, 10 May 2000, Bruce Momjian wrote:\n\n> > On Wed, 10 May 2000, Bruce Momjian wrote:\n> > \n> > > > > So if you use -lutil, the argv[0] trick works, and if you don't, it\n> > > > > doesn't? If so, we can get that into the FreeBSD template.\n> > > > \n> > > > 'splain the \"argv[0] trick\" briefly.\n> > > \n> > > It is a nifty BSD one. If you assign argv[0] in the program to a\n> > > string, it shows in ps.\n> > > \n> > > \targv[0] = \"new ps string\";\n> > > \n> > > The Linux method is:\n> > > \n> > > \tstrcpy(argv[0], \"new ps string\");\n> > > \n> > > In the second case, you are actually writing into the environment area\n> > > use to store args. Not real great, but it works on Linux.\n> > \n> > This does not:\n> > \n> > #include <stdio.h>\n> > #include <sys/types.h>\n> > #include <libutil.h>\n> > \n> > \n> > int main(int numargs, char *argv[])\n> > {\n> > int ii;\n> > \n> > argv[0] = \"Postgres Power!\";\n> > \n> > for(ii=0;ii<100;ii++) sleep(1);\n> > \n> > return 0;\n> > }\n> > \n> > $ cc test.c -lutil -o test\n> > $ ./test\n> > \n> > making it strcpy(argv[0],\"Postgres Power!\"); didn't either.\n> > \n> > But:\n> > \n> > making it: setproctitle(\"Postgres Power!\"); gives this:\n> > \n> > 34273 p3 S 0:00.00 test: Postgres Power! (test)\n> \n> Well, that's interesting. Our issue with setproctitle is how fast it\n> is. Every query changes its proctitle, so it has to be fast. Tom want\n> to have setproctitle on backend startup, then use the fast method on\n> platforms that support it.\n> \n> Does the existing postgres ps title code work on your Linux?\n\nI'm assuming you're not asking me..\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Wed, 10 May 2000 20:07:30 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "> > > making it: setproctitle(\"Postgres Power!\"); gives this:\n> > > \n> > > 34273 p3 S 0:00.00 test: Postgres Power! (test)\n> > \n> > Well, that's interesting. Our issue with setproctitle is how fast it\n> > is. Every query changes its proctitle, so it has to be fast. Tom want\n> > to have setproctitle on backend startup, then use the fast method on\n> > platforms that support it.\n> > \n> > Does the existing postgres ps title code work on your Linux?\n> \n> I'm assuming you're not asking me..\n\nI thought I was. :-)\n\nI now realize you are running FreeBSD. Yikes.\n\nSo neither works. Well, that is a problem. Does the -lutil help?\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Wed, 10 May 2000 20:12:12 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "On Wed, 10 May 2000, Bruce Momjian wrote:\n\n> > > > making it: setproctitle(\"Postgres Power!\"); gives this:\n> > > > \n> > > > 34273 p3 S 0:00.00 test: Postgres Power! (test)\n> > > \n> > > Well, that's interesting. Our issue with setproctitle is how fast it\n> > > is. Every query changes its proctitle, so it has to be fast. Tom want\n> > > to have setproctitle on backend startup, then use the fast method on\n> > > platforms that support it.\n> > > \n> > > Does the existing postgres ps title code work on your Linux?\n> > \n> > I'm assuming you're not asking me..\n> \n> I thought I was. :-)\n> \n> I now realize you are running FreeBSD. Yikes.\n> \n> So neither works. Well, that is a problem. Does the -lutil help?\n> \n> \n\nNo, I compiled every time with -lutil\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================\n\n\n\n", "msg_date": "Wed, 10 May 2000 20:16:39 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "> > I thought I was. :-)\n> > \n> > I now realize you are running FreeBSD. Yikes.\n> > \n> > So neither works. Well, that is a problem. Does the -lutil help?\n> > \n> > \n> \n> No, I compiled every time with -lutil\n\nOh. Can you look at the setproctitle code on your platform and see how\nit implements it?\n\n-- \n Bruce Momjian | http://www.op.net/~candle\n [email protected] | (610) 853-3000\n + If your life is a hard drive, | 830 Blythe Avenue\n + Christ can be your backup. | Drexel Hill, Pennsylvania 19026\n", "msg_date": "Wed, 10 May 2000 20:21:45 -0400 (EDT)", "msg_from": "Bruce Momjian <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" }, { "msg_contents": "On Wed, 10 May 2000, Bruce Momjian wrote:\n\n> > > I thought I was. :-)\n> > > \n> > > I now realize you are running FreeBSD. Yikes.\n> > > \n> > > So neither works. Well, that is a problem. Does the -lutil help?\n> > > \n> > > \n> > \n> > No, I compiled every time with -lutil\n> \n> Oh. Can you look at the setproctitle code on your platform and see how\n> it implements it?\n\nI've attached it since it's small.\n\nVince.\n-- \n==========================================================================\nVince Vielhaber -- KA8CSH email: [email protected] http://www.pop4.net\n 128K ISDN from $22.00/mo - 56K Dialup from $16.00/mo at Pop4 Networking\n Online Campground Directory http://www.camping-usa.com\n Online Giftshop Superstore http://www.cloudninegifts.com\n==========================================================================", "msg_date": "Wed, 10 May 2000 20:41:10 -0400 (EDT)", "msg_from": "Vince Vielhaber <[email protected]>", "msg_from_op": false, "msg_subject": "Re: setproctitle() no longer used?" } ]