DM部署完,全量+增量同步报错,parse mydumper metadata error: EOF

Hi,可以帮助我们排查下,在增加权限前(比如临时回滚一下),SHOW GRANTS的输出是什么吗。我们暂时无法复现这个问题

好的,谢谢

在没有增加权限之前,创建数据源的时候无法创建成功,报以下错误信息,后来执行了以下两条SQL语句才可以创建数据源

给账号添加replication slave权限

grant replication slave on . to ‘zhangsan’@‘10.8.114.91’;

设置binlog数据复制模式

set global binlog_format=ROW;

SHOW GRANTS 的输出是什么,当时没注意到这个输出

以下是报错的屏幕打印日志信息:
[root@10-8-4-117 soft]# tiup dmctl --master-addr 10.8.114.91:8261 operate-source create /data/soft/source-mysql-mediamz.yaml
Starting component dmctl : /root/.tiup/components/dmctl/v2.0.0/dmctl/dmctl --master-addr 10.8.114.91:8261 operate-source create /data/soft/source-mysql-mediamz.yaml
{
“result”: false,
“msg”: “[code=10001:class=database:scope=upstream:level=high], Message: database driver error, RawCause: Error 1227: Access denied; you need (at least one of) the REPLICATION SLAVE privilege(s) for this operation, Workaround: Please check the database connection and the database config in configuration file.”,
“sources”: [
]
}

经过这两天试用DM同步组件,感觉缺陷问题还是挺多的,到现在还没解决数据初始化问题

是指的手动运行一下show grants看看输出

show grants for ‘miaoyamin’@‘host’;

root@localhost|mysql>show grants for ‘zhangsan’@‘10.8.114.91’;
±-----------------------------------------------------------------------------------+
| Grants for zhangsan@10.8.114.91 |
±-----------------------------------------------------------------------------------+
| GRANT RELOAD, REPLICATION SLAVE ON . TO zhangsan@10.8.114.91 |
| GRANT ALL PRIVILEGES ON mediamz.* TO zhangsan@10.8.114.91 WITH GRANT OPTION |
±-----------------------------------------------------------------------------------+
2 rows in set (0.00 sec)

突然想起来了,当时还报了另外一个错误,提示缺少reload权限,下面两条命令都执行过才可以添加数据源

grant replication slave on . to ‘zhangsan’@‘10.8.114.91’;

grant reload on . to ‘zhangsan’@‘10.8.114.91’;

感谢,我们试一下 :pray:

在source配置中的用户是miaoyamin,host也不同,可以看一下这个用户的show grants

就是这个,我不想暴露真实的用户名,发帖时特意改成了zhangsan

root@localhost|mysql>show grants for ‘miaoyamin’@‘host’;
ERROR 1141 (42000): There is no such grant defined for user ‘‘miaoyamin’’ on host ‘‘host’’
root@localhost|mysql>show grants for ‘miaoyamin’@‘10.8.114.91’;
ERROR 1141 (42000): There is no such grant defined for user ‘‘miaoyamin’’ on host ‘‘10.8.114.91’’
root@localhost|mysql>show grants for ‘miaoyamin’@‘10.8.114.91’;
±-----------------------------------------------------------------------------------+
| Grants for miaoyamin@10.8.114.91 |
±-----------------------------------------------------------------------------------+
| GRANT RELOAD, REPLICATION SLAVE ON . TO miaoyamin@10.8.114.91 |
| GRANT ALL PRIVILEGES ON mediamz.* TO miaoyamin@10.8.114.91 WITH GRANT OPTION |
±-----------------------------------------------------------------------------------+
2 rows in set (0.00 sec)

哦哦收到,可以删除