<div dir="ltr">Yes Tatsuo we have encrypted the postgres user in both servers<div><br></div><div>SELECT * from pg_shadow a WHERE a.usename='postgres';<br><div><br></div><div>postgres<span class="" style="white-space:pre">   </span>10<span class="" style="white-space:pre">        </span>t<span class="" style="white-space:pre"> </span>t<span class="" style="white-space:pre"> </span>t<span class="" style="white-space:pre"> </span>t<span class="" style="white-space:pre"> </span>md59798b5eb1000b9fad41c78e5a3dccxxx<br></div></div><div><br></div><div>Is diferent a pcp.conf</div><div><br></div><div><div># USERID:MD5PASSWD</div><div>postgres:5c0435eee0f211f150e980e459151xxx</div></div><div><br></div><div>thanks again for your time!!</div><div><br></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">2016-04-07 23:57 GMT-03:00 Tatsuo Ishii <span dir="ltr"><<a href="mailto:ishii@postgresql.org" target="_blank">ishii@postgresql.org</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">pg_hba.conf looks good.  So the user in question has encrypted<br>
password on the both PostgreSQL server? You can check it by looking at<br>
pg_shadow (needs PostgreSQL super user privilege). The "password"<br>
column should look something like "md5.....".<br>
<span class=""><br>
Best regards,<br>
--<br>
Tatsuo Ishii<br>
</span><span class="">SRA OSS, Inc. Japan<br>
English: <a href="http://www.sraoss.co.jp/index_en.php" rel="noreferrer" target="_blank">http://www.sraoss.co.jp/index_en.php</a><br>
Japanese:<a href="http://www.sraoss.co.jp" rel="noreferrer" target="_blank">http://www.sraoss.co.jp</a><br>
<br>
</span><div><div class="h5">> Thanks a lots for your time!!!!<br>
><br>
> Master pgpool.conf and pg_hba.conf<br>
><br>
> # ----------------------------<br>
> # pgPool-II configuration file<br>
> # ----------------------------<br>
> #<br>
> # This file consists of lines of the form:<br>
> #<br>
> #   name = value<br>
> #<br>
> # Whitespace may be used.  Comments are introduced with "#" anywhere on a<br>
> line.<br>
> # The complete list of parameter names and allowed values can be found in<br>
> the<br>
> # pgPool-II documentation.<br>
> #<br>
> # This file is read on server startup and when the server receives a SIGHUP<br>
> # signal.  If you edit the file on a running system, you have to SIGHUP the<br>
> # server for the changes to take effect, or use "pgpool reload".  Some<br>
> # parameters, which are marked below, require a server shutdown and restart<br>
> to<br>
> # take effect.<br>
> #<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # CONNECTIONS<br>
> #------------------------------------------------------------------------------<br>
><br>
> # - pgpool Connection Settings -<br>
><br>
> listen_addresses = '*'<br>
>                                    # Host name or IP address to listen on:<br>
>                                    # '*' for all, '' for no TCP/IP<br>
> connections<br>
>                                    # (change requires restart)<br>
> port = 9999<br>
>                                    # Port number<br>
>                                    # (change requires restart)<br>
> socket_dir = '/tmp'<br>
>                                    # Unix domain socket path<br>
>                                    # The Debian package defaults to<br>
>                                    # /var/run/postgresql<br>
>                                    # (change requires restart)<br>
><br>
><br>
> # - pgpool Communication Manager Connection Settings -<br>
><br>
> pcp_listen_addresses = '*'<br>
>                                    # Host name or IP address for pcp<br>
> process to listen on:<br>
>                                    # '*' for all, '' for no TCP/IP<br>
> connections<br>
>                                    # (change requires restart)<br>
> pcp_port = 9898<br>
>                                    # Port number for pcp<br>
>                                    # (change requires restart)<br>
> pcp_socket_dir = '/tmp'<br>
>                                    # Unix domain socket path for pcp<br>
>                                    # The Debian package defaults to<br>
>                                    # /var/run/postgresql<br>
>                                    # (change requires restart)<br>
> listen_backlog_multiplier = 2<br>
>                                    # Set the backlog parameter of listen(2)<br>
> to<br>
>   # num_init_children * listen_backlog_multiplier.<br>
>                                    # (change requires restart)<br>
><br>
> # - Backend Connection Settings -<br>
><br>
>                                    # Host name or IP address to connect to<br>
> for backend 0<br>
>                                    # Port number for backend 0<br>
>                                    # Weight for backend 0 (only in load<br>
> balancing mode)<br>
>                                    # Data directory for backend 0<br>
>                                    # Controls various backend behavior<br>
>                                    # ALLOW_TO_FAILOVER or<br>
> DISALLOW_TO_FAILOVER<br>
><br>
> # - Authentication -<br>
><br>
> enable_pool_hba = on<br>
>                                    # Use pool_hba.conf for client<br>
> authentication<br>
> pool_passwd = 'pool_passwd'<br>
>                                    # File name of pool_passwd for md5<br>
> authentication.<br>
>                                    # "" disables pool_passwd.<br>
>                                    # (change requires restart)<br>
> authentication_timeout = 60<br>
>                                    # Delay in seconds to complete client<br>
> authentication<br>
>                                    # 0 means no timeout.<br>
><br>
> # - SSL Connections -<br>
><br>
> ssl = off<br>
>                                    # Enable SSL support<br>
>                                    # (change requires restart)<br>
> #ssl_key = './server.key'<br>
>                                    # Path to the SSL private key file<br>
>                                    # (change requires restart)<br>
> #ssl_cert = './server.cert'<br>
>                                    # Path to the SSL public certificate file<br>
>                                    # (change requires restart)<br>
> #ssl_ca_cert = ''<br>
>                                    # Path to a single PEM format file<br>
>                                    # containing CA root certificate(s)<br>
>                                    # (change requires restart)<br>
> #ssl_ca_cert_dir = ''<br>
>                                    # Directory containing CA root<br>
> certificate(s)<br>
>                                    # (change requires restart)<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # POOLS<br>
> #------------------------------------------------------------------------------<br>
><br>
> # - Pool size -<br>
><br>
> num_init_children = 32<br>
>                                    # Number of pools<br>
>                                    # (change requires restart)<br>
> max_pool = 4<br>
>                                    # Number of connections per pool<br>
>                                    # (change requires restart)<br>
><br>
> # - Life time -<br>
><br>
> child_life_time = 300<br>
>                                    # Pool exits after being idle for this<br>
> many seconds<br>
> child_max_connections = 0<br>
>                                    # Pool exits after receiving that many<br>
> connections<br>
>                                    # 0 means no exit<br>
> connection_life_time = 0<br>
>                                    # Connection to backend closes after<br>
> being idle for this many seconds<br>
>                                    # 0 means no close<br>
> client_idle_limit = 0<br>
>                                    # Client is disconnected after being<br>
> idle for that many seconds<br>
>                                    # (even inside an explicit transactions!)<br>
>                                    # 0 means no disconnection<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # LOGS<br>
> #------------------------------------------------------------------------------<br>
><br>
> # - Where to log -<br>
><br>
> log_destination = 'syslog'<br>
>                                    # Where to log<br>
>                                    # Valid values are combinations of<br>
> stderr,<br>
>                                    # and syslog. Default to stderr.<br>
><br>
> # - What to log -<br>
><br>
> log_line_prefix = '%t: pid %p:    # printf-style string to output at<br>
> beginning of each log line.'<br>
><br>
> log_connections = off<br>
>                                    # Log connections<br>
> log_hostname = on<br>
>                                    # Hostname will be shown in ps status<br>
>                                    # and in logs if connections are logged<br>
> log_statement = on<br>
>                                    # Log all statements<br>
> log_per_node_statement = on<br>
>                                    # Log all statements<br>
>                                    # with node and backend informations<br>
> log_standby_delay = 'if_over_threshold'<br>
>                                    # Log standby delay<br>
>                                    # Valid values are combinations of<br>
> always,<br>
>                                    # if_over_threshold, none<br>
><br>
> # - Syslog specific -<br>
><br>
> syslog_facility = 'LOCAL0'<br>
>                                    # Syslog local facility. Default to<br>
> LOCAL0<br>
> syslog_ident = 'pgpool'<br>
>                                    # Syslog program identification string<br>
>                                    # Default to 'pgpool'<br>
><br>
> # - Debug -<br>
><br>
> debug_level = 5<br>
>                                    # Debug message verbosity level<br>
>                                    # 0 means no message, 1 or more mean<br>
> verbose<br>
><br>
> log_error_verbosity = 'DEFAULT'<br>
><br>
> #client_min_messages = notice           # values in order of decreasing<br>
> detail:<br>
>                                         #   debug5<br>
>                                         #   debug4<br>
>                                         #   debug3<br>
>                                         #   debug2<br>
>                                         #   debug1<br>
>                                         #   log<br>
>                                         #   notice<br>
>                                         #   warning<br>
>                                         #   error<br>
><br>
> #log_min_messages = warning             # values in order of decreasing<br>
> detail:<br>
>                                         #   debug5<br>
>                                         #   debug4<br>
>                                         #   debug3<br>
>                                         #   debug2<br>
>                                         #   debug1<br>
>                                         #   info<br>
>                                         #   notice<br>
>                                         #   warning<br>
>                                         #   error<br>
>                                         #   log<br>
>                                         #   fatal<br>
>                                         #   panic<br>
><br>
> #------------------------------------------------------------------------------<br>
> # FILE LOCATIONS<br>
> #------------------------------------------------------------------------------<br>
><br>
> pid_file_name = '/var/run/pgpool/pgpool.pid'<br>
>                                    # PID file name<br>
>                                    # (change requires restart)<br>
> logdir = '/tmp'<br>
>                                    # Directory of pgPool status file<br>
>                                    # (change requires restart)<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # CONNECTION POOLING<br>
> #------------------------------------------------------------------------------<br>
><br>
> connection_cache = on<br>
>                                    # Activate connection pools<br>
>                                    # (change requires restart)<br>
><br>
>                                    # Semicolon separated list of queries<br>
>                                    # to be issued at the end of a session<br>
>                                    # The default is for 8.3 and later<br>
> reset_query_list = 'ABORT; DISCARD ALL'<br>
>                                    # The following one is for 8.2 and before<br>
> #reset_query_list = 'ABORT; RESET ALL; SET SESSION AUTHORIZATION DEFAULT'<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # REPLICATION MODE<br>
> #------------------------------------------------------------------------------<br>
><br>
> replication_mode = off<br>
>                                    # Activate replication mode<br>
>                                    # (change requires restart)<br>
> replicate_select = off<br>
>                                    # Replicate SELECT statements<br>
>                                    # when in replication mode<br>
>                                    # replicate_select is higher priority<br>
> than<br>
>                                    # load_balance_mode.<br>
><br>
> insert_lock = off<br>
>                                    # Automatically locks a dummy row or a<br>
> table<br>
>                                    # with INSERT statements to keep SERIAL<br>
> data<br>
>                                    # consistency<br>
>                                    # Without SERIAL, no lock will be issued<br>
> lobj_lock_table = ''<br>
>                                    # When rewriting lo_creat command in<br>
>                                    # replication mode, specify table name to<br>
>                                    # lock<br>
><br>
> # - Degenerate handling -<br>
><br>
> replication_stop_on_mismatch = off<br>
>                                    # On disagreement with the packet kind<br>
>                                    # sent from backend, degenerate the node<br>
>                                    # which is most likely "minority"<br>
>                                    # If off, just force to exit this session<br>
><br>
> failover_if_affected_tuples_mismatch = off<br>
>                                    # On disagreement with the number of<br>
> affected<br>
>                                    # tuples in UPDATE/DELETE queries, then<br>
>                                    # degenerate the node which is most<br>
> likely<br>
>                                    # "minority".<br>
>                                    # If off, just abort the transaction to<br>
>                                    # keep the consistency<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # LOAD BALANCING MODE<br>
> #------------------------------------------------------------------------------<br>
><br>
> load_balance_mode = on<br>
>                                    # Activate load balancing mode<br>
>                                    # (change requires restart)<br>
> ignore_leading_white_space = on<br>
>                                    # Ignore leading white spaces of each<br>
> query<br>
> white_function_list = ''<br>
>                                    # Comma separated list of function names<br>
>                                    # that don't write to database<br>
>                                    # Regexp are accepted<br>
> black_function_list = 'currval,lastval,nextval,setval'<br>
>                                    # Comma separated list of function names<br>
>                                    # that write to database<br>
>                                    # Regexp are accepted<br>
><br>
> database_redirect_preference_list = ''<br>
>   # comma separated list of pairs of database and node id.<br>
>   # example: postgres:primary,mydb[0-4]:1,mydb[5-9]:2'<br>
>   # valid for streaming replicaton mode only.<br>
><br>
> app_name_redirect_preference_list = ''<br>
>   # comma separated list of pairs of app name and node id.<br>
>   # example: 'psql:primary,myapp[0-4]:1,myapp[5-9]:standby'<br>
>   # valid for streaming replicaton mode only.<br>
> allow_sql_comments = off<br>
>   # if on, ignore SQL comments when judging if load balance or<br>
>   # query cache is possible.<br>
>   # If off, SQL comments effectively prevent the judgment<br>
>   # (pre 3.4 behavior).<br>
><br>
> #------------------------------------------------------------------------------<br>
> # MASTER/SLAVE MODE<br>
> #------------------------------------------------------------------------------<br>
><br>
> master_slave_mode = on<br>
>                                    # Activate master/slave mode<br>
>                                    # (change requires restart)<br>
> master_slave_sub_mode = 'stream'<br>
>                                    # Master/slave sub mode<br>
>                                    # Valid values are combinations slony or<br>
>                                    # stream. Default is slony.<br>
>                                    # (change requires restart)<br>
><br>
> # - Streaming -<br>
><br>
> sr_check_period = 0<br>
>                                    # Streaming replication check period<br>
>                                    # Disabled (0) by default<br>
> sr_check_user = 'postgres'<br>
>                                    # Streaming replication check user<br>
>                                    # This is neccessary even if you disable<br>
> streaming<br>
>                                    # replication delay check by<br>
> sr_check_period = 0<br>
> sr_check_password = 'xxx'<br>
>                                    # Password for streaming replication<br>
> check user<br>
> delay_threshold = 0<br>
>                                    # Threshold before not dispatching query<br>
> to standby node<br>
>                                    # Unit is in bytes<br>
>                                    # Disabled (0) by default<br>
><br>
> # - Special commands -<br>
><br>
> follow_master_command = ''<br>
>                                    # Executes this command after master<br>
> failover<br>
>                                    # Special values:<br>
>                                    #   %d = node id<br>
>                                    #   %h = host name<br>
>                                    #   %p = port number<br>
>                                    #   %D = database cluster path<br>
>                                    #   %m = new master node id<br>
>                                    #   %H = hostname of the new master node<br>
>                                    #   %M = old master node id<br>
>                                    #   %P = old primary node id<br>
>   #   %r = new master port number<br>
>   #   %R = new master database cluster path<br>
>                                    #   %% = '%' character<br>
><br>
> #------------------------------------------------------------------------------<br>
> # HEALTH CHECK<br>
> #------------------------------------------------------------------------------<br>
><br>
> health_check_period = 5<br>
>                                    # Health check period<br>
>                                    # Disabled (0) by default<br>
> health_check_timeout = 0<br>
>                                    # Health check timeout<br>
>                                    # 0 means no timeout<br>
> health_check_user = 'postgres'<br>
>                                    # Health check user<br>
> health_check_password = 'xxx'<br>
>                                    # Password for health check user<br>
> health_check_max_retries = 0<br>
>                                    # Maximum number of times to retry a<br>
> failed health check before giving up.<br>
> health_check_retry_delay = 1<br>
>                                    # Amount of time to wait (in seconds)<br>
> between retries.<br>
> connect_timeout = 10000<br>
>                                    # Timeout value in milliseconds before<br>
> giving up to connect to backend.<br>
>   # Default is 10000 ms (10 second). Flaky network user may want to increase<br>
>   # the value. 0 means no timeout.<br>
>   # Note that this value is not only used for health check,<br>
>   # but also for ordinary conection to backend.<br>
><br>
> #------------------------------------------------------------------------------<br>
> # FAILOVER AND FAILBACK<br>
> #------------------------------------------------------------------------------<br>
><br>
> failover_command = '/usr/local/etc/failover.sh %d %H<br>
> /var/log/pgpool/trigger/trigger_file0'<br>
>                                    # Executes this command at failover<br>
>                                    # Special values:<br>
>                                    #   %d = node id<br>
>                                    #   %h = host name<br>
>                                    #   %p = port number<br>
>                                    #   %D = database cluster path<br>
>                                    #   %m = new master node id<br>
>                                    #   %H = hostname of the new master node<br>
>                                    #   %M = old master node id<br>
>                                    #   %P = old primary node id<br>
>   #   %r = new master port number<br>
>   #   %R = new master database cluster path<br>
>                                    #   %% = '%' character<br>
> failback_command = ''<br>
>                                    # Executes this command at failback.<br>
>                                    # Special values:<br>
>                                    #   %d = node id<br>
>                                    #   %h = host name<br>
>                                    #   %p = port number<br>
>                                    #   %D = database cluster path<br>
>                                    #   %m = new master node id<br>
>                                    #   %H = hostname of the new master node<br>
>                                    #   %M = old master node id<br>
>                                    #   %P = old primary node id<br>
>   #   %r = new master port number<br>
>   #   %R = new master database cluster path<br>
>                                    #   %% = '%' character<br>
><br>
> fail_over_on_backend_error = on<br>
>                                    # Initiates failover when<br>
> reading/writing to the<br>
>                                    # backend communication socket fails<br>
>                                    # If set to off, pgpool will report an<br>
>                                    # error and disconnect the session.<br>
><br>
> search_primary_node_timeout = 10<br>
>                                    # Timeout in seconds to search for the<br>
>                                    # primary node when a failover occurs.<br>
>                                    # 0 means no timeout, keep searching<br>
>                                    # for a primary node forever.<br>
><br>
> #------------------------------------------------------------------------------<br>
> # ONLINE RECOVERY<br>
> #------------------------------------------------------------------------------<br>
><br>
> recovery_user = 'postgres'<br>
>                                    # Online recovery user<br>
> recovery_password = 'xxx'<br>
>                                    # Online recovery password<br>
> recovery_1st_stage_command = 'recovery_1st_stage'<br>
>                                    # Executes a command in first stage<br>
> recovery_2nd_stage_command = ''<br>
>                                    # Executes a command in second stage<br>
> recovery_timeout = 90<br>
>                                    # Timeout in seconds to wait for the<br>
>                                    # recovering node's postmaster to start<br>
> up<br>
>                                    # 0 means no wait<br>
> client_idle_limit_in_recovery = 0<br>
>                                    # Client is disconnected after being idle<br>
>                                    # for that many seconds in the second<br>
> stage<br>
>                                    # of online recovery<br>
>                                    # 0 means no disconnection<br>
>                                    # -1 means immediate disconnection<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # WATCHDOG<br>
> #------------------------------------------------------------------------------<br>
><br>
> # - Enabling -<br>
><br>
> use_watchdog = on<br>
>                                     # Activates watchdog<br>
>                                     # (change requires restart)<br>
><br>
> # -Connection to up stream servers -<br>
><br>
> trusted_servers = ''<br>
>                                     # trusted server list which are used<br>
>                                     # to confirm network connection<br>
>                                     # (hostA,hostB,hostC,...)<br>
>                                     # (change requires restart)<br>
> ping_path = '/bin'<br>
>                                     # ping command path<br>
>                                     # (change requires restart)<br>
><br>
> # - Watchdog communication Settings -<br>
><br>
> wd_hostname = 'SUYSevPrepDB01'<br>
>                                     # Host name or IP address of this<br>
> watchdog<br>
>                                     # (change requires restart)<br>
> wd_port = 9000<br>
>                                     # port number for watchdog service<br>
>                                     # (change requires restart)<br>
> wd_authkey = ''<br>
>                                     # Authentication key for watchdog<br>
> communication<br>
>                                     # (change requires restart)<br>
><br>
> # - Virtual IP control Setting -<br>
><br>
> delegate_IP = '192.168.140.112'<br>
>                                     # delegate IP address<br>
>                                     # If this is empty, virtual IP never<br>
> bring up.<br>
>                                     # (change requires restart)<br>
> ifconfig_path = '/apachebin'<br>
>                                     # ifconfig command path<br>
>                                     # (change requires restart)<br>
> if_up_cmd = 'ifconfig eth1:0 inet $_IP_$ netmask 255.255.255.0'<br>
>                                     # startup delegate IP command<br>
>                                     # (change requires restart)<br>
> if_down_cmd = 'ifconfig eth1:0 down'<br>
>                                     # shutdown delegate IP command<br>
>                                     # (change requires restart)<br>
><br>
> arping_path = '/apachebin'<br>
>                                     # (change requires restart)<br>
><br>
> arping_cmd = 'arping -I  eth0 -U $_IP_$ -w 1'<br>
>                                     # arping command<br>
>                                     # (change requires restart)<br>
><br>
> # - Behaivor on escalation Setting -<br>
><br>
> clear_memqcache_on_escalation = on<br>
>                                     # Clear all the query cache on shared<br>
> memory<br>
>                                     # when standby pgpool escalate to<br>
> active pgpool<br>
>                                     # (= virtual IP holder).<br>
>                                     # This should be off if client connects<br>
> to pgpool<br>
>                                     # not using virtual IP.<br>
>                                     # (change requires restart)<br>
> wd_escalation_command = ''<br>
>                                     # Executes this command at escalation<br>
> on new active pgpool.<br>
>                                     # (change requires restart)<br>
><br>
> # - Lifecheck Setting -<br>
><br>
> # -- common --<br>
><br>
> wd_lifecheck_method = 'heartbeat'<br>
>                                     # Method of watchdog lifecheck<br>
> ('heartbeat' or 'query')<br>
>                                     # (change requires restart)<br>
> wd_interval = 3<br>
>                                     # lifecheck interval (sec) > 0<br>
>                                     # (change requires restart)<br>
><br>
> # -- heartbeat mode --<br>
><br>
> wd_heartbeat_port = 9694<br>
>                                     # Port number for receiving heartbeat<br>
> signal<br>
>                                     # (change requires restart)<br>
> wd_heartbeat_keepalive = 2<br>
>                                     # Interval time of sending heartbeat<br>
> signal (sec)<br>
>                                     # (change requires restart)<br>
> wd_heartbeat_deadtime = 30<br>
>                                     # Deadtime interval for heartbeat<br>
> signal (sec)<br>
>                                     # (change requires restart)<br>
>                                     # Host name or IP address of<br>
> destination 0<br>
>                                     # for sending heartbeat signal.<br>
>                                     # (change requires restart)<br>
>                                     # Port number of destination 0 for<br>
> sending<br>
>                                     # heartbeat signal. Usually this is the<br>
>                                     # same as wd_heartbeat_port.<br>
>                                     # (change requires restart)<br>
>                                     # Name of NIC device (such like 'eth0')<br>
>                                     # used for sending/receiving heartbeat<br>
>                                     # signal to/from destination 0.<br>
>                                     # This works only when this is not empty<br>
>                                     # and pgpool has root privilege.<br>
>                                     # (change requires restart)<br>
><br>
> #heartbeat_destination1 = 'host0_ip2'<br>
> #heartbeat_destination_port1 = 9694<br>
> #heartbeat_device1 = ''<br>
><br>
> # -- query mode --<br>
><br>
> wd_life_point = 3<br>
>                                     # lifecheck retry times<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_query = 'SELECT 1'<br>
>                                     # lifecheck query to pgpool from<br>
> watchdog<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_dbname = 'template1'<br>
>                                     # Database name connected for lifecheck<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_user = ''<br>
>                                     # watchdog user monitoring pgpools in<br>
> lifecheck<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_password = ''<br>
>                                     # Password for watchdog user in<br>
> lifecheck<br>
>                                     # (change requires restart)<br>
><br>
> # - Other pgpool Connection Settings -<br>
><br>
>                                     # Host name or IP address to connect to<br>
> for other pgpool 0<br>
>                                     # (change requires restart)<br>
>                                     # Port number for othet pgpool 0<br>
>                                     # (change requires restart)<br>
>                                     # Port number for othet watchdog 0<br>
>                                     # (change requires restart)<br>
> #other_pgpool_hostname1 = 'host1'<br>
> #other_pgpool_port1 = 5432<br>
> #other_wd_port1 = 9000<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # OTHERS<br>
> #------------------------------------------------------------------------------<br>
> relcache_expire = 0<br>
>                                    # Life time of relation cache in seconds.<br>
>                                    # 0 means no cache expiration(the<br>
> default).<br>
>                                    # The relation cache is used for cache<br>
> the<br>
>                                    # query result against PostgreSQL system<br>
>                                    # catalog to obtain various information<br>
>                                    # including table structures or if it's a<br>
>                                    # temporary table or not. The cache is<br>
>                                    # maintained in a pgpool child local<br>
> memory<br>
>                                    # and being kept as long as it survives.<br>
>                                    # If someone modify the table by using<br>
>                                    # ALTER TABLE or some such, the relcache<br>
> is<br>
>                                    # not consistent anymore.<br>
>                                    # For this purpose, cache_expiration<br>
>                                    # controls the life time of the cache.<br>
> relcache_size = 256<br>
>                                    # Number of relation cache<br>
>                                    # entry. If you see frequently:<br>
>   # "pool_search_relcache: cache replacement happend"<br>
>   # in the pgpool log, you might want to increate this number.<br>
><br>
> check_temp_table = on<br>
>                                    # If on, enable temporary table check in<br>
> SELECT statements.<br>
>                                    # This initiates queries against system<br>
> catalog of primary/master<br>
>   # thus increases load of master.<br>
>   # If you are absolutely sure that your system never uses temporary tables<br>
>   # and you want to save access to primary/master, you could turn this off.<br>
>   # Default is on.<br>
><br>
> check_unlogged_table = off<br>
>                                    # If on, enable unlogged table check in<br>
> SELECT statements.<br>
>                                    # This initiates queries against system<br>
> catalog of primary/master<br>
>                                    # thus increases load of master.<br>
>                                    # If you are absolutely sure that your<br>
> system never uses unlogged tables<br>
>                                    # and you want to save access to<br>
> primary/master, you could turn this off.<br>
>                                    # Default is on.<br>
><br>
> #------------------------------------------------------------------------------<br>
> # IN MEMORY QUERY MEMORY CACHE<br>
> #------------------------------------------------------------------------------<br>
> memory_cache_enabled = off<br>
>   # If on, use the memory cache functionality, off by default<br>
> memqcache_method = 'shmem'<br>
>   # Cache storage method. either 'shmem'(shared memory) or<br>
>   # 'memcached'. 'shmem' by default<br>
>                                    # (change requires restart)<br>
> memqcache_memcached_host = 'localhost'<br>
>   # Memcached host name or IP address. Mandatory if<br>
>   # memqcache_method = 'memcached'.<br>
>   # Defaults to localhost.<br>
>                                    # (change requires restart)<br>
> memqcache_memcached_port = 11211<br>
>   # Memcached port number. Mondatory if memqcache_method = 'memcached'.<br>
>   # Defaults to 11211.<br>
>                                    # (change requires restart)<br>
> memqcache_total_size = 67108864<br>
>   # Total memory size in bytes for storing memory cache.<br>
>   # Mandatory if memqcache_method = 'shmem'.<br>
>   # Defaults to 64MB.<br>
>                                    # (change requires restart)<br>
> memqcache_max_num_cache = 1000000<br>
>   # Total number of cache entries. Mandatory<br>
>   # if memqcache_method = 'shmem'.<br>
>   # Each cache entry consumes 48 bytes on shared memory.<br>
>   # Defaults to 1,000,000(45.8MB).<br>
>                                    # (change requires restart)<br>
> memqcache_expire = 0<br>
>   # Memory cache entry life time specified in seconds.<br>
>   # 0 means infinite life time. 0 by default.<br>
>                                    # (change requires restart)<br>
> memqcache_auto_cache_invalidation = on<br>
>   # If on, invalidation of query cache is triggered by corresponding<br>
>   # DDL/DML/DCL(and memqcache_expire).  If off, it is only triggered<br>
>   # by memqcache_expire.  on by default.<br>
>                                    # (change requires restart)<br>
> memqcache_maxcache = 409600<br>
>   # Maximum SELECT result size in bytes.<br>
>   # Must be smaller than memqcache_cache_block_size. Defaults to 400KB.<br>
>                                    # (change requires restart)<br>
> memqcache_cache_block_size = 1048576<br>
>   # Cache block size in bytes. Mandatory if memqcache_method = 'shmem'.<br>
>   # Defaults to 1MB.<br>
>                                    # (change requires restart)<br>
> memqcache_oiddir = '/var/log/pgpool/oiddir'<br>
>     # Temporary work directory to record table oids<br>
>                                    # (change requires restart)<br>
> white_memqcache_table_list = ''<br>
>                                    # Comma separated list of table names to<br>
> memcache<br>
>                                    # that don't write to database<br>
>                                    # Regexp are accepted<br>
> black_memqcache_table_list = ''<br>
>                                    # Comma separated list of table names<br>
> not to memcache<br>
>                                    # that don't write to database<br>
>                                    # Regexp are accepted<br>
> ssl_key = ''<br>
> ssl_cert = ''<br>
> ssl_ca_cert = ''<br>
> ssl_ca_cert_dir = ''<br>
> log_error_verbosity = 'DEFAULT'<br>
> client_min_messages = 'debug2'<br>
> log_min_messages = 'debug2'<br>
> backend_hostname0 = 'SUYSevPrepDB01'<br>
> backend_port0 = 5432<br>
> backend_weight0 = 1<br>
> backend_data_directory0 = '/var/lib/pgsql/9.4/data'<br>
> backend_flag0= 'ALLOW_TO_FAILOVER'<br>
> backend_hostname1 = 'SUYSevPrepDB02'<br>
> backend_port1 = 5432<br>
> backend_weight1 = 1<br>
> backend_data_directory1 = '/var/lib/pgsql/9.4/data'<br>
> backend_flag1= 'ALLOW_TO_FAILOVER'<br>
> other_pgpool_hostname0 = 'SUYSevPrepDB02'<br>
> other_pgpool_port0 = 9999<br>
> other_wd_port0 = 9000<br>
> heartbeat_destination0 = 'SUYSevPrepDB02'<br>
> heartbeat_destination_port0 = 9694<br>
> heartbeat_device0 = ''<br>
><br>
> # use another authentication method.<br>
><br>
><br>
> # TYPE  DATABASE        USER            ADDRESS                 METHOD<br>
><br>
> # "local" is for Unix domain socket connections only<br>
> local   all             all                                     md5<br>
> # IPv4 local connections:<br>
> host    all             all             <a href="http://127.0.0.1/32" rel="noreferrer" target="_blank">127.0.0.1/32</a>            md5<br>
> host    all             all             <a href="http://0.0.0.0/0" rel="noreferrer" target="_blank">0.0.0.0/0</a>               md5<br>
> # IPv6 local connections:<br>
> # Allow replication connections from localhost, by a user with the<br>
> # replication privilege.<br>
> local   replication     postgres                                trust<br>
> host    replication     replication        <a href="http://0.0.0.0/0" rel="noreferrer" target="_blank">0.0.0.0/0</a>            trust<br>
> #host    replication     postgres        ::1/128                 trust<br>
> "9.4/data/pg_hba.conf" 93L, 4422C<br>
><br>
><br>
> Slave pgpool.conf and pg_hba.conf<br>
><br>
><br>
> # ----------------------------<br>
> # pgPool-II configuration file<br>
> # ----------------------------<br>
> #<br>
> # This file consists of lines of the form:<br>
> #<br>
> #   name = value<br>
> #<br>
> # Whitespace may be used.  Comments are introduced with "#" anywhere on a<br>
> line.<br>
> # The complete list of parameter names and allowed values can be found in<br>
> the<br>
> # pgPool-II documentation.<br>
> #<br>
> # This file is read on server startup and when the server receives a SIGHUP<br>
> # signal.  If you edit the file on a running system, you have to SIGHUP the<br>
> # server for the changes to take effect, or use "pgpool reload".  Some<br>
> # parameters, which are marked below, require a server shutdown and restart<br>
> to<br>
> # take effect.<br>
> #<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # CONNECTIONS<br>
> #------------------------------------------------------------------------------<br>
><br>
> # - pgpool Connection Settings -<br>
><br>
> listen_addresses = '*'<br>
>                                    # Host name or IP address to listen on:<br>
>                                    # '*' for all, '' for no TCP/IP<br>
> connections<br>
>                                    # (change requires restart)<br>
> port = 9999<br>
>                                    # Port number<br>
>                                    # (change requires restart)<br>
> socket_dir = '/tmp'<br>
>                                    # Unix domain socket path<br>
>                                    # The Debian package defaults to<br>
>                                    # /var/run/postgresql<br>
>                                    # (change requires restart)<br>
><br>
><br>
> # - pgpool Communication Manager Connection Settings -<br>
><br>
> pcp_listen_addresses = '*'<br>
>                                    # Host name or IP address for pcp<br>
> process to listen on:<br>
>                                    # '*' for all, '' for no TCP/IP<br>
> connections<br>
>                                    # (change requires restart)<br>
> pcp_port = 9898<br>
>                                    # Port number for pcp<br>
>                                    # (change requires restart)<br>
> pcp_socket_dir = '/tmp'<br>
>                                    # Unix domain socket path for pcp<br>
>                                    # The Debian package defaults to<br>
>                                    # /var/run/postgresql<br>
>                                    # (change requires restart)<br>
> listen_backlog_multiplier = 2<br>
>                                    # Set the backlog parameter of listen(2)<br>
> to<br>
>   # num_init_children * listen_backlog_multiplier.<br>
>                                    # (change requires restart)<br>
><br>
> # - Backend Connection Settings -<br>
><br>
>                                    # Host name or IP address to connect to<br>
> for backend 0<br>
>                                    # Port number for backend 0<br>
>                                    # Weight for backend 0 (only in load<br>
> balancing mode)<br>
>                                    # Data directory for backend 0<br>
>                                    # Controls various backend behavior<br>
>                                    # ALLOW_TO_FAILOVER or<br>
> DISALLOW_TO_FAILOVER<br>
><br>
> # - Authentication -<br>
><br>
> enable_pool_hba = on<br>
>                                    # Use pool_hba.conf for client<br>
> authentication<br>
> pool_passwd = 'pool_passwd'<br>
>                                    # File name of pool_passwd for md5<br>
> authentication.<br>
>                                    # "" disables pool_passwd.<br>
>                                    # (change requires restart)<br>
> authentication_timeout = 60<br>
>                                    # Delay in seconds to complete client<br>
> authentication<br>
>                                    # 0 means no timeout.<br>
><br>
> # - SSL Connections -<br>
><br>
> ssl = off<br>
>                                    # Enable SSL support<br>
>                                    # (change requires restart)<br>
> #ssl_key = './server.key'<br>
>                                    # Path to the SSL private key file<br>
>                                    # (change requires restart)<br>
> #ssl_cert = './server.cert'<br>
>                                    # Path to the SSL public certificate file<br>
>                                    # (change requires restart)<br>
> #ssl_ca_cert = ''<br>
>                                    # Path to a single PEM format file<br>
>                                    # containing CA root certificate(s)<br>
>                                    # (change requires restart)<br>
> #ssl_ca_cert_dir = ''<br>
>                                    # Directory containing CA root<br>
> certificate(s)<br>
>                                    # (change requires restart)<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # POOLS<br>
> #------------------------------------------------------------------------------<br>
><br>
> # - Pool size -<br>
><br>
> num_init_children = 32<br>
>                                    # Number of pools<br>
>                                    # (change requires restart)<br>
> max_pool = 4<br>
>                                    # Number of connections per pool<br>
>                                    # (change requires restart)<br>
><br>
> # - Life time -<br>
><br>
> child_life_time = 300<br>
>                                    # Pool exits after being idle for this<br>
> many seconds<br>
> child_max_connections = 0<br>
>                                    # Pool exits after receiving that many<br>
> connections<br>
>                                    # 0 means no exit<br>
> connection_life_time = 0<br>
>                                    # Connection to backend closes after<br>
> being idle for this many seconds<br>
>                                    # 0 means no close<br>
> client_idle_limit = 0<br>
>                                    # Client is disconnected after being<br>
> idle for that many seconds<br>
>                                    # (even inside an explicit transactions!)<br>
>                                    # 0 means no disconnection<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # LOGS<br>
> #------------------------------------------------------------------------------<br>
><br>
> # - Where to log -<br>
><br>
> log_destination = 'syslog'<br>
>                                    # Where to log<br>
>                                    # Valid values are combinations of<br>
> stderr,<br>
>                                    # and syslog. Default to stderr.<br>
><br>
> # - What to log -<br>
><br>
> log_line_prefix = '%t: pid %p:    # printf-style string to output at<br>
> beginning of each log line.'<br>
><br>
> log_connections = off<br>
>                                    # Log connections<br>
> log_hostname = on<br>
>                                    # Hostname will be shown in ps status<br>
>                                    # and in logs if connections are logged<br>
> log_statement = on<br>
>                                    # Log all statements<br>
> log_per_node_statement = on<br>
>                                    # Log all statements<br>
>                                    # with node and backend informations<br>
> log_standby_delay = 'if_over_threshold'<br>
>                                    # Log standby delay<br>
>                                    # Valid values are combinations of<br>
> always,<br>
>                                    # if_over_threshold, none<br>
><br>
> # - Syslog specific -<br>
><br>
> syslog_facility = 'LOCAL0'<br>
>                                    # Syslog local facility. Default to<br>
> LOCAL0<br>
> syslog_ident = 'pgpool'<br>
>                                    # Syslog program identification string<br>
>                                    # Default to 'pgpool'<br>
><br>
> # - Debug -<br>
><br>
> debug_level = 2<br>
>                                    # Debug message verbosity level<br>
>                                    # 0 means no message, 1 or more mean<br>
> verbose<br>
><br>
> #log_error_verbosity = default          # terse, default, or verbose<br>
> messages<br>
><br>
> #client_min_messages = notice           # values in order of decreasing<br>
> detail:<br>
>                                         #   debug5<br>
>                                         #   debug4<br>
>                                         #   debug3<br>
>                                         #   debug2<br>
>                                         #   debug1<br>
>                                         #   log<br>
>                                         #   notice<br>
>                                         #   warning<br>
>                                         #   error<br>
><br>
> #log_min_messages = warning             # values in order of decreasing<br>
> detail:<br>
>                                         #   debug5<br>
>                                         #   debug4<br>
>                                         #   debug3<br>
>                                         #   debug2<br>
>                                         #   debug1<br>
>                                         #   info<br>
>                                         #   notice<br>
>                                         #   warning<br>
>                                         #   error<br>
>                                         #   log<br>
>                                         #   fatal<br>
>                                         #   panic<br>
><br>
> #------------------------------------------------------------------------------<br>
> # FILE LOCATIONS<br>
> #------------------------------------------------------------------------------<br>
><br>
> pid_file_name = '/var/run/pgpool/pgpool.pid'<br>
>                                    # PID file name<br>
>                                    # (change requires restart)<br>
> logdir = '/tmp'<br>
>                                    # Directory of pgPool status file<br>
>                                    # (change requires restart)<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # CONNECTION POOLING<br>
> #------------------------------------------------------------------------------<br>
><br>
> connection_cache = on<br>
>                                    # Activate connection pools<br>
>                                    # (change requires restart)<br>
><br>
>                                    # Semicolon separated list of queries<br>
>                                    # to be issued at the end of a session<br>
>                                    # The default is for 8.3 and later<br>
> reset_query_list = 'ABORT; DISCARD ALL'<br>
>                                    # The following one is for 8.2 and before<br>
> #reset_query_list = 'ABORT; RESET ALL; SET SESSION AUTHORIZATION DEFAULT'<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # REPLICATION MODE<br>
> #------------------------------------------------------------------------------<br>
><br>
> replication_mode = off<br>
>                                    # Activate replication mode<br>
>                                    # (change requires restart)<br>
> replicate_select = off<br>
>                                    # Replicate SELECT statements<br>
>                                    # when in replication mode<br>
>                                    # replicate_select is higher priority<br>
> than<br>
>                                    # load_balance_mode.<br>
><br>
> insert_lock = off<br>
>                                    # Automatically locks a dummy row or a<br>
> table<br>
>                                    # with INSERT statements to keep SERIAL<br>
> data<br>
>                                    # consistency<br>
>                                    # Without SERIAL, no lock will be issued<br>
> lobj_lock_table = ''<br>
>                                    # When rewriting lo_creat command in<br>
>                                    # replication mode, specify table name to<br>
>                                    # lock<br>
><br>
> # - Degenerate handling -<br>
><br>
> replication_stop_on_mismatch = off<br>
>                                    # On disagreement with the packet kind<br>
>                                    # sent from backend, degenerate the node<br>
>                                    # which is most likely "minority"<br>
>                                    # If off, just force to exit this session<br>
><br>
> failover_if_affected_tuples_mismatch = off<br>
>                                    # On disagreement with the number of<br>
> affected<br>
>                                    # tuples in UPDATE/DELETE queries, then<br>
>                                    # degenerate the node which is most<br>
> likely<br>
>                                    # "minority".<br>
>                                    # If off, just abort the transaction to<br>
>                                    # keep the consistency<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # LOAD BALANCING MODE<br>
> #------------------------------------------------------------------------------<br>
><br>
> load_balance_mode = on<br>
>                                    # Activate load balancing mode<br>
>                                    # (change requires restart)<br>
> ignore_leading_white_space = on<br>
>                                    # Ignore leading white spaces of each<br>
> query<br>
> white_function_list = ''<br>
>                                    # Comma separated list of function names<br>
>                                    # that don't write to database<br>
>                                    # Regexp are accepted<br>
> black_function_list = 'currval,lastval,nextval,setval'<br>
>                                    # Comma separated list of function names<br>
>                                    # that write to database<br>
>                                    # Regexp are accepted<br>
><br>
> database_redirect_preference_list = ''<br>
>   # comma separated list of pairs of database and node id.<br>
>   # example: postgres:primary,mydb[0-4]:1,mydb[5-9]:2'<br>
>   # valid for streaming replicaton mode only.<br>
><br>
> app_name_redirect_preference_list = ''<br>
>   # comma separated list of pairs of app name and node id.<br>
>   # example: 'psql:primary,myapp[0-4]:1,myapp[5-9]:standby'<br>
>   # valid for streaming replicaton mode only.<br>
> allow_sql_comments = off<br>
>   # if on, ignore SQL comments when judging if load balance or<br>
>   # query cache is possible.<br>
>   # If off, SQL comments effectively prevent the judgment<br>
>   # (pre 3.4 behavior).<br>
><br>
> #------------------------------------------------------------------------------<br>
> # MASTER/SLAVE MODE<br>
> #------------------------------------------------------------------------------<br>
><br>
> master_slave_mode = on<br>
>                                    # Activate master/slave mode<br>
>                                    # (change requires restart)<br>
> master_slave_sub_mode = 'stream'<br>
>                                    # Master/slave sub mode<br>
>                                    # Valid values are combinations slony or<br>
>                                    # stream. Default is slony.<br>
>                                    # (change requires restart)<br>
><br>
> # - Streaming -<br>
><br>
> sr_check_period = 0<br>
>                                    # Streaming replication check period<br>
>                                    # Disabled (0) by default<br>
> sr_check_user = 'postgres'<br>
>                                    # Streaming replication check user<br>
>                                    # This is neccessary even if you disable<br>
> streaming<br>
>                                    # replication delay check by<br>
> sr_check_period = 0<br>
> sr_check_password = 'xxx'<br>
>                                    # Password for streaming replication<br>
> check user<br>
> delay_threshold = 0<br>
>                                    # Threshold before not dispatching query<br>
> to standby node<br>
>                                    # Unit is in bytes<br>
>                                    # Disabled (0) by default<br>
><br>
> # - Special commands -<br>
><br>
> follow_master_command = ''<br>
>                                    # Executes this command after master<br>
> failover<br>
>                                    # Special values:<br>
>                                    #   %d = node id<br>
>                                    #   %h = host name<br>
>                                    #   %p = port number<br>
>                                    #   %D = database cluster path<br>
>                                    #   %m = new master node id<br>
>                                    #   %H = hostname of the new master node<br>
>                                    #   %M = old master node id<br>
>                                    #   %P = old primary node id<br>
>   #   %r = new master port number<br>
>   #   %R = new master database cluster path<br>
>                                    #   %% = '%' character<br>
><br>
> #------------------------------------------------------------------------------<br>
> # HEALTH CHECK<br>
> #------------------------------------------------------------------------------<br>
><br>
> health_check_period = 5<br>
>                                    # Health check period<br>
>                                    # Disabled (0) by default<br>
> health_check_timeout = 0<br>
>                                    # Health check timeout<br>
>                                    # 0 means no timeout<br>
> health_check_user = 'postgres'<br>
>                                    # Health check user<br>
> health_check_password = 'xxx'<br>
>                                    # Password for health check user<br>
> health_check_max_retries = 0<br>
>                                    # Maximum number of times to retry a<br>
> failed health check before giving up.<br>
> health_check_retry_delay = 1<br>
>                                    # Amount of time to wait (in seconds)<br>
> between retries.<br>
> connect_timeout = 10000<br>
>                                    # Timeout value in milliseconds before<br>
> giving up to connect to backend.<br>
>   # Default is 10000 ms (10 second). Flaky network user may want to increase<br>
>   # the value. 0 means no timeout.<br>
>   # Note that this value is not only used for health check,<br>
>   # but also for ordinary conection to backend.<br>
><br>
> #------------------------------------------------------------------------------<br>
> # FAILOVER AND FAILBACK<br>
> #------------------------------------------------------------------------------<br>
><br>
> failover_command = '/usr/local/etc/failover.sh %d %H<br>
> /var/log/pgpool/trigger/trigger_file0'<br>
>                                    # Executes this command at failover<br>
>                                    # Special values:<br>
>                                    #   %d = node id<br>
>                                    #   %h = host name<br>
>                                    #   %p = port number<br>
>                                    #   %D = database cluster path<br>
>                                    #   %m = new master node id<br>
>                                    #   %H = hostname of the new master node<br>
>                                    #   %M = old master node id<br>
>                                    #   %P = old primary node id<br>
>   #   %r = new master port number<br>
>   #   %R = new master database cluster path<br>
>                                    #   %% = '%' character<br>
> failback_command = ''<br>
>                                    # Executes this command at failback.<br>
>                                    # Special values:<br>
>                                    #   %d = node id<br>
>                                    #   %h = host name<br>
>                                    #   %p = port number<br>
>                                    #   %D = database cluster path<br>
>                                    #   %m = new master node id<br>
>                                    #   %H = hostname of the new master node<br>
>                                    #   %M = old master node id<br>
>                                    #   %P = old primary node id<br>
>   #   %r = new master port number<br>
>   #   %R = new master database cluster path<br>
>                                    #   %% = '%' character<br>
><br>
> fail_over_on_backend_error = on<br>
>                                    # Initiates failover when<br>
> reading/writing to the<br>
>                                    # backend communication socket fails<br>
>                                    # If set to off, pgpool will report an<br>
>                                    # error and disconnect the session.<br>
><br>
> search_primary_node_timeout = 10<br>
>                                    # Timeout in seconds to search for the<br>
>                                    # primary node when a failover occurs.<br>
>                                    # 0 means no timeout, keep searching<br>
>                                    # for a primary node forever.<br>
><br>
> #------------------------------------------------------------------------------<br>
> # ONLINE RECOVERY<br>
> #------------------------------------------------------------------------------<br>
><br>
> recovery_user = 'postgres'<br>
>                                    # Online recovery user<br>
> recovery_password = 'xxx'<br>
>                                    # Online recovery password<br>
> recovery_1st_stage_command = 'recovery_1st_stage'<br>
>                                    # Executes a command in first stage<br>
> recovery_2nd_stage_command = ''<br>
>                                    # Executes a command in second stage<br>
> recovery_timeout = 90<br>
>                                    # Timeout in seconds to wait for the<br>
>                                    # recovering node's postmaster to start<br>
> up<br>
>                                    # 0 means no wait<br>
> client_idle_limit_in_recovery = 0<br>
>                                    # Client is disconnected after being idle<br>
>                                    # for that many seconds in the second<br>
> stage<br>
>                                    # of online recovery<br>
>                                    # 0 means no disconnection<br>
>                                    # -1 means immediate disconnection<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # WATCHDOG<br>
> #------------------------------------------------------------------------------<br>
><br>
> # - Enabling -<br>
><br>
> use_watchdog = on<br>
>                                     # Activates watchdog<br>
>                                     # (change requires restart)<br>
><br>
> # -Connection to up stream servers -<br>
><br>
> trusted_servers = ''<br>
>                                     # trusted server list which are used<br>
>                                     # to confirm network connection<br>
>                                     # (hostA,hostB,hostC,...)<br>
>                                     # (change requires restart)<br>
> ping_path = '/bin'<br>
>                                     # ping command path<br>
>                                     # (change requires restart)<br>
><br>
> # - Watchdog communication Settings -<br>
><br>
> wd_hostname = 'SUYSevPrepDB02'<br>
>                                     # Host name or IP address of this<br>
> watchdog<br>
>                                     # (change requires restart)<br>
> wd_port = 9000<br>
>                                     # port number for watchdog service<br>
>                                     # (change requires restart)<br>
> wd_authkey = ''<br>
>                                     # Authentication key for watchdog<br>
> communication<br>
>                                     # (change requires restart)<br>
><br>
> # - Virtual IP control Setting -<br>
><br>
> delegate_IP = '192.168.140.112'<br>
>                                     # delegate IP address<br>
>                                     # If this is empty, virtual IP never<br>
> bring up.<br>
>                                     # (change requires restart)<br>
> ifconfig_path = '/apachebin'<br>
>                                     # ifconfig command path<br>
>                                     # (change requires restart)<br>
> if_up_cmd = 'ifconfig eth1:0 inet $_IP_$ netmask 255.255.255.0'<br>
>                                     # startup delegate IP command<br>
>                                     # (change requires restart)<br>
> if_down_cmd = 'ifconfig eth1:0 down'<br>
>                                     # shutdown delegate IP command<br>
>                                     # (change requires restart)<br>
><br>
> arping_path = '/apachebin'<br>
>                                     # (change requires restart)<br>
><br>
> arping_cmd = 'arping -I  eth0 -U $_IP_$ -w 1'<br>
>                                     # arping command<br>
>                                     # (change requires restart)<br>
><br>
> # - Behaivor on escalation Setting -<br>
><br>
> clear_memqcache_on_escalation = on<br>
>                                     # Clear all the query cache on shared<br>
> memory<br>
>                                     # when standby pgpool escalate to<br>
> active pgpool<br>
>                                     # (= virtual IP holder).<br>
>                                     # This should be off if client connects<br>
> to pgpool<br>
>                                     # not using virtual IP.<br>
>                                     # (change requires restart)<br>
> wd_escalation_command = ''<br>
>                                     # Executes this command at escalation<br>
> on new active pgpool.<br>
>                                     # (change requires restart)<br>
><br>
> # - Lifecheck Setting -<br>
><br>
> # -- common --<br>
><br>
> wd_lifecheck_method = 'heartbeat'<br>
>                                     # Method of watchdog lifecheck<br>
> ('heartbeat' or 'query')<br>
>                                     # (change requires restart)<br>
> wd_interval = 3<br>
>                                     # lifecheck interval (sec) > 0<br>
>                                     # (change requires restart)<br>
><br>
> # -- heartbeat mode --<br>
><br>
> wd_heartbeat_port = 9694<br>
>                                     # Port number for receiving heartbeat<br>
> signal<br>
>                                     # (change requires restart)<br>
> wd_heartbeat_keepalive = 2<br>
>                                     # Interval time of sending heartbeat<br>
> signal (sec)<br>
>                                     # (change requires restart)<br>
> wd_heartbeat_deadtime = 30<br>
>                                     # Deadtime interval for heartbeat<br>
> signal (sec)<br>
>                                     # (change requires restart)<br>
>                                     # Host name or IP address of<br>
> destination 0<br>
>                                     # for sending heartbeat signal.<br>
>                                     # (change requires restart)<br>
>                                     # Port number of destination 0 for<br>
> sending<br>
>                                     # heartbeat signal. Usually this is the<br>
>                                     # same as wd_heartbeat_port.<br>
>                                     # (change requires restart)<br>
>                                     # Name of NIC device (such like 'eth0')<br>
>                                     # used for sending/receiving heartbeat<br>
>                                     # signal to/from destination 0.<br>
>                                     # This works only when this is not empty<br>
>                                     # and pgpool has root privilege.<br>
>                                     # (change requires restart)<br>
><br>
> #heartbeat_destination1 = 'host0_ip2'<br>
> #heartbeat_destination_port1 = 9694<br>
> #heartbeat_device1 = ''<br>
><br>
> # -- query mode --<br>
><br>
> wd_life_point = 3<br>
>                                     # lifecheck retry times<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_query = 'SELECT 1'<br>
>                                     # lifecheck query to pgpool from<br>
> watchdog<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_dbname = 'template1'<br>
>                                     # Database name connected for lifecheck<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_user = ''<br>
>                                     # watchdog user monitoring pgpools in<br>
> lifecheck<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_password = ''<br>
>                                     # Password for watchdog user in<br>
> lifecheck<br>
>                                     # (change requires restart)<br>
><br>
> # - Other pgpool Connection Settings -<br>
><br>
>                                     # Host name or IP address to connect to<br>
> for other pgpool 0<br>
>                                     # (change requires restart)<br>
>                                     # Port number for othet pgpool 0<br>
>                                     # (change requires restart)<br>
>                                     # Port number for othet watchdog 0<br>
>                                     # (change requires restart)<br>
> #other_pgpool_hostname1 = 'host1'<br>
> #other_pgpool_port1 = 5432<br>
> #other_wd_port1 = 9000<br>
><br>
><br>
> #------------------------------------------------------------------------------<br>
> # OTHERS<br>
> #------------------------------------------------------------------------------<br>
> relcache_expire = 0<br>
>                                    # Life time of relation cache in seconds.<br>
>                                    # 0 means no cache expiration(the<br>
> default).<br>
>                                    # The relation cache is used for cache<br>
> the<br>
>                                    # query result against PostgreSQL system<br>
>                                    # catalog to obtain various information<br>
>                                    # including table structures or if it's a<br>
>                                    # temporary table or not. The cache is<br>
>                                    # maintained in a pgpool child local<br>
> memory<br>
>                                    # and being kept as long as it survives.<br>
>                                    # If someone modify the table by using<br>
>                                    # ALTER TABLE or some such, the relcache<br>
> is<br>
>                                    # not consistent anymore.<br>
>                                    # For this purpose, cache_expiration<br>
>                                    # controls the life time of the cache.<br>
> relcache_size = 256<br>
>                                    # Number of relation cache<br>
>                                    # entry. If you see frequently:<br>
>   # "pool_search_relcache: cache replacement happend"<br>
>   # in the pgpool log, you might want to increate this number.<br>
><br>
> check_temp_table = on<br>
>                                    # If on, enable temporary table check in<br>
> SELECT statements.<br>
>                                    # This initiates queries against system<br>
> catalog of primary/master<br>
>   # thus increases load of master.<br>
>   # If you are absolutely sure that your system never uses temporary tables<br>
>   # and you want to save access to primary/master, you could turn this off.<br>
>   # Default is on.<br>
><br>
> check_unlogged_table = off<br>
>                                    # If on, enable unlogged table check in<br>
> SELECT statements.<br>
>                                    # This initiates queries against system<br>
> catalog of primary/master<br>
>                                    # thus increases load of master.<br>
>                                    # If you are absolutely sure that your<br>
> system never uses unlogged tables<br>
>                                    # and you want to save access to<br>
> primary/master, you could turn this off.<br>
>                                    # Default is on.<br>
><br>
> #------------------------------------------------------------------------------<br>
> # IN MEMORY QUERY MEMORY CACHE<br>
> #------------------------------------------------------------------------------<br>
> memory_cache_enabled = off<br>
>   # If on, use the memory cache functionality, off by default<br>
> memqcache_method = 'shmem'<br>
>   # Cache storage method. either 'shmem'(shared memory) or<br>
>   # 'memcached'. 'shmem' by default<br>
>                                    # (change requires restart)<br>
> memqcache_memcached_host = 'localhost'<br>
>   # Memcached host name or IP address. Mandatory if<br>
>   # memqcache_method = 'memcached'.<br>
>   # Defaults to localhost.<br>
>                                    # (change requires restart)<br>
> memqcache_memcached_port = 11211<br>
>   # Memcached port number. Mondatory if memqcache_method = 'memcached'.<br>
>   # Defaults to 11211.<br>
>                                    # (change requires restart)<br>
> memqcache_total_size = 67108864<br>
>   # Total memory size in bytes for storing memory cache.<br>
>   # Mandatory if memqcache_method = 'shmem'.<br>
>   # Defaults to 64MB.<br>
>                                    # (change requires restart)<br>
> memqcache_max_num_cache = 1000000<br>
>   # Total number of cache entries. Mandatory<br>
>   # if memqcache_method = 'shmem'.<br>
>   # Each cache entry consumes 48 bytes on shared memory.<br>
>   # Defaults to 1,000,000(45.8MB).<br>
>                                    # (change requires restart)<br>
> memqcache_expire = 0<br>
>   # Memory cache entry life time specified in seconds.<br>
>   # 0 means infinite life time. 0 by default.<br>
>                                    # (change requires restart)<br>
> memqcache_auto_cache_invalidation = on<br>
>   # If on, invalidation of query cache is triggered by corresponding<br>
>   # DDL/DML/DCL(and memqcache_expire).  If off, it is only triggered<br>
>   # by memqcache_expire.  on by default.<br>
>                                    # (change requires restart)<br>
> memqcache_maxcache = 409600<br>
>   # Maximum SELECT result size in bytes.<br>
>   # Must be smaller than memqcache_cache_block_size. Defaults to 400KB.<br>
>                                    # (change requires restart)<br>
> memqcache_cache_block_size = 1048576<br>
>   # Cache block size in bytes. Mandatory if memqcache_method = 'shmem'.<br>
>   # Defaults to 1MB.<br>
>                                    # (change requires restart)<br>
> memqcache_oiddir = '/var/log/pgpool/oiddir'<br>
>     # Temporary work directory to record table oids<br>
>                                    # (change requires restart)<br>
> white_memqcache_table_list = ''<br>
>                                    # Comma separated list of table names to<br>
> memcache<br>
>                                    # that don't write to database<br>
>                                    # Regexp are accepted<br>
> black_memqcache_table_list = ''<br>
>                                    # Comma separated list of table names<br>
> not to memcache<br>
>                                    # that don't write to database<br>
>                                    # Regexp are accepted<br>
> ssl_key = ''<br>
> ssl_cert = ''<br>
> ssl_ca_cert = ''<br>
> ssl_ca_cert_dir = ''<br>
> log_error_verbosity = 'DEFAULT'<br>
> client_min_messages = 'notice'<br>
> log_min_messages = 'warning'<br>
> backend_hostname0 = 'SUYSevPrepDB01'<br>
> backend_port0 = 5432<br>
> backend_weight0 = 1<br>
> backend_data_directory0 = '/var/lib/pgsql/9.4/data'<br>
> backend_flag0= 'ALLOW_TO_FAILOVER'<br>
> backend_hostname1 = 'SUYSevPrepDB02'<br>
> backend_port1 = 5432<br>
> backend_weight1 = 1<br>
> backend_data_directory1 = '/var/lib/pgsql/9.4/data'<br>
> backend_flag1= 'ALLOW_TO_FAILOVER'<br>
> other_pgpool_hostname0 = 'SUYSevPrepDB01'<br>
> other_pgpool_port0 = 9999<br>
> other_wd_port0 = 9000<br>
> heartbeat_destination0 = 'SUYSevPrepDB01'<br>
> heartbeat_destination_port0 = 9694<br>
> heartbeat_device0 = ''<br>
><br>
> # TYPE  DATABASE        USER            ADDRESS                 METHOD<br>
><br>
> # "local" is for Unix domain socket connections only<br>
> local   all             all                                     md5<br>
> # IPv4 local connections:<br>
> host    all             all             <a href="http://127.0.0.1/32" rel="noreferrer" target="_blank">127.0.0.1/32</a>            md5<br>
> host    all             all             <a href="http://0.0.0.0/0" rel="noreferrer" target="_blank">0.0.0.0/0</a>               md5<br>
> # IPv6 local connections:<br>
> # Allow replication connections from localhost, by a user with the<br>
> # replication privilege.<br>
> local   replication     postgres                                trust<br>
> host    replication     replication        <a href="http://0.0.0.0/0" rel="noreferrer" target="_blank">0.0.0.0/0</a>            trust<br>
> #host    replication     postgres        ::1/128                 trust<br>
><br>
><br>
> 2016-04-07 19:31 GMT-03:00 Tatsuo Ishii <<a href="mailto:ishii@postgresql.org">ishii@postgresql.org</a>>:<br>
><br>
>> >>> *DETALLE:  message length (12) in slot 1 does not match with slot 0(8)*<br>
>><br>
>> Probably a configuration mismatch in PostgreSQL server #0 and<br>
>> PostgreSQL server #1. From reading the message above, server #0 asks<br>
>> trust authentication (no password), while server #1 requires certain<br>
>> authentication (possibly md5). Showing full pgpool.conf and<br>
>> pg_hba.conf from both PostgreSQL servers will reveal this.<br>
>><br>
>> Best regards,<br>
>> --<br>
>> Tatsuo Ishii<br>
</div></div><span class="">>> SRA OSS, Inc. Japan<br>
>> English: <a href="http://www.sraoss.co.jp/index_en.php" rel="noreferrer" target="_blank">http://www.sraoss.co.jp/index_en.php</a><br>
>> Japanese:<a href="http://www.sraoss.co.jp" rel="noreferrer" target="_blank">http://www.sraoss.co.jp</a><br>
>><br>
>> > Lucas is the same error!!!!<br>
>> ><br>
>> ><br>
>> > Apr 7 16:14:24 localhost pgpool[14839]: [40-1] 2016-04-07 16:14:24: pid<br>
</span>>> > 14839: # printf-style string to output at beginning of each log<br>
<span class="">>> line.ERROR:<br>
>> > unable to read message length<br>
>> > Apr 7 16:14:24 localhost pgpool[14839]: [40-2] 2016-04-07 16:14:24: pid<br>
>> > 14839: # printf-style string to output at beginning of each log<br>
>> > line.DETAIL: message length (12) in slot 1 does not match with slot 0<br>
>> ><br>
>> > 2016-04-07 15:52 GMT-03:00 Lucas Luengas <<a href="mailto:lucasluengas@gmail.com">lucasluengas@gmail.com</a>>:<br>
>> ><br>
>> >> Hello<br>
>> >> You can check pgpool log and postgresql log when you run that psql<br>
>> command.<br>
>> >> Regards.<br>
>> >> On Apr 6, 2016 8:30 PM, "Daniel Gallo" <<a href="mailto:danielito.gallo@gmail.com">danielito.gallo@gmail.com</a>><br>
>> wrote:<br>
>> >><br>
>> >>> Dear I'm trying to run the following and I get the following error and<br>
>> I<br>
>> >>> can not figure out what the problem is , I could help ?<br>
>> >>><br>
>> >>><br>
>> >>> Any information that need be notified me and sent them<br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>> Thanks a lots!!!!!<br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>> -bash-4.2$ psql -h localhost -U postgres -p 5432<br>
>> >>><br>
>> >>> psql (9.4.4)<br>
>> >>><br>
>> >>> Digite «help» para obtener ayuda.<br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>> postgres=#<br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>> *-bash-4.2$ psql -h localhost -U postgres -p 9999*<br>
>> >>><br>
>> >>> *psql: ERROR:  unable to read message length*<br>
>> >>><br>
</span><span class="">>> >>> *DETALLE:  message length (12) in slot 1 does not match with slot 0(8)*<br>
>> >>><br>
>> >>><br>
>> >>><br>
</span>>> >>> Any idea?<br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>> *pg_hba.conf*<br>
<span class="">>> >>><br>
>> >>><br>
>> >>><br>
>> >>> # TYPE  DATABASE        USER            ADDRESS                 METHOD<br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>> # "local" is for Unix domain socket connections only<br>
>> >>><br>
>> >>> local   all             all                                     md5<br>
>> >>><br>
>> >>> # IPv4 local connections:<br>
>> >>><br>
>> >>> host    all             all             <a href="http://127.0.0.1/32" rel="noreferrer" target="_blank">127.0.0.1/32</a>            md5<br>
>> >>><br>
>> >>> host    all             all             <a href="http://0.0.0.0/0" rel="noreferrer" target="_blank">0.0.0.0/0</a>               md5<br>
>> >>><br>
>> >>> # IPv6 local connections:<br>
>> >>><br>
>> >>> # Allow replication connections from localhost, by a user with the<br>
>> >>><br>
>> >>> # replication privilege.<br>
>> >>><br>
>> >>> local   replication     postgres                                trust<br>
>> >>><br>
>> >>> host    replication     replication        <a href="http://0.0.0.0/0" rel="noreferrer" target="_blank">0.0.0.0/0</a>            trust<br>
>> >>><br>
>> >>> #host    replication     postgres        ::1/128                 trust<br>
>> >>><br>
>> >>><br>
>> >>><br>
</span><span class="">>> >>> -rwxrw-r--. 1 apache apache 33283 abr  1 15:49 pgpool.conf<br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>> *pgpool.conf*<br>
>> >>><br>
>> >>><br>
>> >>><br>
</span><span class="">>> >>> # - Authentication -<br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>> enable_pool_hba = on<br>
>> >>><br>
>> >>>                                    # Use pool_hba.conf for client<br>
>> >>> authentication<br>
>> >>><br>
>> >>> pool_passwd = 'pool_passwd'<br>
>> >>><br>
>> >>>                                    # File name of pool_passwd for md5<br>
>> >>> authentication.<br>
>> >>><br>
>> >>>                                    # "" disables pool_passwd.<br>
>> >>><br>
>> >>>                                    # (change requires restart)<br>
>> >>><br>
>> >>> authentication_timeout = 60<br>
>> >>><br>
>> >>>                                    # Delay in seconds to complete<br>
>> client<br>
>> >>> authentication<br>
>> >>><br>
>> >>>                                    # 0 means no timeout.<br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
</span><span class="">>> >>> -rw-r--r--. 1 apache root      42 feb 29 18:28 pool_passwd<br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>> postgres:5c0435eee0f211f150e980e459151xxx<br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>><br>
>> >>> -rwxrw-r--. 1 root   root    3295 mar  3 18:19 pool_hba.conf<br>
>> >>><br>
>> >>><br>
>> >>><br>
</span>>> >>> # TYPE  DATABASE    USER        CIDR-ADDRESS          METHOD<br>
<span class="im HOEnZb">>> >>><br>
>> >>><br>
>> >>><br>
>> >>> # "local" is for Unix domain socket connections only<br>
>> >>><br>
>> >>> local   all         all                               md5<br>
>> >>><br>
>> >>> # IPv4 local connections:<br>
>> >>><br>
>> >>> host    all         all         <a href="http://127.0.0.1/32" rel="noreferrer" target="_blank">127.0.0.1/32</a>          md5<br>
>> >>><br>
>> >>> host    all         all         <a href="http://0.0.0.0/0" rel="noreferrer" target="_blank">0.0.0.0/0</a>             md5<br>
>> >>><br>
</span><div class="HOEnZb"><div class="h5">>> >>> #host    all         all         ::1/128               trust<br>
>> >>><br>
>> >>> _______________________________________________<br>
>> >>> pgpool-general mailing list<br>
>> >>> <a href="mailto:pgpool-general@pgpool.net">pgpool-general@pgpool.net</a><br>
>> >>> <a href="http://www.pgpool.net/mailman/listinfo/pgpool-general" rel="noreferrer" target="_blank">http://www.pgpool.net/mailman/listinfo/pgpool-general</a><br>
>> >>><br>
>> >>><br>
>><br>
</div></div></blockquote></div><br></div>