replication slave disconnects often

replication slave disconnects often

am 26.09.2006 02:37:46 von noident

Greetings!
We have a few master/slave mysql server pairs.
The problem is that the slave disconnects often from the master.
Of course, it reconnects straight away, so if you don't go looking for
it, you may easily miss the problem.
However, executing "show processlist" on the master shows that the
slave comes up with a different Id all the time.
Of course, I didn't forget to assign different server-id's to master
and slave.
There is no problem on the network, as is evident from this snoop log:
slave -> master TCP D=3306 S=32897 Ack=626414592 Seq=1800482976 Len=0
Win=49640
master -> slave TCP D=32897 S=3306 Push Ack=1800482976 Seq=626414592
Len=150 Win=49640
slave -> master TCP D=3306 S=32897 Ack=626414742 Seq=1800482976 Len=0
Win=49640
master -> slave TCP D=32897 S=3306 Push Ack=1800482976 Seq=626414742
Len=133 Win=49640
slave -> master TCP D=3306 S=32897 Ack=626414875 Seq=1800482976 Len=0
Win=49640
slave -> master TCP D=3306 S=32897 Fin Ack=626414875 Seq=1800482976
Len=0 Win=49640
The slave just closes connection, and then reconnects. For no apparent
reason. Nothing in the logs (with log_warnings=1) on either slave or
master.
Almost all our slave/master pairs have this problem.

This is run on Solaris 10 sparc
Mysql versions - tried different ones for slave and master with no luck
- versions from 5.0.12 to 5.0.24a, downloaded from the mysql site.

Googling yields nothing on the subject.
Has anyone seen anything similar?
Tnak you.

Re: replication slave disconnects often

am 26.09.2006 10:42:11 von Nandakishore

could you send me my.cnf
check wait_timeout

if proble persists use salve_updates =1

noident@my-deja.com wrote:
> Greetings!
> We have a few master/slave mysql server pairs.
> The problem is that the slave disconnects often from the master.
> Of course, it reconnects straight away, so if you don't go looking for
> it, you may easily miss the problem.
> However, executing "show processlist" on the master shows that the
> slave comes up with a different Id all the time.
> Of course, I didn't forget to assign different server-id's to master
> and slave.
> There is no problem on the network, as is evident from this snoop log:
> slave -> master TCP D=3306 S=32897 Ack=626414592 Seq=1800482976 Len=0
> Win=49640
> master -> slave TCP D=32897 S=3306 Push Ack=1800482976 Seq=626414592
> Len=150 Win=49640
> slave -> master TCP D=3306 S=32897 Ack=626414742 Seq=1800482976 Len=0
> Win=49640
> master -> slave TCP D=32897 S=3306 Push Ack=1800482976 Seq=626414742
> Len=133 Win=49640
> slave -> master TCP D=3306 S=32897 Ack=626414875 Seq=1800482976 Len=0
> Win=49640
> slave -> master TCP D=3306 S=32897 Fin Ack=626414875 Seq=1800482976
> Len=0 Win=49640
> The slave just closes connection, and then reconnects. For no apparent
> reason. Nothing in the logs (with log_warnings=1) on either slave or
> master.
> Almost all our slave/master pairs have this problem.
>
> This is run on Solaris 10 sparc
> Mysql versions - tried different ones for slave and master with no luck
> - versions from 5.0.12 to 5.0.24a, downloaded from the mysql site.
>
> Googling yields nothing on the subject.
> Has anyone seen anything similar?
> Tnak you.

Re: replication slave disconnects often

am 27.09.2006 01:36:41 von noident

Nandakishore wrote:

> could you send me my.cnf
> check wait_timeout

This is the master's my.cnf:
[mysqld]
skip-locking
read_buffer = 1M
read_rnd_buffer = 1M
key_buffer = 512M
max_allowed_packet = 16M
table_cache = 512
sort_buffer = 1M
myisam_sort_buffer_size = 128M
thread_cache = 8
thread_concurrency = 8
max_connections = 5000
log-bin = master-bin
server-id = 1
query_cache_limit = 1M
query_cache_size = 64M
query_cache_type = 1
skip-bdb
skip-external-locking
log-slow-queries
long_query_time = 5
interactive_timeout = 172800
wait_timeout = 172800



And this is the slave's:

[mysqld]
skip-locking
read_buffer = 1M
read_rnd_buffer = 1M
key_buffer = 512M
max_allowed_packet = 16M
table_cache = 512
sort_buffer = 1M
myisam_sort_buffer_size = 128M
thread_cache = 8
thread_concurrency = 8
max_connections = 300
# we have a reason for enabling log-bin on the slave, shouldn't break
anything
log-bin = slave-bin
server-id = 2
binlog-do-db=MY_DB
log-slave-updates
query_cache_limit = 1M
query_cache_size = 64M
query_cache_type = 1
skip-bdb
skip-external-locking
log-slow-queries
long_query_time = 5
interactive_timeout = 172800
wait_timeout = 172800


Cheers