[Pgpool-general] Error in Master/Slave Replication

Ole Wendland ole.wendland at werum.de
Tue Nov 9 11:35:10 UTC 2010


Hi
you were right with the standby server (at least it seemed so), because 
now I get different error-messages. :D

Now I got one step back and try to follow the tutorial as closely as 
possible, but some how I still have problems to connect to the clients.

This is the error messages, especially the first debug messages is quite 
strange, because as you can see in the config files, ssl should be 
turned of.

2010-11-09     11:13:33     DEBUG:     pid     14942:     pool_ssl: SSL 
requested but SSL support is not available
2010-11-09     11:13:33     DEBUG:     pid     14942:     s_do_auth: 
auth kind: 0
2010-11-09     11:13:33     ERROR:     pid     14942:     s_do_auth: 
unknown response "E" before processing BackendKeyData
2010-11-09     11:13:33     DEBUG:     pid     14908:     health_check: 
1 th DB node status: 1
2010-11-09     11:13:33     ERROR:     pid     14942:     s_do_auth: 
unknown response "" before processing BackendKeyData
2010-11-09     11:13:33     ERROR:     pid     14942:     s_do_auth: 
unknown response "" before processing BackendKeyData
2010-11-09     11:13:33     ERROR:     pid     14942:     s_do_auth: 
unknown response "_" before processing BackendKeyData
2010-11-09     11:13:33     DEBUG:     pid     14942:     s_do_auth: 
parameter status data received
2010-11-09     11:13:33     ERROR:     pid     14942:     pool_read2: 
EOF encountered with backend
2010-11-09     11:13:33     ERROR:     pid     14942:     
make_persistent_db_connection: s_do_auth failed

Has anybody encounted a likewise problem.

Another thing that bothers me is that the install-functions.sh try to 
install following functions.

cd ../pgpool-walrecvrunning
make
make install
psql -f pgpool-walrecvrunning.sql template1

But there is no just thing like pgpool-walrecvrunning, not in the 
pgpool-II-3.0.1 and also not in pgpool-II-3.1.0-alpha, does anybody 
knows what that is about?

Below I posted the hole configuration.

Greetings Ole

General settings:
Redhat 5.5
postgres 9.0.1
pgpool-II-3.0.1
pgpoolAdmin-3.0.2


PgPool Configuration:

pgpool.conf:

#
# pgpool-II configuration file sample
# $Header: 
/cvsroot/pgpool/pgpool-web/contrib_docs/simple_sr_setting/pgpool.conf,v 
1.1 2010/11/04 04:39:57 t-ishii Exp $

listen_addresses = '*'
port = 9999
pcp_port = 9898
socket_dir = '/tmp'
pcp_socket_dir = '/tmp'
backend_socket_dir = '/tmp'
pcp_timeout = 10
num_init_children = 32
max_pool = 4
child_life_time = 0
connection_life_time = 0
child_max_connections = 0
client_idle_limit = 0
authentication_timeout = 60
logdir = '/var/log/pgpool'
pid_file_name = '/var/run/pgpool/pgpool.pid'
replication_mode = false
load_balance_mode = true
replication_stop_on_mismatch = false
failover_if_affected_tuples_mismatch = true
replicate_select = false
reset_query_list = 'ABORT;DISCARD ALL'
white_function_list = ''
black_function_list = 'nextval,setval,foo'
print_timestamp = true
master_slave_mode = true
master_slave_sub_mode = 'stream'
delay_threshold = 100
log_standby_delay = 'if_over_threshold'
connection_cache = true
health_check_timeout = 10
health_check_period = 10
health_check_user = 'apache'
failover_command = '/usr/local/etc/failover.sh %d "%h" %p %D %m %M "%H" %P'
failback_command = '/bin/rm -f /tmp/trigger_file1'
fail_over_on_backend_error = false
insert_lock = true
ignore_leading_white_space = false
log_statement = false
log_per_node_statement = true
log_connections = false
log_hostname = false
parallel_mode = false
enable_query_cache = false
pgpool2_hostname = ''
system_db_hostname = 'localhost'
system_db_port = 5432
system_db_dbname = 'pgpool'
system_db_schema = 'pgpool_catalog'
system_db_user = 'pgpool'
system_db_password = ''
enable_pool_hba = true
pool_passwd = 'pool_passwd'
recovery_user = 'postgres'
recovery_password = 'pgpoolAdmin'
recovery_1st_stage_command = 'basebackup.sh'
recovery_2nd_stage_command = ''
recovery_timeout = 60
client_idle_limit_in_recovery = 0
lobj_lock_table = 'pgpool_lobj_lock'
ssl = false
debug_level = 3
replication_timeout = 5000
log_statement = false
backend_hostname0 = ''
backend_port0 = 5432
backend_weight0 = 1
backend_data_directory0 = '/home/postgres/data'
backend_hostname1 = ''
backend_port1 = 5433
backend_weight1 = 1
backend_data_directory1 = '/home/postgres/standby'


