Linux上查看mysql的启动

吃可爱长大的小学妹 提交于 2020-02-12 13:26:02

一、linux下查看mysql服务的两种方式:

方式一:

[root@localhost bin]ps -ef|grep mysql

方式二:

[root@localhost bin]netstat -nlp

 

 

 

二、linux下启动mysql服务的两种方式:

命令行方式:

[root@localhost bin]cd /usr/bin
[root@localhost bin]./mysqld_safe &

服务方式:

  • [root@localhost ~]service mysql start
  • 如果服务在启动状态,直接重启服务用以下命令:
  • [root@localhost ~]service mysql restart

三、linux下关闭mysql服务的两种方式:

命令行方式:

[root@localhost ~]mysqladmin -u root shutdown

服务方式:

[root@localhost ~]service mysql stop
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!