Guang Bao, Zhen Xing, hello.
> Hi Alfranio, Andrei,
> Thanks for your reviewing work.
> But after fixed BUG#41613, Jasonh believes it's not a bug now.
I think bug#30703 is a an issue of incompatibility, but it might be
superceeded by bug#41613. There is a reason to make the three states
to report for IO thread, and that makes bug#30703 an active again.
The tree states in show slave status was discussed ago with some
people on #support who accepted the idea.
Guang Bao, Zhen Xing, I think you need to speak to #support people and act in
consensus with them according to the two items:
- if the 3 states for IO in show slave status is acceptable indeed
- whether SHOW STATUS LIKE 'Slave_running' would report the binary,
and then which of the two binaries:
1) NO, YES (IO thread is started but not connected, the current pre-bug30703)
2) NO, YES (IO thread is connected)
or we would need to reflex the new IO 3 states in
the SHOW STATUS LIKE 'SLAVE_RUNNING'
I personally would be content with the binary 2 (which confirms
bug#30703 is a bug).
> So don't need to push this patch into bugteam tree.
> Explanation about this is on comment of the bug.
> How do you think?
> Best wishes,
> Alfranio Correia Wrote:
>> Patch approved.
>> However, before pushing please fix test rpl.rpl_row_colSize.
>> The patch makes it fail.
>> Guangbao Ni wrote:
>>> #At file:///home/ngb/mysql/bzr/bug30703-6.0-bugteam/
>>> 3101 Guangbao Ni 2009-03-04
>>> Bug #30703 SHOW STATUS LIKE 'Slave_running' is not compatible with
> `SHOW SLAVE STATUS'
>>> SHOW SHOW STATUS LIKE 'Slave_running' command believes
>>> that if active_mi->slave_running != 0, then io thread is
>>> running normally.
>>> But it isn't so in fact. When some errors happen to make io
>>> thread try to reconnect master, then it will become
>>> transitional status (MYSQL_SLAVE_RUN_NOT_CONNECT == 1), which
>>> also doesn't equal 0.
>>> Yet, "SHOW SLAVE STATUS" believes that only if
>>> active_mi->slave_running == MYSQL_SLAVE_RUN_CONNECT, then io thread
>>> is running.
>>> So "SHOW SLAVE STATUS" can get the correct result.
>>> Fixed to make SHOW SHOW STATUS LIKE
>>> Slave_running' command have the same check condition
>>> with "SHOW SLAVE STATUS". It only believe that the io thread
>>> is running when active_mi->slave_running ==
>>> per-file messages:
>>> Fixed to make SHOW SHOW STATUS LIKE 'Slave_running' command have the same
> check condition
>>> with "SHOW SLAVE STATUS". It only believe that the io thread is
>>> running when active_mi->slave_running ==
>>> === modified file 'sql/mysqld.cc'
>>> --- a/sql/mysqld.cc 2009-02-25 08:58:28 +0000
>>> +++ b/sql/mysqld.cc 2009-03-04 17:28:42 +0000
>>> @@ -7369,7 +7369,8 @@ static int show_slave_running(THD *thd,
>>> var->type= SHOW_MY_BOOL;
>>> var->value= buff;
>>> - *((my_bool *)buff)= (my_bool) (active_mi &&
> active_mi->slave_running &&
>>> + *((my_bool *)buff)= (my_bool) (active_mi && +
>>> active_mi->slave_running == MYSQL_SLAVE_RUN_CONNECT &&
>>> return 0;