Dear users,<br><br>I have 3 backend, and one balancer, this is config of my balancer:<br><br>listen_addresses = '*'<br>port = 5433<br>socket_dir = '/tmp'<br>pcp_port = 9898<br>pcp_socket_dir = '/tmp'<br>
backend_hostname0 = '10.2.141.54'<br>backend_port0 = 5432<br>backend_weight0 = 0.499<br>backend_data_directory0 = '/var/lib/postgresql/9.1/main'<br>backend_hostname1 = '10.2.141.55'<br>backend_port1 = 5432<br>
backend_weight1 = 0.499<br>backend_data_directory1 = '/var/lib/postgresql/9.1/main'<br>backend_hostname2 = '10.2.141.53'<br>backend_port2 = 5432<br>backend_weight2 = 0.002<br>backend_data_directory2 = '/var/lib/postgresql/9.1/main'<br>
enable_pool_hba = off<br>authentication_timeout = 60<br>ssl = off<br>num_init_children = 120<br>max_pool = 2<br>child_life_time = 64800<br>child_max_connections = 1000<br>connection_life_time = 300<br>client_idle_limit = 64800<br>
log_destination = 'stderr'<br>print_timestamp = on<br>log_connections = off<br>log_hostname = on<br>log_statement = off<br>log_per_node_statement = off<br>log_standby_delay = 'if_over_threshold'<br>syslog_facility = 'LOCAL0'<br>
syslog_ident = 'pgpool'<br>debug_level = 0<br>pid_file_name = '/var/run/pgpool/pgpool.pid'<br>logdir = '/tmp'<br>connection_cache = on<br>reset_query_list = 'ABORT; DISCARD ALL'<br>replication_mode = off<br>
replicate_select = off<br>insert_lock = off<br>lobj_lock_table = ''<br>replication_stop_on_mismatch = off<br>failover_if_affected_tuples_mismatch = off<br>load_balance_mode = on<br>ignore_leading_white_space = on<br>
white_function_list = ''<br>black_function_list = 'nextval,setval'<br>master_slave_mode = on<br>master_slave_sub_mode = 'stream'<br>sr_check_period = 10<br>sr_check_user = 'sr_check'<br>sr_check_password = 'sr_check1'<br>
delay_threshold = 100<br>follow_master_command = '/etc/pgpool.d/follow_master_command.sh %d %h %p %D %m %H %M %P'<br>parallel_mode = off<br>enable_query_cache = off<br>pgpool2_hostname = ''<br>system_db_hostnameš = 'localhost'<br>
system_db_port = 5432<br>system_db_dbname = 'pgpool'<br>system_db_schema = 'pgpool_catalog'<br>system_db_user = 'pgpool'<br>system_db_password = ''<br>health_check_period = 5<br>health_check_timeout = 20<br>
health_check_user = 'health_check'<br>health_check_password = 'health_check1'<br>failover_command = '/etc/pgpool.d/failover.sh %d %h %p %D %m %H %M %P'<br>failback_command = '/etc/pgpool.d/failback_command.sh %d %h %p %D %m %H %M %P'<br>
fail_over_on_backend_error = on<br>recovery_user = 'postgres'<br>recovery_password = 'postgres'<br>recovery_1st_stage_command = 'copy_base_backup'<br>recovery_2nd_stage_command = ''<br>recovery_timeout = 90<br>
client_idle_limit_in_recovery = 0<br>relcache_expire = 5<br><br>Client use PgAdmin to connect to pool and sometimes DML go to the slave server, and i see this error in pgpool.log:<br><br>2012-03-28 14:48:41 ERROR: pid 18767: read_kind_from_backend: 0 th kind C does not match with master or majority connection kind E<br>
2012-03-28 14:48:41 ERROR: pid 18767: kind mismatch among backends. Possible last query was: "set role muvi;<br>/* Newsletter subject and body templates with boundaries imposed by body markup */<br>CREATE TABLE NewsletterTemplate (<br>
š newsletter_template_uid uuid DEFAULT uuid_generate_v1() NOT NULL, /* Template id */<br><br>š subject_template_path varchar (255) NOT NULL,šššššššššššššššššššš /* Unique name of message subject velocity template */<br>š body_template_path varchar (255) NOT NULL,ššššššššššššššššššššššš /* Unique name of message body velocity template */<br>
<br>š free_content text,ššššššššššššššššššššššššššššššššššššššššššššššš /* Free text content */<br><br>š /* Limits of how many digest items of each type can fit into template body */<br>š recent_friends_limit integer DEFAULT 0 NOT NULL,ššššššššššššššššš /* Recent friends limit */<br>
š recommendations_limit integer DEFAULT 0 NOT NULLššššššššššššššššš /* Recommendations limit */<br>);<br><br>COMMENT ON TABLE NewsletterTemplate<br>ššš IS 'Newsletter subject and body templates with boundaries imposed by body markup'<br>
;<br>COMMENT ON COLUMN NewsletterTemplate.newsletter_template_uid<br>ššš IS " kind details are: 0[C] 1[E: cannot execute CREATE TABLE in a read-only transaction] 2[E: cannot execute CREATE TABLE in a read-only transaction]<br>
2012-03-28 14:48:41 LOG:šš pid 18767: do_child: exits with status 1 due to error<br><br clear="all"><br>Replication is <span class="Bold"> organize by native Postgresql streaming replication. My version Postgresql - 9.1.3 and my version pgpool-II version 3.1.2<br>
<br></span>-- <br>σ ΥΧΑΦΕΞΙΕΝ σΕΜΡΧΛΑ εΧΗΕΞΙΚ<br>