Re: [GENERAL] Corruption of files in PostgreSQL

2007-06-02 Thread Paolo Bizzarri
Hi Tom, as explained above, the problem seems quite random. So I need to understand what we have to check. Best regards. Paolo Bizzarri Icube S.r.l. On 6/2/07, Tom Lane [EMAIL PROTECTED] wrote: Paolo Bizzarri [EMAIL PROTECTED] writes: Any hint? Please provide a reproducible test case ...

Re: [GENERAL] Continuous PITR (was Re: multimaster)

2007-06-02 Thread Greg Smith
On Fri, 1 Jun 2007, Ron Johnson wrote: How difficult would it be to modify the process (the postmaster?) that writes the xlogs(?) to tee them to a listening process across the cloud on the DR machine, which then applies them to the DR database? On an 8.2 server, you can practically do this

Re: [GENERAL] Corruption of files in PostgreSQL

2007-06-02 Thread Purusothaman A
Hi Tom Lane, In my case, we upload/download files to/from postgresql. And we don't change the content of the file after once loaded to postgresql. But as days going, more files stored to postgresql and never change file content after that. But download many times the stored files as per need.

Re: [GENERAL] why postgresql over other RDBMS

2007-06-02 Thread PFC
On Sat, 02 Jun 2007 00:14:28 +0200, Ron Johnson [EMAIL PROTECTED] wrote: On 06/01/07 16:38, PFC wrote: Will the synchronized seq scan patch be able to do this by issuing all the CREATE INDEX commands at the same time from several different database connections ? No, but it could

Re: [GENERAL] multimaster

2007-06-02 Thread PFC
Have you looked at raidb? http://c-jdbc.objectweb.org. Narrow niche, but if it happens to be the one you are in, then it's an option. I took a quick look at the user's page, and both of them were using PostgreSQL. I just love those Java guys. The world starts and ends

Re: [GENERAL] multimaster

2007-06-02 Thread Martijn van Oosterhout
On Sat, Jun 02, 2007 at 02:27:06AM +0200, Alexander Staubo wrote: What you are basically saying below is... web 2.0 developers such as rails developers have so fundamentally broken the way it is supposed to be done, we should too... I don't know if I said that, but I would love to hear how

Re: [GENERAL] warm standby server stops doingcheckpointsafterawhile

2007-06-02 Thread Simon Riggs
On Fri, 2007-06-01 at 23:14 +0200, Frank Wittig wrote: Teodor Sigaev schrieb: Hope, attached patch fix that. Pls, test it. It still happens. The log is full of incomplete split dumps: 2007-06-01 23:00:00.001 CEST:% LOG: GIN incomplete splits=8 2007-06-01 23:00:00.001 CEST:% CONTEXT:

Re: [GENERAL] multimaster

2007-06-02 Thread Rodrigo Gonzalez
Alexander Staubo wrote: On 6/2/07, Guy Rouillier [EMAIL PROTECTED] wrote: Have you looked at raidb? http://c-jdbc.objectweb.org. Narrow niche, but if it happens to be the one you are in, then it's an option. I took a quick look at the user's page, and both of them were using PostgreSQL.

Re: [GENERAL] multimaster

2007-06-02 Thread Alexander Staubo
On 6/2/07, Martijn van Oosterhout [EMAIL PROTECTED] wrote: I don't know if it's a general problem, but I've been involved in a using rails and it appears to have it's own way of declaring the database. It presumes to handle referential integrity and uniqueness in the application code (!). I

[GENERAL] Transactional DDL

2007-06-02 Thread Jasbinder Singh Bali
Hi, A few days back, it was commented by someone in the community that Postgres has this Transactional DDL feature. What I understand about Transactional DDL is something like this: begin --ddl 1 --ddl 2 end; I believe that if a database supports transactional ddl then ddl1 and

[GENERAL] Stored Procedures and Functions

2007-06-02 Thread Harpreet Dhaliwal
Hi, Is it true that postgres doesn't have a notion of Stored Procedures and functions is what it has instead? RDBMS like Sql Server supports both stored procedures and functions. So I was wondering what is the difference between a Stored Procedure and a function. Thanks, ~Harpreet

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Alexander Staubo
On 6/2/07, Jasbinder Singh Bali [EMAIL PROTECTED] wrote: [snip] I believe that if a database supports transactional ddl then ddl1 and ddl2 would commit together as a batch And If a Db doesn't support this transactional DDL feature then ddl1 executes and commits without even caring about ddl2.

