[Pgpool-general] what is "backend_data_directory"?

2009-10-25 Thread Tomasz Chmielewski
like: backend_hostname0 = 'host1' backend_port0 = 5432 backend_weight0 = 1 backend_data_directory0 = '/var/lib/postgresql/8.3/main' backend_hostname1 = 'host2' backend_port1 = 5433 backend_weight1 = 1 backend_data_directory1 = '/var/lib/postgresql/8.3/main' -- Toma

[Pgpool-general] online recovery by PITR - broken examples?

2009-10-26 Thread Tomasz Chmielewski
OVERY_DATA For example, it includes $DATA variable, which is not used anywhere. Is it the same as "/data" referenced later? Probably yes. Anyway, I can't get it to work. Does anyone have online recover with pgpool-ii explained in more details? -- Tomasz Chmielewski http://w

Re: [Pgpool-general] online recovery by PITR - broken examples?

2009-10-26 Thread Tomasz Chmielewski
Jaume Sabater wrote: On Mon, Oct 26, 2009 at 5:59 PM, Tomasz Chmielewski wrote: Is it the same as "/data" referenced later? Probably yes. It is. Anyway, I can't get it to work. It proved very useful to me in order to create mine, but I did not expect it to work out

Re: [Pgpool-general] online recovery by PITR - broken examples?

2009-10-26 Thread Tomasz Chmielewski
Jaume Sabater wrote: On Mon, Oct 26, 2009 at 10:32 PM, Tomasz Chmielewski wrote: Yes, this is what I don't understand - these scripts seem to want to copy the whole postgresql data directory. That can't be right, can it? If you use rsync, only the differences. Assuming your data

Re: [Pgpool-general] online recovery by PITR - broken examples?

2009-10-27 Thread Tomasz Chmielewski
Jaume Sabater wrote: On Mon, Oct 26, 2009 at 5:59 PM, Tomasz Chmielewski wrote: Is it the same as "/data" referenced later? Probably yes. It is. Anyway, I can't get it to work. It proved very useful to me in order to create mine, but I did not expect it to work out

Re: [Pgpool-general] online recovery by PITR - broken examples?

2009-10-28 Thread Tomasz Chmielewski
Tomasz Chmielewski wrote: Anyway, I can't get it to work. It proved very useful to me in order to create mine, but I did not expect it to work out of the box. Nor should you. It's meant to be an example for you to learn, just that. It's a script that works on Tatsuo's l

[Pgpool-general] saving state across pgpool restarts?

2009-10-29 Thread Tomasz Chmielewski
If pgpool-ii is restarted, it will consider that all backends are in "good" state - even if one of the backends was not up to date (and data was not being replicated there). What is the best way to preserve backend state across pgpool-ii restarts? -- Tomasz Chmielewski http:

Re: [Pgpool-general] saving state across pgpool restarts?

2009-10-30 Thread Tomasz Chmielewski
hing which could cause it would be OOM-killer). -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

Re: [Pgpool-general] saving state across pgpool restarts?

2009-11-08 Thread Tomasz Chmielewski
the nodes is out of sync. And later, finding the node which was out of sync would be real pain. -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

Re: [Pgpool-general] execute a command when one node is back?

2009-11-15 Thread Tomasz Chmielewski
Tomasz Chmielewski wrote: When one node is gone, pgpool-ii can execute a "failover_command". After a node is recovered, pgpool-ii can execute a "failback_command". What I lack (or can't find) is something executed between those two commands: a command executed

[Pgpool-general] execute a command when one node is back?

2009-11-15 Thread Tomasz Chmielewski
s reachable again). Is something like this possible with pgpool-ii? -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

[Pgpool-general] understanding backend_weight

2009-11-16 Thread Tomasz Chmielewski
_hostname0 = 'local' backend_weight0 = 0 backend_hostname1 = 'remote' backend_weight1 = 1 Or maybe: backend_hostname0 = 'local' backend_weight0 = 1 backend_hostname1 = 'remote' backend_weight1 = 0 Or is the mean

Re: [Pgpool-general] understanding backend_weight

2009-11-16 Thread Tomasz Chmielewski
gres2' backend_weight1 = 1 backend_hostname1 = 'postgres3' backend_weight1 = 2 postgres1 should not get any reads. postgres2 should get 33,3(3)% reads. postgres2 should get 66,6(6)% reads. Is my reasoning correct? -- Tomasz Chmielewski http://wpkg.org ___

