-
Notifications
You must be signed in to change notification settings - Fork 0
/
NEWS
2248 lines (1563 loc) · 88.9 KB
/
NEWS
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
Release Notes
===============================================================================
3.2 Series (2012/08/03 - )
===============================================================================
3.2.0 (namameboshi) 2012/08/03
* Version 3.2.0
This is the first version of pgpool-II 3.2 series.
That is, a "major version up" from 3.1 series.
__________________________________________________________________
* Incompatible changes
- The new query cache "On memory query cache" took the place of the old
one.
- Now the parameter "enable_query_cache" is deleted.
__________________________________________________________________
* New features
** Memory based query cache
Original author is Masanori Yamazaki, improved by Development Group.
(Tatsuo Ishii, Nozomi Anzai, Yugo Nagata)
Overview:
On memory query cache is faster because cache storage is on memory.
Moreover you don't need to restart pgpool-II when the cache is outdated
because the underlying table gets updated.
On memory cache saves pair of SELECT statements (with its Bind parameters
if the SELECT is an extended query). If the same SELECTs comes in, it
returns the value from cache. Since no SQL parsing nor access to
PostgreSQL are involed, it's extremely fast.
On the other hand, it might be slower than the normal path because it
adds some overhead to store cache. Moreover when a table is updated,
pgpool automatically deletes all the caches related to the table. So the
prformace will be degraded by a system with a lot of updates. If the
cache_hit_ratio is lower than 70%, you might want to disable onl memory
cache.
Choosing cache storage:
You can choose a cache storage: shared memory or memcached (you can't use
the both).
Query cache with shared memory is fast and easy because you don't have
to install and config memcached, but restricted the max size of cache by
the one of shared memory. Query cache with memcached needs a overhead to
access network, but you can set the size as you like.
Restrictions:
- On memory query cache deletes the all cache of an updated table
automatically with monitoring if the executed query is UPDATE, INSERT,
ALTER TABLE and so on. But pgpool-II isn't able to recognize implicit
updates due to trigers, foreign keys and DROP TABLE CASCADE.
You can avoid this problem with memqcache_expire by which pgpool deletes
old cache in a fixed time automatically, or with black_memqcache_table_list
by which pgpool's memory cache flow ignores the tables.
- If you want to use multiple instances of pgpool-II with online memory
cache which uses shared memory, it could happen that one pgpool deletes
cache, and the other one doesn't do it thus finds old cached result
when a table gets updated. Memcached is the better cache storage in this
case.
New parameters:
- Add parameters for on memoey query cache as follows:
memory_cache_enabled, memqcache_method, memqcache_expire,
memqcache_maxcache, memqcache_oiddir. (Tatsuo Ishii)
- Add parameters about shared memory for on memory query cache as
follows:
memqcache_total_size, memqcache_max_num_cache,
memqcache_cache_block_size. (Tatsuo Ishii)
- Add parameters about memcached for on memory query cache as follows:
memqcache_memcached_host, memqcache_memcached_port. (Tatsuo Ishii)
- Add parameters about relation cache for on memory query cache as
follows:
relcache_expire, relcache_size. (Tatsuo Ishii)
- Add a parameter "check_temp_table" to check if the SELECTed table is
temp table. (Tatsuo Ishii)
- Add the parameters of white_memqcache_table_list,
black_memqcache_table_list that check if the SELECTed tables, temp
tables and views are to be cached or not. (Nozomi Anzai)
- Add a parameter "memqcache_auto_cache_invalidation" of the flag if
query cache is triggered by corresponding DDL/DML/DCL (and
memqcache_expire). (Yugo Nagata)
New commands:
- Add "SHOW pool cache" which shows hit ratio of query cache and the
status of cache storage.
- Add "--with-memcached" option to configure. (Nozomi Anzai)
- Add "-C, --clear-oidmaps" option to "pgpool" command. (Nozomi Anzai)
If pgpool with memcached starts / restarts with -C option, discard oid
maps, if not, it can reuse old oid maps and query caches.
** Watchdog
The author is Atsushi Mitani, tested by Yugo Nagata.
Overview:
"Watchdog" is a sub process of pgpool-II aiming for adding high
availability feature to it. Features added by watchdog include:
- Life checking of pgpool service
Watchdog monitors responses of pgpool service rather than process. It
sends queries to PostgreSQL via pgpool which is being monitored by
watchdog and watchdog checks the response. Also watchdog monitors
connections to up stream servers (application servers etc.) from the
pgpool. The connection between the up stream servers and the pgpool is
monitored as service of pgpool.
- Mutual monitoring of watchdog processes
Watchdog processes exchange information on the monitored servers to
keep the information up to date, and to allow watchdog processes to
mutually monitor each other.
- Changing active/standby state in case of certain faults detected
When a fault is detected in the pgpool service, watchdog notifies the
other watchdogs of it. Watchdogs decide the new active pgpool if
previous active pgpool is broken by voting and change active/standby
state.
- Automatic virtual IP address assigning synchronous to server switching
When a standby pgpool server promotes to active, the new active server
brings up virtual IP interface. Meanwhile, the previous active server
brings down the virtual IP interface. This enables the active pgpool to
work using the same IP address even when servers is switched over.
- Automatic registration of a server as standby in recovery
When broken server recovers or new server is attached, the watchdog
process notifies the other watchdog process along with information of
the new server, and the watchdog process receives information on the
active server and other servers. Then, the attached server is
registered as standby.
New parameters:
- Add a parameter to enable watchdog: use_watchdog. (Atsushi Mitani)
- Add the parameters about life checking of pgpool service as follows:
wd_interval,other_pgpool_port wd_life_point, wd_lifecheck_query,
other_pgpool_hostname, other_pgpool_port. (Atsushi Mitani)
- Add the parameters about up to stream connection (e.g. to application
servers) as follows:
trusted_servers, ping_path. (Atsushi Mitani)
- Add the parameters about mutual monitoring of watchdog processes
as follows:
wd_hostname, wd_port, other_wd_port. (Atsushi Mitani)
- Add the parameters about virtual IP as follows:
ifconfig_path, if_up_cmd, if_down_cmd, arping_path, arping_cmd.
(Atsushi Mitani)
__________________________________________________________________
* Enhancements
- Retry if health check faied rather than immediately do failover. For
this purpose new directives "health_check_max_retries" and
"health_check_retry_delay" were added. (Tatsuo Ishii)
Patch contributed by Matt Solnit.
Subject: [Pgpool-hackers] Health check retries (patch)
From: Matt Solnit
Date: Fri, 18 Nov 2011 16:28:44 -0500
- Log client IP and port number when pgpool failed to parse given query.
(Tasuo)
This is usefull to identify which client gives wrong query without
enabling log_connections, which produces too many log entries on busy web
systems.
- Refactor pool_process_query(). (Tatsuo Ishii)
Deal with the case when:
1) query not in progress
2) other than master node has pending data.
It is reported that pgpool goes into infinite loop in this case.
[pgpool-general: 43]
Re: [Pgpool-general] seemingly hung pgpool process consuming 100% CPU
http://www.pgpool.net/pipermail/pgpool-general/2011-December/000042.html
- Add "role" which represents "primary" or "standby" iin streaming
replication mode for example to "SHOW pool_nodes" command.(Tatsuo Ishii)
- Add params to the result of "SHOW pool_status": backend_data_directory,
ssl_ca_cert, ssl_ca_cert_dir, and sort by orders in pgpool.conf. (Anzai)
- Commentout params about system db from pgpool.conf.sample-*. (Nozomi Anzai)
- Add new parameter to failover/failback/followmaster command. (Tatsuo Ishii)
%r: new master port number
%R: new master database cluster path
- Allow to reload to recognize md5 password change. (Tatsuo Ishii)
Before, the only way to recognize md5 password change was restarting
pgpool-II. Patch contributed by Gurjeet Singh.
- Remove unused parameter "query" from is_set_transaction_serializable().
(Tastuo Ishii)
- Fix on memory query cache section's comments in pgpool.com in the way
which other sections employ. (Tastuo Ishii)
- Add missing health_check_max_retries and health_check_retry_delay
directives to pgpool.conf.sample-master-slave, pgpool.conf.sample-replication
pgpool.conf.sample-stream. (Tastuo Ishii)
- Fix pool_ssl_write. It seems someone forgot to do retrying when SSL
returns SSL_ERROR_WANT_READ or SSL_ERROR_WANT_WRITE.
Per [pgpool-general: 797]
[pgpool-general: 797]
Re: Problem with pgpool when using SSL, for client/pgpool communication
http://www.sraoss.jp/pipermail/pgpool-general/2012-July/000807.html
- Improve the design of manuals. (Nozomi Anzai)
__________________________________________________________________
* Bug Fix
- Fix memory leak in Raw mode.(Tatsuo Ishii)
- Fix failover/failback in Raw mode. (Tatsuo Ishii)
- Simply does not failover if target node is not master.
- Fail to select master node if the node is in CON_UP.
- Allow health check retry while connect(). (Tatsuo Ishii)
It is reported that connect() blocks sigalarm under some conditions, for
example: When system is configured for security reasons not to return
destination host unreachable messages ([pgpool-general: 131])
Part of changes are contributed by Stevo Slavic.
[pgpool-general: 131] Healthcheck timeout not always respected
http://www.pgpool.net/pipermail/pgpool-general/2012-January/000131.html
- Fix pool_send_and_wait() to send or not to send COMMIT / ABORT depending
on the transaction state on each node. (Tatsuo Ishii)
It is possible that only primary is in an explicit transaction but
standby is not in it if multi statement query has been sent.
Per bug report [pgpool-general-jp: 1049].
- Fix load balance in Solaris. (Tatsuo Ishii)
Problem is, random() in using random() in Solaris results in strange
load balancing calculation.
Use srand()/rand() instead although they produce lesser quality random
Problem reported at [pgpool-general: 396].
[pgpool-general: 396] strange load balancing issue in Solaris
http://www.pgpool.net/pipermail/pgpool-general/2012-April/000397.html
- Fix segfault of pcp_systemdb_info not in parallel mode. (Nozomi Anzai)
- Fix "unnamed prepared statment does not exist" error. (Tatsuo Ishii)
This is caused by pgpool's internal query, which breaks client's unnamed
statements. To fix this, if extended query is used, named
statement/portal for internal are used for internal query.
- Fix hangup when query conflict occurs in Hot-Standby mode. (Yugo Nagata)
Query example to reproduce:
(S1) BEGIN;
(S1) SELECT * FROM t;
(S2) DELETE FROM t;
(S2) VACUUM t;
- Fix pool_process_query() bug reported in [pgpool-general: 672].
(Tatsuo Ishii)
This is caused by the function waits for primary node which does not
have pending data, while standbys have pending data.
[pgpool-general: 672] Transaction never finishes
http://www.pgpool.net/pipermail/pgpool-general/2012-June/000676.html
- Fix wait_for_query_response() not to send param status to frontend if
frontend is NULL. (Tatsuo Ishii)
This could happen while processing reset_query_list and occur crash.
- Fix bug with treatment of BEGIN TRANSACTION in master/slave mode.
(Tatsuo Ishii)
Original complain is [pgpool-general: 714].
From 3.1, pgpool-II sends BEGIN.. to all DB nodes. Of course we cannot
send BEGIN TRANSACTION READ WRITE to standby nodes.
Problem is, we did not check BEGIN WORK ISOLATION LEVEL SERIALIZABLE;
and sent to standby nodes. Of course this is wrong, since it's not
allowed to run transactions in serializable mode on standby nodes.
So added check for BEGIN WORK ISOLATION LEVEL SERIALIZABLE case.
[pgpool-general: 714]
Load Balancing / Streaming Replication / Isolation Level serializable
http://www.pgpool.net/pipermail/pgpool-general/2012-July/000719.html
- Fix send_to_where() to send the query to only primary if the it is like
SET TRANSACTION ISOLATION LEVELSERIALIZABLE etc. (Tatsuo Ishii)
Case in streaming replication mode. Previously, it was sent to not only
primary but also to standby and of course this causes an error.
Similar SQLs are:
SET SESSION CHARACTERISTICS AS TRANSACTION ISOLATION LEVEL SERIALIZABLE or
SET transaction_isolation TO 'serializable'
SET default_transaction_isolation TO 'serializable'
Original complain is [pgpool-general: 715].
[pgpool-general: 715]
Re: Load Balancing / Streaming Replication / Isolation Level serializable
http://www.pgpool.net/pipermail/pgpool-general/2012-July/000720.html
- Prevent errors even if memcached is not available with on memory query
cache enabled and cache storage is memcached. (Tatsuo Ishii)
This is mainly achieved by modifying pool_fetch_cache to pretend
"cache not found" if memcached_get returns error other than
MEMCACHED_NOTFOUND. Also we set pool_config->memory_cache_enabled to 0 to
prevent future errors by accessing memcached.
- Run rerun libtoolize with --copy and --force option. (Tatsuo Ishii)
This should prevent build problems in different environment.
Following commands were executed:
libtoolize --copy --force
aclocal
autoheader
automake -a
autoconf
- Fix pool_ssl_read. (Tatsuo Ishii)
When SSL_read returns unknown error, treat as if EOF detected and returns 0
to caller (pool_read). This is same as libpq's behavior. Also this will
avoid unwanted failover in pool_read. pool_read triggers failover if
underlying I/O functions, read(2) or pool_ssl_read returns -1.
- Fix pool_process_query. (Tatsuo Ishii)
When other than primary sends packet, pgpool tries to terminate session
gracefully and hung because now ssl_read returns EOF, rather than error
and triggers failover. For example [pgpool-general: 766] reported this:
2012-07-17 00:11:03 NZST [15692]: [257-1] ERROR: canceling statement
due to conflict with recovery
2012-07-17 00:11:03 NZST [15692]: [258-1] DETAIL: User query might
have needed to see row versions that must be removed.
2012-07-17 00:11:03 NZST [15692]: [259-1] STATEMENT: <SNIP>
2012-07-17 00:11:03 NZST [15696]: [366-1] FATAL: terminating
connection due to conflict with recovery
2012-07-17 00:11:03 NZST [15696]: [367-1] DETAIL: User query might
have needed to see row versions that must be removed.
In this case pool_process_query should return POOL_ERROR, rather than
POOL_END.
[pgpool-general: 766]
Re: pgpool dropping backends too much
http://www.pgpool.net/pipermail/pgpool-general/2012-July/000774.html
- If frontend terminates while reading large number of query results
from backend, pgpool continues to read from backend and write to
frontend until all query results consumued. (Tatsuo Ishii)
This will take very long time if query results is huge. To finish pgpool
session as soon as possible, modify pool_flush_it to returns error if
fail to write to frontend when operated in other than replication mode.
In replication mode, we need to keep the previous behavior to save
consistency among backends).
Also fix SimpleForwardToFrontend to return pool_write_and_flush error
status. Before it was ignored.
===============================================================================
3.1 Series (2011/09/08 - )
===============================================================================
3.1.3 (hatsuiboshi) 2012/04/23
* Version 3.1.3
This is a bugfix release against pgpool-II 3.1.2.
__________________________________________________________________
* Bug fixes
- Add m4 files. This should prevent compiling problem on older
OS's. (Tatsuo Ishii)
- Fix to handle failover properly in detect_postmaster_down_error().
(Tatsuo Ishii)
It is possible that it fails to read backend socket after detecting
backend errors and before actually detaching the backend.
- Fix bug that the process exits before unlocking semaphore by a
signal interrupt. (Tatsuo Ishii)
- Fix a memory leak in case of reset_query. (Tatsuo Ishii)
- Fix pool_ssl_read() to deal with large data reading. (Tatsuo Ishii)
Original complain is here:
http://www.pgpool.net/pipermail/pgpool-general/2012-March/000299.html
- Fix deadlock by enabling log_destination = syslog. (Tatsuo Ishii)
Reported in bug tracker http://www.pgpool.net/mantisbt/view.php?id=9.
Patch provided by Gilles Darold.
- Allow to use multi statement in master/slave mode. (Tatsuo Ishii)
From 3.1 transactional statements such as "BEGIN" are sent to not only
primary but also standbys. This brings an unfortunate side effect: if
the multi statement is "BEGIN;DELETE FROM table;END", this will be
sent to standy as well and cause an error because standby does notallow
write SQL. So fix is, if a query is a multi statement one, then send it
to primary only.
- Allow to have private cache of master node id. (Tatsuo Ishii)
When master goes down running pgpool children look into NULL pointer
because the process does not connect to the new master yet. The private
cache returns the old master node id and will avoid the situation.
Per bug reported in http://www.pgpool.net/mantisbt/view.php?id=51
- Fix pool_start_query() so that it uses my_master_node_id instead of
REAL_MASTER_NODE_ID for initial virtual_master_node_id. (Tatsuo Ishii)
Real master node could be changed while pgpool is running in streaming
replication mode. Previously it is assigned REAL_MASTER_NODE_ID, which
could have no connections after fail over and cause segafult.
- Fix pool_setall_node_to_be_sent() to use private_backend_status instead
of BACKEND_INFO macro. (Tatsuo Ishii)
It is possible that while processing, the node returned by BACKEND_INFO
is not usable any more.
- Fix failover(). (Tatsuo Ishii)
Before it only restarts worker child only when pgpool child do not need
restart. This is wrong. We need to restart worker child in any case.
Otherwise it continues to send replication time lag check request to down
the node.
- Fix debug log message so that it does not contain null characters.
(Toshihiro Kitagawa)
- Fix SimpleQuery() so that it restores parser memory context when:
1) Builtin show commands are used
2) Parallel query mode
3) Query cache is used
(Tatsuo Ishii)
- Fix hangup when PREPARE statement causes error. (Toshihiro Kitagawa)
This issue was reported by Tomonari Katsumata:
Subject: [pgpool-general: 121] question of pgpool's behavior
- Add doc/pgpool-fr.html to Makefile.am. (Tatsuo Ishii)
This had been forgotten when the doc was added.
- Fix hangup during md5 authentication that occurs in daemon mode
and log_destination is 'syslog'. (Yugo Nagata)
Reported in bug tracker http://www.pgpool.net/mantisbt/view.php?id=2.
===============================================================================
3.1.2 (hatsuiboshi) 2012/01/31
* Version 3.1.2
This is a bugfix release against pgpool-II 3.1.1.
__________________________________________________________________
* Bug fixes
- Fix to recognize READ UNCOMMITTED and REPEATABLE READ of transaction
isolation levels. (Tatsuo Ishii)
- Fix infinite loop reported in this thread (Tatsuo Ishii):
http://www.pgpool.net/pipermail/pgpool-general/2011-December/000099.html
It was not considered the case that, when received buffer in primary was
empty but the one in a standby was not, the standby spontaneously sent
packet to pgpool.
This could happen when, for example, reloading postgresql.conf.
The fix is that such buffer in standby is discarded.
===============================================================================
3.1.1 (hatsuiboshi) 2011/12/06
* Version 3.1.1
This is a bugfix release against pgpool-II 3.1.
__________________________________________________________________
* Bug fixes
- Fix add_regex_pattern(). It does not allocate enough memory
for each black/white_function_list items.
The function adds "^" and "$" to each function items which do not
contain those characters. Unfortunately the function forgot to add
extra 2 bytes for those characters. This may lead to memory
corruption errors when pgpool starting up.
- Fix error message of check_replication_time_lag(Tatsuo Ishii).
It emitted wrong error message when it failed to connect to PostgreSQL
while checking streaming replication delay.
Because it does not use health_check_user anymore.
- Fix memory leak(Toshihiro Kitagawa). This is essentially same
as the fix made for 3.0.5
(commit 19a4ea9215da0b61728741fc0da2271958b09238).
- Major cleanup for strncpy(Tatsuo Ishii).
There are several places where strncpy() is used. Problem is some of
them do not consider the case when copy lengh == buffer size.
In this case copied buffer is not null terminated and may cause
tons of problems later. To fix this, most of them are replaced by
strlcpy().
- Update cached backend status whenever possible(Tatsuo Ishii).
This solves the problem of follow_master_command not being
able to lookup backend status correctly which was reported by
Jeff Frost: Subject: [Pgpool-general] diagnosing BackendError
from pcp_recovery_node To: pgpool-general@pgfoundry.org Date:
Wed, 05 Oct 2011 15:15:07 -0700
- Fix buffer overrun problem when pcp password is longer than 32
(Tatsuo Ishii).
- Remove PGDLLIMPORTI which is only neccessary for Windows and
cause a problem for non gcc. Patch contributed by Ibrar Ahmed.
===============================================================================
3.1 (hatsuiboshi) 2011/09/08
* Version 3.1
This is the first version of pgpool-II 3.1 series.
That is, a "major version up" from 3.0 series.
__________________________________________________________________
* Incompatible changes
- Change the lock method of insert_lock. The previous insert_lock uses
row locking against the sequence relation, but the current one uses
row locking against pgpool_catalog.insert_lock table.
The reason is that PostgreSQL core developers decided to disallow row
locking against the sequence relation to avoid an internal error
which it leads. So creating insert_lock table in all databases which are
accessed via pgpool-II beforehand is required.
If does not exist insert_lock table, pgpool-II locks the insert target
table. This behavior is same as pgpool-II 2.2 and 2.3 series.
If you want to use insert_lock which is compatible with older releases,
you can specify lock method by configure options: --enable-sequence-lock,
--enable-table-lock(Toshihiro Kitagawa)
- Deprecate backend_socket_dir. Instead, if backend_hostname starts
with '/' it is regarded the as path to Unix domain. If backend_hostname
is left empty, then default Unix domain path(/tmp) is used. This
follows the convention of libpq interface. Patch contributed by
Jehan-Guillaume (ioguix) de Rorthais.
- Now "pgpool_walrecrunning()" was not used. pgpool-II used to consider
the node that is promoted a primary node using the function. Now,
pgpool-II waits for completing of the promotion to primary node
because it did not work as we intended. But we still have a problem
that pgpool-II waits while recovery_timeout, when there is no primary
node(Toshihiro Kitagawa)
- Add node_id to each PostgreSQL DB node info in the output of
show pool_nodes(Jean-Paul Argudo)
- Change the handling of sequence functions(nextval, setval) so that
they completely obey setting of black/white_function_list. They were
always handled as write functions before(Toshihiro Kitagawa)
__________________________________________________________________
* New features
- Add syslog support. Patch contributed by Gilles Darold. Review and
editing by Guillaume Lelarge.
- Adapt application_name introduced in PostgreSQL 9.0. When reusing
connection, send application_name in the startup packet to backend
and send parameter status to frontend(Tatsuo Ishii)
- Add relcache_expire directive to control the expiration of the
internal system catalog cache. ALTER TABLE might make these
cache values obsoleted and the new directive will make the risk
lower(Tatsuo Ishii).
- Add follow_master_command directive. This directive specifies a
command to run in master/slave streaming replication only after
a master failover. Patch contributed by Gilles Darold.
- Add pcp_promote_node command. This command promotes a new master
node to pgpool-II. This can use in master/slave streaming replication
only. Patch contributed by Gilles Darold.
- Add pcp_pool_status command which produces similar output of show
pool_status. Also C API for this command is added. Patch
contributed by Jehan-Guillaume (ioguix) de Rorthais.
- Add new per backend directive "backend_flag". This controls per
backend behavior. Currently "ALLOW_TO_FAILOVER" or
"DISALLOW_TO_FAILOVER" are allowed(Tatsuo Ishii)
- Add health_check_password directive(Nicolas Thauvin)
- Add sr_check_period, sr_check_user and sr_check_password directives.
These are used for streaming replication delay checking and
determining primary node(Tatsuo Ishii)
- Add --username(or -u) option to pg_md5 command. This allows to manage
users which do not have UNIX accounts. Japanese document change by
Tatsuo Ishii(Nicolas Thauvin)
- Add pgpool_adm functions to pgpool_adm/. These are user-defined
functions written in C language which work like pcp commands
(Jehan-Guillaume (ioguix) de Rorthais)
- Add Simplified Chinese version of documents(Huang Jian, Sun Peng)
- Add SQL files to uninstall functions to sql/(Nicolas Thauvin)
- In master/slave mode, SELECTs to unlogged table execute only on
master/primary(Toshihiro Kitagawa)
__________________________________________________________________
* Bug fixes
- Fix bug which cannot use the cursors of JDBC driver on standby
node. The transaction commands come to be sent to all nodes by
this fix in master/slave mode(Toshihiro Kitagawa)
- Fix bug with the handling of empty queries. The empty queries
come to be handled the same as SELECT queries. This fix allows
load-balance after the empty query(Toshihiro Kitagawa)
- Fix insert_lock so that it works correctly even if the column
definition such as "DEFAULT nextval(('"x_seq"'::text)::regclass)"
(Toshihiro Kitagawa)
- Fix pcp_attach_node command so that it emits error message while
doing failover(Toshihiro Kitagawa)
- Fix log message which is emitted when pgpool-II cannot parse the
query in the extended query protocol so that it shows the query
(Toshihiro Kitagawa)
- Fix description about backend_weight inpgpool-II manual. It can
be changed by reloading pgpool.conf(Tatsuo Ishii)
- Fix and enhance wording in English tutorial document.
Fix suggested by Huang Jian(Tatsuo Ishii)
- Fix bug which does not update the node status when reattaching the
node in raw mode(Guillaume Lelarge)
- Fix incorrect calculation of the replication delay in streaming
replication mode(Tatsuo Ishii)
- Replace wrong function name "notice_backend_error" with correct one
"degenerate_backend_set" in the failover log message(Tatsuo Ishii)
- Remove unnecessary logging at the end of pgpool.conf parsing
(Tatsuo Ishii)
- Fix possible crash of pgpool/worker child after attaching new backend.
Fix suggested by Gurjeet Singh(Tatsuo Ishii)
- Fix bug that SELECTs which have subquery with FOR SHARE/UPDATE clause
are sent to slave/standby(Tatsuo Ishii)
- Fix bug which rewriting timestamp of default value fails in PREPARE
statements. This used to work but was broken in 3.0(Toshihiro Kitagawa)
- Fix fail to compile pcp commands on the environment without
getopt_long()(Tatsuo Ishii)
- Fix crash of pgpool child when frontend connects if in raw mode,
enable_hba is off and more than 2 backends(Toshihiro Kitagawa)
- Fix some memory leaks(Toshihiro Kitagawa)
__________________________________________________________________
* Enhancements
- Enhance online recovery in streaming replication mode.
Now restarting pgpool-II children is avoided when recovery finished.
So existing sessions can be continued while doing online recovery
(Tatsuo Ishii)
- pcp_attach_node does not diconnect existing sessions in
streaming replication mode. In other mode, pcp_attache_node
still disconnects existing sessions(Tatsuo Ishii).
- Import PostgreSQL 9.0 parser. This allows to use CREATE INDEX with
implicit index name, which is new in 9.0. Patch contributed by
Akio Ishida.
- Allow to use regular expressions in black and white function list.
Patch contributed by Gilles Darold. Patch reviewed by Guillaume Lelarge.
- Reorganize pgpool.conf sample files so that they are easier to read
(Guillaume Lelarge)
- Add <a name="..."> tags into all parameters in the pgpool-II user
manual(Haruka Takatsuka)
- Enhance online recovery documents in streaming replication(Tatsuo Ishii)
- Change the function to check the replication delay in streaming
replication mode. Currently, pgpool uses
pg_last_xlog_replay_location() instead of
pg_last_xlog_receive_location(). Fix suggested by Anton Yuzhaninov
(Tatsuo Ishii)
- Allow time stamp rewriting to work with arbitrary expression in
default value of a column. Before we detected anything including
now() then simply replaced it to now(). This will lead to wrong
rewriting of default value. for example, timezone('utc'::text, now()).
Note that, however, this only adopts to simple queries. Extended
protocols(for example Java, PHP PDO) or SQL "PREPARE" still remain
same(Tatsuo Ishii)
- Enhance the error message which is emitted when failed to check
replication delay(Nicolas Thauvin)
- Change error message "do_md5: read_password_packet failed" into debug
level(Toshihiro Kitagawa)
- Allow to compile pgpool-regclass() against PostgreSQL 9.1(Tatsuo Ishii)
- Update and sync pgpool-II manuals of English version and Japanese
version(Tatsuo Ishii)
===============================================================================
3.0 Series (2010/09/10 - )
===============================================================================
3.0.7 (umiyameboshi) 2012/04/23
* Version 3.0.7
This is a bugfix release against pgpool-II 3.0.6.
__________________________________________________________________
* Bug fixes
- Add m4 files. This should prevent compiling problem on older
OS's. (Tatsuo Ishii)
- Fix bug that the process exits before unlocking semaphore by a
signal interrupt. (Tatsuo Ishii)
- Fix a memory leak in case of reset_query. (Tatsuo Ishii)
- Fix SimpleQuery() so that it restores parser memory context when:
1) Builtin show commands are used
2) Parallel query mode
3) Query cache is used
(Tatsuo Ishii)
- Fix pool_ssl_read() to deal with large data reading. (Tatsuo Ishii)
Original complain is here:
http://www.pgpool.net/pipermail/pgpool-general/2012-March/000299.html
- Fix hangup when PREPARE statement causes error. (Toshihiro Kitagawa)
This issue was reported by Tomonari Katsumata:
Subject: [pgpool-general: 121] question of pgpool's behavior
===============================================================================
3.0.6 (umiyameboshi) 2012/01/31
* Version 3.0.6
This version fixes various bugs since 3.0.5.
- Fix infinite loop reported in this thread (Tatsuo Ishii):
http://www.pgpool.net/pipermail/pgpool-general/2011-December/000099.html
It was not considered the case that, when received buffer in primary was
empty but the one in a standby was not, the standby spontaneously sent
packet to pgpool.
This could happen when, for example, reloading postgresql.conf.
The fix is that such buffer in standby is discarded.
===============================================================================
3.0.5 (umiyameboshi) 2011/10/31
* Version 3.0.5
This version fixes various bugs since 3.0.4.
__________________________________________________________________
* Bug fixes
- Fix bug with the handling of empty queries. The empty queries
come to be handled the same as SELECT queries. This fix allows
load-balance after the empty query(Toshihiro Kitagawa)
- Fix insert_lock so that it works correctly even if the column
definition such as "DEFAULT nextval(('"x_seq"'::text)::regclass)"
(Toshihiro Kitagawa)
- Fix log message which is emitted when pgpool-II cannot parse the
query in the extended query protocol so that it shows the query
(Toshihiro Kitagawa)
- Fix description about backend_weight inpgpool-II manual. It can
be changed by reloading pgpool.conf(Tatsuo Ishii)
- Fix bug which does not update the node status when reattaching the
node in raw mode(Guillaume Lelarge)
- Fix bug that SELECTs which have subquery with FOR SHARE/UPDATE clause
are sent to slave/standby(Tatsuo Ishii)
- Fix bug which rewriting timestamp of default value fails in PREPARE
statements. This used to work but was broken in 3.0(Toshihiro Kitagawa)
- Fix crash of pgpool child when frontend connects if in raw mode,
enable_hba is off and more than 2 backends(Toshihiro Kitagawa)
- Fix some memory leaks(Toshihiro Kitagawa)
__________________________________________________________________
* Enhancements
- Allow time stamp rewriting to work with arbitrary expression in
default value of a column. Before we detected anything including
now() then simply replaced it to now(). This will lead to wrong
rewriting of default value. for example, timezone('utc'::text, now()).
Note that, however, this only adopts to simple queries. Extended
protocols(for example Java, PHP PDO) or SQL "PREPARE" still remain
same(Tatsuo Ishii)
- Change error message "do_md5: read_password_packet failed" into debug
level(Toshihiro Kitagawa)
===============================================================================
3.0.4 (umiyameboshi) 2011/06/01
* Version 3.0.4
This version fixes various bugs since 3.0.3.
__________________________________________________________________
* Incompatible changes
- In streaming replication, if delay_threshold is 0 or health
checking is disabled, the delay checking is not performed.
This is the behaviour according to a description of the
pgpool-II manual. But, so far the delay checking was performed
even if health checking was disabled(Guillaume Lelarge)
__________________________________________________________________
* Bug fixes
- Fix pgpool-regclass() to be compiled in PostgreSQL 8.0 or later.
7.4 still produces errors(Tatsuo Ishii)
- Fix possible hangup when using /*NO LOAD BALANCE*/ comment in
streaming replication(Toshihiro Kitagawa)
- Fix hangup when received Flush(H) message or CloseComplete(C)
message(Toshihiro Kitagawa)
- Fix possible hangup that happen for the receiving timing of
ReadyForQuery(Z) message after pgpool-II connects to backends
(Toshihiro Kitagawa)
- Add description about parameters for recovery_1st_stage_command
and recovery_2nd_stage_command(Tatsuo Ishii)
- Increase size of the internal system catalog cache from 32 to 128.
This has the effect of reducing "unnamed prepared statement does
not exist" error(Tatsuo, Kitagawa)
- Fix bug with pcp_connect() which causes double free. Patch
contributed by Jehan-Guillaume (ioguix) de Rorthais(Tatsuo Ishii)
- Fix bug with start_recoery() which is apparently wrong usage of
PQfinish()(Tatsuo Ishii)
- Fix incorrect error message which is sent to the frontend when
client idle time reached client_idle_limit(Tatsuo Ishii)
- Fix "backend status" variable name correctly in pool_status.
Replace the space with a '_'(Guillaume Lelarge)
- Fix hangup when using md5 authentication method and running as
daemon. Patch contributed by Nicolas Thauvin(Tatsuo Ishii)
- Fix log_per_node_statement so that it prints statements in the
extended query protocol. This used to work but was broken in 3.0
(Toshihiro Kitagawa)
__________________________________________________________________
* Enhancements
- Add currval() and lastval() to black_function_list of sample
configuration files. If they are load balanced, currval() or
lastval() may be called before the result of nextval() or setval()
is propagated to slaves(Tatsuo Ishii)
===============================================================================
3.0.3 (umiyameboshi) 2011/02/23
* Version 3.0.3
This version fixes various bugs since 3.0.1. Please note that
3.0.2 was canceled due to a packaging problem.
__________________________________________________________________
* Incompatible changes
- Now installing C function "pgpool_walrecrunning()" is recommended
if you plan to use streaming replication mode.
This is necessary for better use of online recovery in the mode.
Also new variable "%P" can be used in the online recovery script.
If you do not install the function, these functionalities Cannot
be used(Tatsuo Ishii).
- In raw mode if there's only one DB node and if a problem arises
with the DB node, it will be brought to down status. However if
the DB node goes into good condition again, you can use the DB
node without restarting pgpool. This change has been included in
3.0, but did not work(Tatsuo, Kitagawa)
__________________________________________________________________
* Bug fixes