Bug #102307 [ERROR] Slave I/O for channel '': error connecting to master
Submitted: 20 Jan 2021 7:08 Modified: 21 Jan 2021 16:43
Reporter: Ankit Kumar Email Updates:
Status: Not a Bug Impact on me:
None 
Category:MySQL Server Severity:S2 (Serious)
Version:5.7.27-30 OS:CentOS
Assigned to: MySQL Verification Team CPU Architecture:Any

[20 Jan 2021 7:08] Ankit Kumar
Description:
Hi Team,

 

We are facing a strange issue with MySQL server(5.7.27-30-log). when we are setting up replication using dns it is throwing error:

[ERROR] Slave I/O for channel '': error connecting to master 'replication@mydomainname.dc.lan:3306' - retry-time: 20 retries: 4, Error_code: 2005
while we are able to nslookup and ping the dns name from console:

[root@dc-db20 ~]# nslookup 10.26.50.11
11.50.26.10.in-addr.arpa name = dc-db10.dc.lan.
[root@dc-db20 ~]# host dc-db10.dc.lan
dc-db10.dc.lan has address 10.26.50.11
 

How to repeat:
NA
[20 Jan 2021 7:48] Frederic Descamps
Hi Ankit, 

Did you try to connect from the console of that server with the MySQL Client ? (mysql) like :

mysql -u replication -p -h mydomainname.dc.lan

Thank you.
[20 Jan 2021 8:27] Ankit Kumar
Yes, We are able to connect Remote MySQL on dc-db10.dc.lan from client.
[21 Jan 2021 16:43] MySQL Verification Team
Hi Ankit,

We're sorry, but the bug system is not the appropriate forum for asking help on using MySQL products. Your problem is not the result of a bug.

For details on getting support for MySQL products see http://www.mysql.com/support/
You can also check our forums (free) at http://forums.mysql.com/

With regards to your problem, check your hosts file on both servers, check resolv.conf on both servers and if resolv.conf points to proper dns server, check if that dns server returns proper reply (use dig @thatdnsserver) and finally check skip-name-resolve in your config files on both servers. Also make sure your user is properly created on the master and that from that server you can connect using that user.

Thanks in your interest in MySQL 
in good health
Bogdan