Re: [Pgpool-general] understanding backend_weight

2009-11-16 Thread Tomasz Chmielewski
Tomasz Chmielewski wrote: Thanks. Out of curiosity, how would be such values handled? I made some typos wrt numbers -once again, corrected below: backend_hostname0 = 'postgres1' backend_weight0 = 0 backend_hostname1 = 'postgres2' backend_weight1 = 1 backend_ho

Re: [Pgpool-general] understanding backend_weight

2009-11-16 Thread Tomasz Chmielewski
s. postgres2 should get 33,3(3)% reads. postgres2 should get 66,6(6)% reads. Is my reasoning correct? Yes. See select_load_balancing_node() in child.c for more details. OK, thanks for your help. -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-gener

Re: [Pgpool-general] pgpool-II 2.3 released

2009-12-07 Thread Tomasz Chmielewski
guess status of down node is what the NEWS file talks about? - pgpool_status file is created under logdir. So you need to give write permission to the directory so that pgpool-II can read/write pgpool_status file. -- Tomasz Chmielewski http://wpkg.org

[Pgpool-general] "torture test" for pgpool-ii?

2009-12-12 Thread Tomasz Chmielewski
Is there any "torture test" for pgpool-ii? Say, a test which would connect over pgpool-ii and do the following: - create a database, - do lots of inserts etc. changes, over a certain period of time (30 mins or so), - ideally, compare databases which pgpool-ii uses. -- Tomasz C

Re: [Pgpool-general] "torture test" for pgpool-ii?