Re: [GENERAL] Corruption of files in PostgreSQL

2007-06-02 Thread Tom Lane
Paolo Bizzarri [EMAIL PROTECTED] writes: On 6/2/07, Tom Lane [EMAIL PROTECTED] wrote: Please provide a reproducible test case ... as explained above, the problem seems quite random. So I need to understand what we have to check. In this context reproducible means that the failure happens

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Jasbinder Singh Bali
But its said that transactions in any RDBMS follow ACID properties. So if i put a create table and an Insert statement in the same begin end block as one single transactioin, won't both create and insert follow acid property, being in one single trasaction, and either both get committed or none,

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Michael Glaesemann
On Jun 2, 2007, at 10:12 , Jasbinder Singh Bali wrote: But its said that transactions in any RDBMS follow ACID properties. So if i put a create table and an Insert statement in the same begin end block as one single transactioin, won't both create and insert follow acid property, being in

Re: [GENERAL] Stored Procedures and Functions

2007-06-02 Thread Leif B. Kristensen
On Saturday 2. June 2007 16:47, Harpreet Dhaliwal wrote: Hi, Is it true that postgres doesn't have a notion of Stored Procedures and functions is what it has instead? RDBMS like Sql Server supports both stored procedures and functions. So I was wondering what is the difference between a Stored

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Harpreet Dhaliwal
Whats so novel about postgresql here? This would happen in any RDBMS. right? You induced divide by zero exception that crashed the whole transaction and it did not create the table bar? I can't see any Transactional DDL philosophy here. Could you please throw some more light on it to point out

Re: [GENERAL] Stored Procedures and Functions

2007-06-02 Thread Pavel Stehule
Hello Is it true that postgres doesn't have a notion of Stored Procedures and functions is what it has instead? RDBMS like Sql Server supports both stored procedures and functions. So I was wondering what is the difference between a Stored Procedure and a function. It's true. PostgreSQL

Re: [GENERAL] Stored Procedures and Functions

2007-06-02 Thread PFC
MySQL supports procedures and functions. Functions can return results but cannot update the database. Procedures can update the database but cannot return results. However : - a function can call a procedure that updates the database ! - a

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Dawid Kuroczko
On 6/2/07, Jasbinder Singh Bali [EMAIL PROTECTED] wrote: But its said that transactions in any RDBMS follow ACID properties. So if i put a create table and an Insert statement in the same begin end block as one single transactioin, won't both create and insert follow acid property, being in one

Re: [GENERAL] There can be only one! How to avoid the highlander-problem.

