Bug #10780 slave can't connect to master - IO and SQL threads running
Submitted: 20 May 2005 22:09 Modified: 17 Aug 2005 19:08
Reporter: Sergey Frolovichev Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Replication Severity:S3 (Non-critical)
Version:4.1.11-standard OS:Linux (SuSe 9.3)
Assigned to: Bugs System CPU Architecture:Any

[20 May 2005 22:09] Sergey Frolovichev
Description:
I have forgot to give access right from slave to master and...
It was always in state - connectiong to master, write a lot of errors to log file but both slave IO and SQL threads are okey and there is no errors about ca't connect in "show slave status". So this state seems to be can't be monitoried by standart sql quesry, i have just to check mysql log file. I don't mind on this, but may be this comes to be a simple unmonitoried situation...

How to repeat:
Just close access to slave on master and see "show slave status" there will be no messages about this error...
[26 May 2005 14:32] MySQL Verification Team
Hello Sergey,

I tested your bug report and got the following in the SHOW SLAVE STATUS output:

           Slave_IO_Running: No
          Slave_SQL_Running: Yes

that is expected.

WRT errors and error codes, SHOW SLAVE STATUS reports only errors that happen due to execution of a query on the slave, all other errors are written to the error log.

If you want you can change "Severity" to "Feature request" otherwise I set this bug report to "Not a bug".
[29 May 2005 8:41] Sergey Frolovichev
mysql> show slave status\G
*************************** 1. row ***************************
             Slave_IO_State: Connecting to master
                Master_Host: 10.0.0.41
                Master_User: replication
                Master_Port: 3306
              Connect_Retry: 60
            Master_Log_File: db-bin.000026
        Read_Master_Log_Pos: 227641216
             Relay_Log_File: voicedb01-relay-bin.000027
              Relay_Log_Pos: 84352535
      Relay_Master_Log_File: db-bin.000026
           Slave_IO_Running: Yes
          Slave_SQL_Running: Yes
            Replicate_Do_DB: 
        Replicate_Ignore_DB: 
         Replicate_Do_Table: Monamour2.RegionNames,Monamour2.CityNames,Monamour2.PhoneOperators,Monamour2.CityCodes,Monamour2.TZ,Monamour2.CountryNames,Monamour2.Partner,Monamour2.CountryCodes,Monamour2.Region,Monamour2.City,Monamour2.Language,Monamour2.Country
     Replicate_Ignore_Table: 
    Replicate_Wild_Do_Table: 
Replicate_Wild_Ignore_Table: 
                 Last_Errno: 0
                 Last_Error: 
               Skip_Counter: 0
        Exec_Master_Log_Pos: 220978275
            Relay_Log_Space: 91015476
            Until_Condition: None
             Until_Log_File: 
              Until_Log_Pos: 0
         Master_SSL_Allowed: No
         Master_SSL_CA_File: 
         Master_SSL_CA_Path: 
            Master_SSL_Cert: 
          Master_SSL_Cipher: 
             Master_SSL_Key: 
      Seconds_Behind_Master: NULL
1 row in set (0.00 sec)
[29 May 2005 8:45] Sergey Frolovichev
mysql> show slave status\G    
*************************** 1. row ***************************
             Slave_IO_State: Connecting to master
                Master_Host: 10.0.0.41
                Master_User: replication
                Master_Port: 3306
              Connect_Retry: 60
            Master_Log_File: db-bin.000026
        Read_Master_Log_Pos: 233883289
             Relay_Log_File: dbs4-relay-bin.000029
              Relay_Log_Pos: 193652945
      Relay_Master_Log_File: db-bin.000026
           Slave_IO_Running: Yes
          Slave_SQL_Running: Yes
            Replicate_Do_DB: 
        Replicate_Ignore_DB: 
         Replicate_Do_Table: Monamour2.AnketaNamesSelf,Monamour2.AnketaNamesDescr,Monamour2.TZCity,Monamour2.AnketaNames,Monamour2.TZ,Monamour2.AnketaCounter,Monamour2.Friend,Monamour2.CityNames,Monamour2.User,Monamour2.CountryNames,Rating2.PhotoAll,Monamour2.Photo,Monamour2.Country,Monamour2.Language,Rating2.Rating,Monamour2.MetroNames,Monamour2.TZCountry,Monamour2.Partner,Monamour2.PhotoNames,Monamour2.City,Rating2.RatingNames,Monamour2.MetroEquals,Monamour2.Meet,Monamour2.Metro,Monamour2.Region,Monamour2.Anketa,Monamour2.MetroShort,Monamour2.RegionNames,Monamour2.TZRegion,Monamour2.PhotoFolder,Rating2.RatingPartners,Monamour2.UserOptions,Monamour2.PhotoFolderNames,Monamour2.MetroMiddle
     Replicate_Ignore_Table: 
    Replicate_Wild_Do_Table: 
Replicate_Wild_Ignore_Table: 
                 Last_Errno: 0
                 Last_Error: 
               Skip_Counter: 0
        Exec_Master_Log_Pos: 233883289
            Relay_Log_Space: 1267394840
            Until_Condition: None
             Until_Log_File: 
              Until_Log_Pos: 0
         Master_SSL_Allowed: No
         Master_SSL_CA_File: 
         Master_SSL_CA_Path: 
            Master_SSL_Cert: 
          Master_SSL_Cipher: 
             Master_SSL_Key: 
      Seconds_Behind_Master: NULL
1 row in set (0.00 sec)
[29 May 2005 8:52] Sergey Frolovichev
Lets make in another way this test?
1. I have on master special user, password and host for slave to access on master.
2. I have fully working slave + master working on do-table option!
3. On master i'm deleting user and making flush privileges;
4. On slave i'm running stop slave;start slave;
On both 4.1.12 & 4.1.11 I receive a message which I posted in previus messages :-(
[6 Jun 2005 16:36] MySQL Verification Team
Verified with latest 4.1 bk tree.
SHOW SLAVE STATUS shows wrong slave IO status.
[30 Jul 2005 3:00] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/internals/27737
[17 Aug 2005 17:59] Paul DuBois
We need the three-part version number for the
version to which the patch was applied, in order to
write a changelog entry.  Reverting to Patch Pending
status.  Please supply the version number and set
to Documenting status again. Thanks.

A short description of the problem that was fixed
would be helpful as well. :-)
[17 Aug 2005 18:32] Alexander Pachev
Fixed in version 4.1.14 and 5.0.12. The problem was that the slave I/O thread was considering in the running state from the time it was launched. I have changed this definition to count it as running only after it has successfully connected to the master.
[17 Aug 2005 19:08] Paul DuBois
Noted in 4.1.14, 5.0.12 changelogs.