2009-12-12 Thread Tomasz Chmielewski
On 13.12.2009 02:03, Tomasz Chmielewski wrote: > Is there any "torture test" for pgpool-ii? > > Say, a test which would connect over pgpool-ii and do the following: > > - create a database, > > - do lots of inserts etc. changes, over a certain period of time (30

Re: [Pgpool-general] "torture test" for pgpool-ii?

2009-12-12 Thread Tomasz Chmielewski
On 13.12.2009 02:57, Tomasz Chmielewski wrote: What's wrong here? I use pgpool-2.3. If I do this right before rsyncing on the "to-be-recovered" server, then I don't get the errors anymore: /usr/bin/pg_ctlcluster 8.3 main stop --force I followed this guide, which

Re: [Pgpool-general] Database nodes mismatch after failback

2009-12-14 Thread Tomasz Chmielewski
ained, nor outlined in example scripts. See this thread from yesterday: "torture test" for pgpool-ii? -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

[Pgpool-general] "failed to read kind from frontend. frontend abnormally exited"?

2009-12-18 Thread Tomasz Chmielewski
ived: host=[local] Dec 18 12:06:49 pg1 pgpool: 2009-12-18 12:06:49 LOG: pid 4352: connection received: host=[local] It doesn't look too healthy to me - what exactly happened there? This is a setup of two postgres servers, connections go through pgpool-ii 2.

Re: [Pgpool-general] "failed to read kind from frontend. frontend abnormally exited"?

2009-12-20 Thread Tomasz Chmielewski
husagestats.id" 2009-12-18 01:39:42 UTC NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "core_bandwidthusagestats_pkey" for table "core_bandwidthusagestats" until: 2009-12-18 01:39:42 UTC NOTICE: CREATE TABLE / UNIQUE will create implicit index "auth_user_user_permissions_user_id_key" for table "auth_user_user_permissions" 2009-12-18 01:39:49 UTC ERROR: null value in column "object_id" violates not-null constraint 2009-12-18 01:39:49 UTC STATEMENT: INSERT INTO "core_event" ("id","ip","when","bytes","protocol_id","country") VALUES (800,E'serv1',E'2009-12-09 12:00:13',3 2009-12-18 01:39:49 UTC ERROR: current transaction is aborted, commands ignored until end of transaction block 2009-12-18 01:39:49 UTC STATEMENT: INSERT INTO "django_content_type" ("id","name","app_label","model") VALUES (1,E'permission',E'auth',E'permission'); 2009-12-18 01:39:49 UTC ERROR: current transaction is aborted, commands ignored until end of transaction block -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

[Pgpool-general] pcp_recovery_node and errors in postgres log

2009-12-22 Thread Tomasz Chmielewski
2009-12-23 06:03:20 SGT LOG: autovacuum launcher started 2009-12-23 06:03:20 SGT LOG: database system is ready to accept connections Because of these errors, recovery sometimes fails. How does postgres on the node which is recovered determines the %f files it needs

Re: [Pgpool-general] pcp_recovery_node and errors in postgres log

2009-12-22 Thread Tomasz Chmielewski
On 22.12.2009 23:05, Tomasz Chmielewski wrote: > I followed the http://linuxsilo.net/articles/postgresql-pgpool.html to set up > pgpool-ii replication. > > > When I detach and recover a node with these commands: > > # pcp_detach_node -d 240 127.0.0.1 9898 user pass 1 >

[Pgpool-general] thousands of queries from pgpool to one of the backends (queries I don't do)

2010-02-28 Thread Tomasz Chmielewski
DEFAULT [393-1] 2010-03-01 03:06:56 SGT LOG: duration: 0.028 ms statement: COMMIT And they are repeated every second or so. Does anyone have an idea why pgpool queries one of the backends so often? The queries I made by pgpool, as they stop when I stop pgpool. I use pgpool-2.3.2.2, but I had thi

Re: [Pgpool-general] thousands of queries from pgpool to one of the backends (queries I don't do)

2010-02-28 Thread Tomasz Chmielewski
query. It may well be that the queries are sent by my application running in the network - but: - backend0 has weight 1; backend1 has weight 0 - doesn't in mean these queries should be sent to backend0? Right now, backend0 gets only few queries; backend1 gets thousands. -- Tomasz Chmiel

Re: [Pgpool-general] thousands of queries from pgpool to one of the backends (queries I don't do)

2010-02-28 Thread Tomasz Chmielewski
Tomasz Chmielewski wrote: > - backend0 has weight 1; backend1 has weight 0 - doesn't in mean these > queries should be sent to backend0? Right now, backend0 gets only few > queries; backend1 gets thousands. I guess I didn't reload postgres settings on one of the servers, so

Re: [Pgpool-general] info

2010-03-02 Thread Tomasz Chmielewski
turn the slave into Master and have it replicate everything to a new DB server when it is brought online? heartbeat? -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman

Re: [Pgpool-general] Database verification

2010-03-04 Thread Tomasz Chmielewski
elopped my solution to check if backends are synchronized or not. Do you think that could interest people? Or do you know an existing tool? Surely that would be interesting. -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpo

Re: [Pgpool-general] Database verification

2010-03-11 Thread Tomasz Chmielewski
op it because I need it. Before publishing it, I have to resolve some formal legal issues with one of my clients. I'll tell you when it is published. Just pinging here - was it forgotten, or are there any legal issues here etc.? -- Tomasz Chmiele

[Pgpool-general] pgpool "freeze" when pcp_recovery_node fails

2010-03-11 Thread Tomasz Chmielewski
y to kill pgpool in this state is to use kill -9. Is it a known issue? I use pgpool-II 2.3.2.2. -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

[Pgpool-general] can't attach two nodes simultaneously

2010-04-13 Thread Tomasz Chmielewski
at it fails when we start pcp_attch_node one after another? 2. Is there a way to attach multiple nodes in an "atomic" way? -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

Re: [Pgpool-general] can't attach two nodes simultaneously

2010-04-14 Thread Tomasz Chmielewski
which go to node 0 only 7. yo do "pcp_attach_node ... 0" to attach node 1 8. writes go to both nodes now, but node 1 does not contain some data now There is a workaround: stop pgpool, remove its status file, start it again, but that's not real

Re: [Pgpool-general] Online recovery timeouts

2010-04-14 Thread Tomasz Chmielewski
grams (such as pgadmin) which maintain a persistent connection and prevent pgpool from performing recovery. Just out of curiosity, why don't you just stop pgadmin if you go into online recovery? There can be clients connected you have no control over. -- Tomasz Chmielewski http:

Re: [Pgpool-general] PgPool-II + Iptables

2010-06-17 Thread Tomasz Chmielewski
t;netstat -tpna" to see the ports processes are listening on. Also, "man ps" and "man netstat" could be interesting to you. -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http

[Pgpool-general] 3.0.3: pool_init_pool_passwd: couldn't open /etc/pool_passwd. reason: Permission denied

2011-03-31 Thread Tomasz Chmielewski
LOG: pid 22202: pgpool-II successfully started. version 3.0.3 (umiyameboshi) >From what I found, there was indeed such an issue before 3.0.1. Did I miss >anything? -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing lis

Re: [Pgpool-general] 3.0.3: pool_init_pool_passwd: couldn't open /etc/pool_passwd. reason: Permission denied

2011-03-31 Thread Tomasz Chmielewski
On 31.03.2011 17:31, Tomasz Chmielewski wrote: > I'm just trying to upgrade from 3.0.1 to 3.0.3. > > Unfortunately, it complains like below: > > Mar 31 23:16:09 db20 pgpool: 2011-03-31 23:16:09 ERROR: pid 22202: > pool_init_pool_passwd: couldn't open /etc/poo

[Pgpool-general] what does "ProcessFrontendResponse: failed to read kind from frontend. frontend abnormally exited" mean?

2011-05-10 Thread Tomasz Chmielewski
from frontend. frontend abnormally exited I get them in my syslog around 40 times per hour. Is that anything good? Anything bad? Neutral? Other than that, everything else seem to be working correctly. -- Tomasz Chmielewski http://wpkg.org

[Pgpool-general] one of backends kicked after "VACUUM ANALYZE"

2011-05-11 Thread Tomasz Chmielewski
1493 live rows and 0 dead rows; 1493 May 12 05:23:04 db20 postgres[27590]: [73-2] rows in sample, 1362565 estimated total rows May 12 05:23:04 db20 postgres[27590]: [74-1] 2011-05-12 05:23:04 SGT LOG: duration: 1126957.051 ms statement: VACUUM VERBOSE ANALYZE core_extevent; -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

Re: [Pgpool-general] one of backends kicked after "VACUUM ANALYZE"

2011-05-11 Thread Tomasz Chmielewski
On 12.05.2011 00:21, Tomasz Chmielewski wrote: > I removed a large number of records from a table (~38 mln out of ~40 mln), > after which I've started "VACUUM VERBOSE ANALYZE my_table". > > Near the very end, pgpool kicked one of the backends - is it expected? Pl

Re: [Pgpool-general] one of backends kicked after "VACUUM ANALYZE"

2011-05-14 Thread Tomasz Chmielewski
you. Are there any other commands which should not be executed through pgpool? For example, is REINDEX TABLE safe to execute through pgpool? Probably I should add this to FAQ. -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing l

[Pgpool-general] "idle in transaction" on one backend only?

2011-05-19 Thread Tomasz Chmielewski
t all, I should expect them on both backends, or? -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

Re: [Pgpool-general] one of backends kicked after "VACUUM ANALYZE"

2011-05-20 Thread Tomasz Chmielewski
ncy among db nodes server closed the connection unexpectedly This probably means the server terminated abnormally before or while processing the request. connection to server was lost So after all, looks REINDEX is also not so safe? -- Tomasz Chmielewski http://wpkg.org

Re: [Pgpool-general] one of backends kicked after "VACUUM ANALYZE"

2011-05-20 Thread Tomasz Chmielewski
h pgpool? As I understand, it does not change database data visible to the clients, so should be safe. -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

Re: [Pgpool-general] one of backends kicked after "VACUUM ANALYZE"

2011-05-20 Thread Tomasz Chmielewski
rect me if I'm wrong. -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

Re: [Pgpool-general] one of backends kicked after "VACUUM ANALYZE"

2011-05-20 Thread Tomasz Chmielewski
ld be done during the least load, but in theory, a deadlock can still happen. -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

Re: [Pgpool-general] one of backends kicked after "VACUUM ANALYZE"

2011-05-20 Thread Tomasz Chmielewski
during the least load, but in theory, a deadlock can still happen. Why don't you use an explicit transatcion plus lock to avoid deadlock for the first place? BEGIN; LOCK TABLE REINDEX TABLE END; That could be helpful, thank you. -- Tomasz Chmielewski http://wpk

Re: [Pgpool-general] Online Recovery Question

2011-06-15 Thread Tomasz Chmielewski
, you will need to remove this file. -- Tomasz Chmielewski http://wpkg.org ___ Pgpool-general mailing list Pgpool-general@pgfoundry.org http://pgfoundry.org/mailman/listinfo/pgpool-general

Re: [Pgpool-general] Online Recovery Question

2011-06-16 Thread Tomasz Chmielewski
ation which tries to connect/write all the time. If pgpool starts and the application connects/writes before you start pcp_attach_node, you will have problems (even if time before starting pgpool and pcp_attach_node may seem short, the application may still be able to write to pgpool). -- T