pool_hba.conf:

# TYPE  DATABASE    USER        CIDR-ADDRESS          METHOD

# "local" is for Unix domain socket connections only
host    all    all    172.20.0.0/16            trust
host    all    all    10.56.253.0/24        trust
host     all    all    192.168.1.0/24         trust
local   all         all                          trust
# IPv4 local connections:
host    all         all         127.0.0.1/32         trust

# IPv6 local connections:
host    all         all         ::1/128              trust


Postgres Config

postgresql.conf
listen_addresses = '*'
port = 5432
max_connections = 100
shared_buffers = 32MB
wal_level = hot_standby
archive_mode = on
archive_command = 'date >&2 && echo did dummy archiving for %f >&2 '
max_wal_senders = 1
hot_standby = on
log_destination = 'stderr'
logging_collector = on
log_directory = 'pg_log'
log_filename = 'postgresql-%a.log'
log_truncate_on_rotation = on
log_rotation_age = 1d
log_rotation_size = 0
datestyle = 'iso, dmy'
client_encoding = unicode
lc_messages = 'de_DE.UTF.-8'
lc_monetary = 'de_DE.UTF.-8'
lc_numeric = 'de_DE.UTF.-8'
lc_time = 'de_DE.UTF.-8'
default_text_search_config = 'pg_catalog.german'
listen_addresses = '*'
port = 5432
max_connections = 100
shared_buffers = 32MB
wal_level = hot_standby
archive_mode = on
archive_command = 'date >&2 && echo did dummy archiving for %f >&2 '
max_wal_senders = 1
hot_standby = on
log_destination = 'stderr'
logging_collector = on
log_directory = 'pg_log'
log_filename = 'postgresql-%a.log'
log_truncate_on_rotation = on
log_rotation_age = 1d
log_rotation_size = 0
datestyle = 'iso, dmy'
client_encoding = unicode
lc_messages = 'de_DE.UTF.-8'
lc_monetary = 'de_DE.UTF.-8'
lc_numeric = 'de_DE.UTF.-8'
lc_time = 'de_DE.UTF.-8'
default_text_search_config = 'pg_catalog.german'


pghba.conf:

# TYPE  DATABASE    USER        CIDR-ADDRESS          METHOD

# "local" is for Unix domain socket connections only
host    all    all    172.20.0.0/16            trust
host    all    all    10.56.253.0/24        trust
host     all    all        192.168.1.0/24 trust
local   all             all                                      trust
# IPv4 local connections:
host    all             all             127.0.0.1/32            trust
# IPv6 local connections:
host    all             all             ::1/128                  trust
#host   replication      postgres         0.0.0.0/0                trust
local   replication      postgres                                trust


Am 07.11.2010 10:12, schrieb Tatsuo Ishii:
>> Hi guys,
>> I try to setup a Master/Slave replication via streaming. If I activate
>> replication without Master/Slave everything works fine, but in the
>> Master/Slave mode it is somehow messed up. I always get this one error
>> and I have no idea where to look, at the master postgres side, master
>> pgpool side or somewhere at the slave. Has anybody seen something like
>> this?
>>
>> "2010-11-04 16:11:59 ERROR: pid 3339: check_replication_time_lag:
>> SELECT pg_last_xlog_receive_location() returns no data"
> The error indicates that your standby server (192.168.1.3) is not
> configured properly as a standby server. Are you sure that it's
> running as a standby server?
> --
> Tatsuo Ishii
> SRA OSS, Inc. Japan
> English: http://www.sraoss.co.jp/index_en.php
> Japanese: http://www.sraoss.co.jp
> _______________________________________________
> Pgpool-general mailing list
> Pgpool-general at pgfoundry.org
> http://pgfoundry.org/mailman/listinfo/pgpool-general


-- 
Ole Wendland, Dipl.-Ing. (FH) M. Sc.
Software Engineer
CIS (Communication&  Information Systems)
Werum Software&  Systems AG
Wulf-Werum-Straße 3 | 21337 Lüneburg
Tel. +49(0)4131/8900-393 | Fax +49(0)4131/8900-20
mailto:ole.wendland at werum.de | http://www.werum.de

USt-ID-Nr. DE 116 083 850 | RG Lüneburg HRB 2262
Vorsitzender des Aufsichtsrats: Johannes Zimmermann
Vorstand: Hartmut Krome, Rüdiger Schlierenkämper, Hans-Peter Subel



More information about the Pgpool-general mailing list