Re: [GENERAL] Implementing "thick"/"fat" databases

2011-07-24 Thread Karsten Hilbert
Hello Chris, > > In LedgerSMB, we take this a step further by making the procedures > > into discoverable interfaces, how do you do that ? Karsten -- NEU: FreePhone - 0ct/min Handyspartarif mit Geld-zurück-Garantie! Jetzt informieren: http://www.gmx.net/de/go/freephone -- Sent

Re: [GENERAL] streaming replication does not work across datacenter with 20ms latency?

2011-07-24 Thread Yan Chunlu
is there anything special you have configured on master and slave? could I see the related configuration on your master and slave? such as wal_keep_segments,checkpoint_segments or any other might be related? thanks a lot! On Sun, Jul 24, 2011 at 11:23 AM, Scott Ribe wrote: > On Jul 23, 2011, at

Re: Re : [GENERAL] Update columns in same table from update trigger?

2011-07-24 Thread Alban Hertroys
On 23 Jul 2011, at 16:49, Pablo Romero Abiti wrote: > Hi Alban, thank's for your reply. I already changed it as you wrote, but I'm > still having the problem that the trigger won't execute unless the value > specified for idcolor in table warehouse does exist. Shouldn't the trigger > execute BE

Re: Re : [GENERAL] Update columns in same table from update trigger?

2011-07-24 Thread Alban Hertroys
On 24 Jul 2011, at 11:00, Alban Hertroys wrote: > You can't fire a trigger on non-existant data. I just realised the above statement is a little inexact: you can't fire row-level triggers on non-existant data. You can still fire statement-level triggers on them, but with those you won't have

Re: [GENERAL] Update columns in same table from update trigger?

2011-07-24 Thread Sim Zacks
On 07/22/2011 11:02 PM, Pablo Romero Abiti wrote: Here's what I want to do: I have a master table that has 2 columns: idcol1 and idcol2, where idcol2 is equivalent to idcol1 Table: color_eq idcol1 idcol2 1 1 2 2 2 3 Table: warehouse idcolqty 110 220 if I exe

Re: [GENERAL] Implementing "thick"/"fat" databases

2011-07-24 Thread Gavin Flower
On 24/07/11 17:51, Chris Travers wrote: I was thinking similar thoughts, but you not only beat me to it, you made some good points I had not thought of! The only thing I can think of adding: is that it would be good to lock down the database so that only the middleware can access it, everything

Re: [GENERAL] streaming replication does not work across datacenter with 20ms latency?

2011-07-24 Thread Tomas Vondra
On 24 Červenec 2011, 6:09, Yan Chunlu wrote: > thanks for all the help! > > @Adrian: yes, only one instance on each machine > > not the slave finally started and could be connect, replication didn't > begin, just following errors: > https://gist.github.com/1102225 These errors just mean the maste

Re: [GENERAL] streaming replication does not work across datacenter with 20ms latency?

2011-07-24 Thread Yan Chunlu
checkpoint_segments = 64 wal_keep_segments = 128 On Sun, Jul 24, 2011 at 8:25 PM, Tomas Vondra wrote: > On 24 Červenec 2011, 6:09, Yan Chunlu wrote: >> thanks for all the help! >> >> @Adrian:  yes, only one instance on each machine >> >> not the slave finally started and could be connect, replica

[GENERAL] pgpool HA not working

2011-07-24 Thread Sanjay Rao
Hi I am working on pgpool /postgresql/linux first time. All these three are new to me. I am running pgpool-HA using pacemaker-corosync. I am having following error in my setup. Does any body have any idea about the warning highlighted in logs ? Any type of help would be appreciated a lot...

Re: [GENERAL] Implementing "thick"/"fat" databases

2011-07-24 Thread Chris Travers
On Sun, Jul 24, 2011 at 12:34 AM, Karsten Hilbert wrote: > Hello Chris, > >> > In LedgerSMB, we take this a step further by making the procedures >> > into discoverable interfaces, > > how do you do that ? The way we do things in 1.3 beta is relatively free-form and not idea. In future versions

Re: [GENERAL] Implementing "thick"/"fat" databases

2011-07-24 Thread Chris Travers
On Sat, Jul 23, 2011 at 11:44 PM, Sim Zacks wrote: > I gave a talk on using postgresql as an application server  at PG East in > March. > > Basically, we try to implement all business logic using functions, using > plpythonu when necessary. > > For example, we have functions that send email, ftp f

Re: [GENERAL] streaming replication does not work across datacenter with 20ms latency?

2011-07-24 Thread Yan Chunlu
I did the SR procedure again, still no luck: is that normal that after start slave postgresql, the first line of log is: database system was interrupted; last known up at 2011-07-24 10:53:38 CDT?? 4760 2011-07-24 10:55:58 CDT 2011-07-24 10:55:58 CDT @ LOG: database system was interrupted; last

Re: [GENERAL] weird table sizes

2011-07-24 Thread Adrian Klaver
On Saturday, July 23, 2011 3:34:07 pm MirrorX wrote: > i mentioned the sequences number only b/c it seemed stange and i didnt know > if it could be related to the "weird" sizes. > > now i found something more weird...the autovacuum is ON but on > pg_stat_user_tables on this specific table tha last

Re: [GENERAL] weird table sizes

2011-07-24 Thread Chris Travers
On Sun, Jul 24, 2011 at 11:45 AM, Adrian Klaver wrote: > On Saturday, July 23, 2011 3:34:07 pm MirrorX wrote: >> i mentioned the sequences number only b/c it seemed stange and i didnt know >> if it could be related to the "weird" sizes. >> >> now i found something more weird...the autovacuum is ON

