1 启动mysql服务:Service mysql start
再次启动:service mysql restart
停止mysql服务:service mysql stop
确定mysql是否启动成功:sudo netstat -tap | grep mysql
2 查看mysql的状态
service mysql status 或者systemctl status mysql.service
3 Ubuntu下的mysql的配置文件存放位置是两个:
(1) /etc/mysql/my.cnf
(2) /etc/my.cnf
4 查看mysql进程: ps -e |grep mysql