mysql-cluster配置时,启动管理器:
sudo ndb_mgmd -f /var/lib/mysql-cluster/config.ini --initial
遇到以下错误:
Couldn’t start as daemon, error: ‘Failed to lock pidfile ‘/var/lib/mysql-cluster/ndb_1.pid’, already locked by pid=1195, errno: 11’
解决办法:
进入mysql-cluster文件夹查看文件
cd /var/lib/mysql-cluster
ls
发现有ndb_1.pid文件
删除该文件即可:
sudo rm -rf ndb_1.pid
重新启动管理器:
sudo ndb_mgmd -f /var/lib/mysql-cluster/config.ini --initial