2007-06-02 Thread Erwin Brandstetter
On Jun 2, 2:43 am, [EMAIL PROTECTED] (Erwin Brandstetter) wrote: raise warning '%', kings; And remove this line of debug code. /Erwin ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Harpreet Dhaliwal
So, while writing any technical document, would it be wrong to mention stored procedures in postgresql? what is the general convention? On 6/2/07, Dawid Kuroczko [EMAIL PROTECTED] wrote: On 6/2/07, Jasbinder Singh Bali [EMAIL PROTECTED] wrote: But its said that transactions in any RDBMS

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Michael Glaesemann
On Jun 2, 2007, at 11:08 , Harpreet Dhaliwal wrote: Whats so novel about postgresql here? This would happen in any RDBMS. right? You induced divide by zero exception that crashed the whole transaction and it did not create the table bar? [Please don't top-post. It makes the discussion hard

Re: [GENERAL] query log corrupted-looking entries

2007-06-02 Thread George Pavlov
From: Tom Lane [mailto:[EMAIL PROTECTED] George Pavlov [EMAIL PROTECTED] writes: ... Also redirect_stderr = on. Hm. Well, that's the bit that ought to get you into the PIPE_BUF exception. There's been some speculation that a change like the attached would help. I've found that it makes

Re: One last Slony question (was Re: [GENERAL] Slightly OT.)

2007-06-02 Thread Andrew Sullivan
On Fri, Jun 01, 2007 at 06:15:40PM -0500, Ron Johnson wrote: Since DDL is infrequent, is that bottleneck an acceptable trade-off? I don't know. We'd have to do the analysis. But it could be a problem. Look at it this way: if you have a replica that is, for isntance, _always_ 30 minutes

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Jasbinder Singh Bali
On 6/2/07, Michael Glaesemann [EMAIL PROTECTED] wrote: On Jun 2, 2007, at 11:08 , Harpreet Dhaliwal wrote: Whats so novel about postgresql here? This would happen in any RDBMS. right? You induced divide by zero exception that crashed the whole transaction and it did not create the table

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Harpreet Dhaliwal
On 6/2/07, Jasbinder Singh Bali [EMAIL PROTECTED] wrote: On 6/2/07, Michael Glaesemann [EMAIL PROTECTED] wrote: On Jun 2, 2007, at 11:08 , Harpreet Dhaliwal wrote: Whats so novel about postgresql here? This would happen in any RDBMS. right? You induced divide by zero exception that

Re: [GENERAL] Slightly OT.

2007-06-02 Thread Andrew Sullivan
On Sat, Jun 02, 2007 at 01:30:53AM +0200, Alexander Staubo wrote: There needs to be a point of synchronization when a DDL transaction appears that blocks further write transactions from running. As far as I can tell, the slaves themselves can continue to receive pending events, but perhaps

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Ron Johnson
You were politely asked not to top-post. On 06/02/07 11:46, Harpreet Dhaliwal wrote: So, while writing any technical document, would it be wrong to mention stored procedures in postgresql? what is the general convention? Did I miss something? What does stored procedures have to do with

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Russ Brown
Harpreet Dhaliwal wrote: On 6/2/07, *Jasbinder Singh Bali* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: On 6/2/07, *Michael Glaesemann* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: On Jun 2, 2007, at 11:08 , Harpreet Dhaliwal wrote: Whats

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Ron Johnson
On 06/02/07 13:35, Jasbinder Singh Bali wrote: On 6/2/07, Michael Glaesemann [EMAIL PROTECTED] wrote: On Jun 2, 2007, at 11:08 , Harpreet Dhaliwal wrote: Whats so novel about postgresql here? This would happen in any RDBMS. right? You induced divide by zero exception that crashed the

Re: [GENERAL] Corruption of files in PostgreSQL

2007-06-02 Thread Paolo Bizzarri
On 6/2/07, Tom Lane [EMAIL PROTECTED] wrote: Paolo Bizzarri [EMAIL PROTECTED] writes: On 6/2/07, Tom Lane [EMAIL PROTECTED] wrote: Please provide a reproducible test case ... as explained above, the problem seems quite random. So I need to understand what we have to check. In this context

Re: [GENERAL] Transactional DDL

2007-06-02 Thread PFC
This is what happens in every RDBMS. Whats so special about postgres then? mysql BEGIN; Query OK, 0 rows affected (0.00 sec) mysql CREATE TABLE ble ( id INTEGER ) ENGINE=InnoDB; Query OK, 0 rows affected (0.09 sec) mysql INSERT INTO ble VALUES (1),(2),(3); Query OK, 3 rows affected

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Tom Lane
Russ Brown [EMAIL PROTECTED] writes: Harpreet Dhaliwal wrote: Whats so different in postgresql then? Try doing the same test in MySQL (using InnoDB so you get a supposedly ACID compliant table type). Or even in Oracle. Examples (using mysql 5.0.40, reasonably current): mysql create table

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Leif B. Kristensen
On Saturday 2. June 2007 20:39, Ron Johnson wrote: You were politely asked not to top-post. On 06/02/07 11:46, Harpreet Dhaliwal wrote: So, while writing any technical document, would it be wrong to mention stored procedures in postgresql? what is the general convention? Did I miss something?

Re: [GENERAL] Corruption of files in PostgreSQL

2007-06-02 Thread Michael Nolan
On 6/2/07, Paolo Bizzarri [EMAIL PROTECTED] wrote: What we are trying to understand is, first and foremost, if there are known cases under which PostgreSQL can truncate a file. I think it's somewhat more likely that whatever is sending the file to PG is the cause, either in how it handles

Re: [GENERAL] why postgresql over other RDBMS

2007-06-02 Thread Jeremy Harris
On 06/01/07 11:22, Bruce Momjian wrote: PFC wrote: On Thu, 31 May 2007 22:20:09 +0200, Vivek Khera [EMAIL PROTECTED] wrote: On May 25, 2007, at 5:28 PM, Tom Lane wrote: That's true at the level of DDL operations, but AFAIK we could parallelize table-loading and index-creation steps

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Harpreet Dhaliwal
my bad.. i replied to that in a wrong thread. sorry On 6/2/07, Leif B. Kristensen [EMAIL PROTECTED] wrote: On Saturday 2. June 2007 20:39, Ron Johnson wrote: You were politely asked not to top-post. On 06/02/07 11:46, Harpreet Dhaliwal wrote: So, while writing any technical document, would

[GENERAL] Need a wee bit more info on PostgreSQL's SSL security options

2007-06-02 Thread Andreas
Hi, I've got it so far: Server-OS: Debian 3.1 sarge PostgreSQL: Debian's binary PG 8.1.8 (still the most recent version available) Following a tutorial (actually for OpenVPN as I didn't find any for PG that goes beyond what is found in the main docu) I created a CA, server and client

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Jaime Casanova
On 6/2/07, PFC [EMAIL PROTECTED] wrote: This is what happens in every RDBMS. Whats so special about postgres then? mysql BEGIN; Query OK, 0 rows affected (0.00 sec) mysql CREATE TABLE ble ( id INTEGER ) ENGINE=InnoDB; Query OK, 0 rows affected (0.09 sec) mysql INSERT INTO ble

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Jaime Casanova
On 6/2/07, *Jasbinder Singh Bali* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: On 6/2/07, *Michael Glaesemann* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: On Jun 2, 2007, at 11:08 , Harpreet Dhaliwal wrote: Whats so novel about postgresql here?

Re: [GENERAL] High-availability

2007-06-02 Thread Alexander Staubo
On 6/3/07, Madison Kelly [EMAIL PROTECTED] wrote: Slony is indeed intended for near-real-time replication; it's asynchronous, so slaves always lag behind the master. The amount of discrepancy depends on a bunch of factors -- individual node performance, network performance, and system load.

Re: [GENERAL] High-availability

2007-06-02 Thread Alexander Staubo
On 6/3/07, Alexander Staubo [EMAIL PROTECTED] wrote: As a side-note, I sat up pgpool-II today, and was pleasantly surprised about how easy it all was; within two minutes I had two databases in perfect sync on my laptop. It has limitations (such as in its handling of sequences), but compared to

Re: [GENERAL] Transactional DDL

2007-06-02 Thread Tom Lane
Jaime Casanova [EMAIL PROTECTED] writes: Tom's example seems to show that mysql inserts a commit immidiatelly after a DDL but this one example shows the thing is worse than that. Actually, I think their behavior is just DDL issues a COMMIT, so that after that you are out of the transaction and

Re: [GENERAL] High-availability

2007-06-02 Thread Madison Kelly
Alexander Staubo wrote: On 6/1/07, Madison Kelly [EMAIL PROTECTED] wrote: After realizing that 'clustering' in the PgSQL docs means multiple DBs behind one server, and NOT multple machines, I am back at square one, feeling somewhat the fool. :P I remember being similarly disappointed in

Re: [GENERAL] multimaster

2007-06-02 Thread Guy Rouillier
PFC wrote: Have you looked at raidb? http://c-jdbc.objectweb.org. Narrow niche, but if it happens to be the one you are in, then it's an option. I took a quick look at the user's page, and both of them were using PostgreSQL. I just love those Java guys. The world starts and ends

Re: [GENERAL] PITR Base Backup on an idle 8.1 server

2007-06-02 Thread Greg Smith
On Fri, 1 Jun 2007, Marco Colombo wrote: If you need *both* a full backup *and* PITR, just add a real cp to the archive_command above. The important part is to return failure during the backup process, I think. You seem to have worked out a way for your application to do a base backup in a

[GENERAL] Turning on logging

2007-06-02 Thread Owen Hartnett
I know this is in the docs somewhere, and it's probably staring me in the face, but I haven't been able to find it: I'm running 8.2.4 through npgsql - how do I log: 1) connections to the database 2) updates, deletes, adds Is this set in the ./configuration? Or in the startup command