View Issue Details

IDProjectCategoryView StatusLast Update
0000356Pgpool-IIBugpublic2017-11-09 16:42
Reporterzachwalton Assigned ToMuhammad Usama  
PrioritynormalSeveritymajorReproducibilityalways
Status closedResolutionopen 
Product Version3.6.6 
Fixed in Version3.6.7 
Summary0000356: pg_terminate_backend() causing failover despite setting flag
DescriptionReproduced on RHEL 6 and MacOS.

This issue seems to have recurred:

http://www.pgpool.net/pipermail/pgpool-general/2017-February/005378.html

15:48 $ pgpool --version
pgpool-II version 3.6.6 (subaruboshi)

2017-10-18 15:08:55: pid 37631: LOG: found the pg_terminate_backend request for backend pid:37664 on backend node:0
2017-10-18 15:08:55: pid 37631: DETAIL: setting the connection flag
2017-10-18 15:08:55: pid 37631: LOG: DB node id: 0 backend pid: 37835 statement: select pg_terminate_backend(37664)
2017-10-18 15:08:55: pid 37651: LOG: reading and processing packets
2017-10-18 15:08:55: pid 37651: DETAIL: postmaster on DB node 0 was shutdown by administrative command
2017-10-18 15:08:55: pid 37651: FATAL: unable to read data from DB node 0
2017-10-18 15:08:55: pid 37651: DETAIL: EOF encountered with backend
Steps To Reproduce1. Call pg_terminate_backend(pid) on a pid from pg_stat_activity() through the pgpool VIP
2. Note the log line indicating that pg_terminate_backend() was intercepted
3. Note that it fails over anyway
TagsNo tags attached.

Activities

Muhammad Usama

2017-10-26 01:07

developer   ~0001787

Hi

I have found an issue in handling of pg_terminate_backend() and pushed the fix for it.
https://git.postgresql.org/gitweb/?p=pgpool2.git;a=commitdiff;h=43e0994264622415ae3d9661b3a9888810df6277

Can you verify building from the current head of V3_6_STABLE or master branch if it also fixes the issue you are facing.

zachwalton

2017-10-31 05:51

reporter   ~0001791

Confirmed that this fixes the issue! Thanks a lot!

Issue History

Date Modified Username Field Change
2017-10-19 07:53 zachwalton New Issue
2017-10-19 17:06 t-ishii Assigned To => Muhammad Usama
2017-10-19 17:06 t-ishii Status new => assigned
2017-10-26 01:07 Muhammad Usama Status assigned => feedback
2017-10-26 01:07 Muhammad Usama Note Added: 0001787
2017-10-31 05:51 zachwalton Note Added: 0001791
2017-10-31 05:51 zachwalton Status feedback => assigned
2017-11-09 16:42 t-ishii Status assigned => closed
2017-11-09 16:42 t-ishii Fixed in Version => 3.6.7