Create a mysql replication from multiple master and single slave server?
You need to modify the master and relay repositories to be stored into tables and then define channels for each master.

STOP SLAVE;
SET GLOBAL master_info_repository = 'TABLE';
SET GLOBAL relay_log_info_repository = 'TABLE';

CHANGE MASTER TO MASTER_HOST='master1', MASTER_USER='rpl', MASTER_PORT=3451, MASTER_PASSWORD='' \
MASTER_LOG_FILE='master1-bin.000006', MASTER_LOG_POS=628 FOR CHANNEL 'master-1';


Refer: https://dev.mysql.com/doc/refman/5.7/en/replication-multi-source.html