Re: [GENERAL] streaming replication does not work across datacenter with 20ms latency?

2011-07-24 Thread Tomas Vondra
Dne 24.7.2011 14:46, Yan Chunlu napsal(a): > checkpoint_segments = 64 > wal_keep_segments = 128 This information alone is not sufficient - we don't know how much write activity is on the primary system, so we can't say if those number are sufficient or not. You have to tune them according to write

[GENERAL] Disallow access from psql, or allow access only from specific client app

2011-07-24 Thread Mario Puntin
Hi everybody: I searched the web trying to find an answer to this, but found none. I have a postgresql server and a database, and I granted access to some users. However I want them to access the data only through some specific client application. I do not want them to have access through psql or s

Re: [GENERAL] Disallow access from psql, or allow access only from specific client app

2011-07-24 Thread Kurt Buff
On Sun, Jul 24, 2011 at 14:36, Mario Puntin wrote: > > Hi everybody: > I searched the web trying to find an answer to this, but found none. I have > a postgresql server and a database, and I granted access to some users. > However I want them to access the data only through some specific client >

Re: [GENERAL] Disallow access from psql, or allow access only from specific client app

2011-07-24 Thread Lonni J Friedman
On Sun, Jul 24, 2011 at 2:46 PM, Kurt Buff wrote: > On Sun, Jul 24, 2011 at 14:36, Mario Puntin wrote: >> >> Hi everybody: >> I searched the web trying to find an answer to this, but found none. I have >> a postgresql server and a database, and I granted access to some users. >> However I want th

Re: [GENERAL] Disallow access from psql, or allow access only from specific client app

2011-07-24 Thread Chris Travers
On Sun, Jul 24, 2011 at 2:36 PM, Mario Puntin wrote: > > Hi everybody: > I searched the web trying to find an answer to this, but found none. I have > a postgresql server and a database, and I granted access to some users. > However I want them to access the data only through some specific client

Re: [GENERAL] Disallow access from psql, or allow access only from specific client app

2011-07-24 Thread Chris Curvey
On Sun, Jul 24, 2011 at 5:36 PM, Mario Puntin wrote: > > Hi everybody: > I searched the web trying to find an answer to this, but found none. I have > a postgresql server and a database, and I granted access to some users. > However I want them to access the data only through some specific client

Re: [GENERAL] Disallow access from psql, or allow access only from specific client app

2011-07-24 Thread Kurt Buff
On Sun, Jul 24, 2011 at 14:48, Lonni J Friedman wrote: > On Sun, Jul 24, 2011 at 2:46 PM, Kurt Buff wrote: >> On Sun, Jul 24, 2011 at 14:36, Mario Puntin wrote: >>> >>> Hi everybody: >>> I searched the web trying to find an answer to this, but found none. I have >>> a postgresql server and a dat

Re: [GENERAL] Disallow access from psql, or allow access only from specific client app

2011-07-24 Thread salah jubeh
Hello, I do not know if your clients are superusers on their machines, one thing you can do is to remove psql client from these machines. In general, for example in a company, the users do not have administration privileges. Regards From: Kurt Buff To: Lon

Re: [GENERAL] Disallow access from psql, or allow access only from specific client app

2011-07-24 Thread Craig Ringer
On 25/07/2011 5:36 AM, Mario Puntin wrote: Hi everybody: I searched the web trying to find an answer to this, but found none. I have a postgresql server and a database, and I granted access to some users. However I want them to access the data only through some specific client application. I

Re: [GENERAL] Disallow access from psql, or allow access only from specific client app

2011-07-24 Thread John R Pierce
On 07/24/11 2:36 PM, Mario Puntin wrote: Hi everybody: I searched the web trying to find an answer to this, but found none. I have a postgresql server and a database, and I granted access to some users. However I want them to access the data only through some specific client application. I do

Re: [GENERAL] streaming replication does not work across datacenter with 20ms latency?

2011-07-24 Thread Yan Chunlu
checkpoint_segments = 64 wal_keep_segments = 128 this setting seems is for 5GB capacity, I think there is noway I would ever write 5GB data during the rsync progress. I think the problem is still "invalid record length" and "invalid magic number", it start showing right after I complete sync dat

Re : Re : [GENERAL] Update columns in same table from update trigger?

2011-07-24 Thread Pablo Romero Abiti
Thank you for our help anyway! De : Alban Hertroys À : Alban Hertroys Cc : Pablo Romero Abiti ; "pgsql-general@postgresql.org" Envoyé le : Dimanche 24 Juillet 2011 4h06 Objet : Re: Re : [GENERAL] Update columns in same table from update trigger? On 24 Jul 2

[GENERAL] Would it be possible

2011-07-24 Thread Adarsh Sharma
Dear all, I am using Postgres-8.4.2 on Windows system. I have 2 databases in my postgres database ( globedatabase (21GB), urldatabase). I restore globedatabase from a .sql file on yesterday morning.I insert some new data in that database. In the evening, by mistake I issued a *drop database

Re: [GENERAL] Would it be possible

2011-07-24 Thread Christian Ullrich
* Adarsh Sharma wrote: In the evening, by mistake I issued a *drop database globedatabase* command. Is it possible to get the data back till the state before drop database command. My pglog files is in the E:/data directory & Binary log is also enabled. You do not mention that you have a f

Re: [GENERAL] Implementing "thick"/"fat" databases

2011-07-24 Thread Sim Zacks
On 07/24/2011 06:58 PM, Chris Travers wrote: On Sat, Jul 23, 2011 at 11:44 PM, Sim Zacks wrote: I gave a talk on using postgresql as an application server at PG East in March. Basically, we try to implement all business logic using functions, using plpythonu when necessary. For example, we