1, the configuration of MySQL at startup
-
chkconfig -- add mysql
-
chkconfig mysqld on
2, the command enable / disable MySQL instance
-
service mysqld start/stop
-
/etc/init.d/mysqld start/stop
3, ordered the closure of MySQL
mysqladmin -p -u root shutdown
4, check whether the real start mysql
Method One: query port
#netstat -tulpn
MySQL monitor TCP port 3306 is the last line of the figure that is the result of the operation command MySQL service in operation.
Method Two: query process
ps -ef | grep mysqld
If there are two processes mysqld_safe and mysqld, indicating that MySQL service is currently in start-up state.