1、修改my.ini 如果只存在my-default.ini,则新建一个my.ini 添加datadir=要迁移的目录 2、重启mysql服务 转载于:https://www.cnblogs.com/pltang/p/8965834.html