>Description:
        Replication master updates it's binary log based on current database, 
        not on tables being updated. This leads to replication problems
        if not all your databases on the server are replicated.
>How-To-Repeat:
        Prerequisites:
        Two databases created, (test1 and test2), 
        tables "test1.test" and "test2.test2" created
        with the following operator (without quotes):
        "create table <name>(x integer);"
        Replication setup:
        log-bin
        sql-bin-update-same
        binlog-do-db    = test1
        server-id       = 1

        Demostration(Log with unnecessary lines(like "1 row in set") cut):
---log start---
mysql> show master status;
| File          | Position | Binlog_do_db | Binlog_ignore_db |
| homer-bin.002 | 131      | test1        |                  |
mysql> insert into test values(1);
mysql> show master status;
| File          | Position | Binlog_do_db | Binlog_ignore_db |
| homer-bin.002 | 187      | test1        |                  |
mysql> select * from test;
+------+
| x    |
+------+
|    1 |
+------+
mysql> use test2
Database changed
mysql> insert into test1.test values(2);
Query OK, 1 row affected (0.00 sec)
mysql> show master status;
| File          | Position | Binlog_do_db | Binlog_ignore_db |
| homer-bin.002 | 187      | test1        |                  |
mysql> select * from test1.test;
+------+
| x    |
+------+
|    1 |
|    2 |
+------+

mysql> use test1
mysql> insert into test2.test2 values(1);
mysql> show master status;
| File          | Position | Binlog_do_db | Binlog_ignore_db |
+---------------+----------+--------------+------------------+
| homer-bin.002 | 250      | test1        |                  |

---log end---

>Fix:
        The only visible workaround is emitting "use xxxx", "use yyyy" before
        every statement, or using different DB handles, one per db.

>Submitter-Id:  <submitter ID>
>Originator:    root
>Organization:
 SWsoft
>MySQL support: [none]
>Synopsis:      Replication problem: master's binary log updates incorrectly.
>Severity:      serious
>Priority:      
>Category:      mysql
>Class:         sw-bug
>Release:       mysql-3.23.37 (Official MySQL binary)

>Environment:
        
System: Linux ovir 2.2.14-5.0.14csmp #1 SMP Wed May 31 09:23:37 PDT 2000 i686 unknown
Architecture: i686

Some paths:  /usr/bin/perl /usr/bin/make /usr/bin/gmake /usr/bin/gcc /usr/bin/cc
GCC: Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/specs
gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)
Compilation info: CC='gcc'  CFLAGS='-O3 -mpentium '  CXX='gcc'  CXXFLAGS='-O3 
-mpentium  -felide-constructors'  LDFLAGS='-static'
LIBC: 
lrwxrwxrwx    1 root     root           13 Jun  9  2000 /lib/libc.so.6 -> libc-2.1.3.so
-rwxr-xr-x    1 root     root      4101324 Feb 29  2000 /lib/libc-2.1.3.so
-rw-r--r--    1 root     root     20272704 Feb 29  2000 /usr/lib/libc.a
-rw-r--r--    1 root     root          178 Feb 29  2000 /usr/lib/libc.so
Configure command: ./configure  --prefix=/usr/local/mysql '--with-comment=Official 
MySQL binary' --with-extra-charsets=complex --enable-assembler 
--with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --disable-shared
Perl: This is perl, version 5.005_03 built for i386-linux

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to