9.配置环境变量(添加下面两条)
[root@chufeng yusen]# vim /etc/profile export MYSQL_HOME="/usr/local/mysql" export PATH="$PATH:$MYSQL_HOME/bin" **#加载环境变量** [root@chufeng yusen]# source /etc/profile
10.将mysql启动文件添加到系统启动文件中
[root@chufeng yusen]# cd /usr/local/mysql/ [root@chufeng mysql]# cp support-files/mysql.server /etc/init.d/mysql
11.mysql的 启动 停止 及 重启命令
启动mysql服务
[root@chufeng yusen]# systemctl start mysql
重启mysql服务
[root@chufeng yusen]# systemctl restart mysql
停止mysql服务
[root@chufeng yusen]# systemctl stop mysql
开机自启
[root@chufeng yusen]# systemctl enable mysql
或者:
启动mysql服务
[root@chufeng yusen]# service mysql start
重启mysql服务
[root@chufeng yusen]# service mysql restart
停止mysql服务
[root@chufeng yusen]# service mysql stop
将服务添加到开机启动指令管理的服务列表中
chkconfig --add mysql
开机自启
chkconfig mysql on
12.修改mysql密码
[root@chufeng yusen]# mysqladmin -u root password New password: Confirm new password: [root@chufeng yusen]#
13.连接 Mysql
[root@chufeng yusen]# mysql -u root -p Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 2 Server version: 5.6.40 Source distribution Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql>
在此mysql-5.6.40源码安装就完成了
总结
以上所述是小编给大家介绍的CentOs7 64位 mysql 5.6.40源码安装过程,希望对大家有所帮助,如果大家有任何疑问请给我留言,小编会及时回复大家的。在此也非常感谢大家对网站的支持!
如果你觉得本文对你有帮助,欢迎转载,烦请注明出处,谢谢!
更多Mysql内容来自木庄网络博客
标签:Mysql
相关阅读 >>
更多相关阅读请进入《mysql》频道 >>

数据库系统概念 第6版
本书主要讲述了数据模型、基于对象的数据库和XML、数据存储和查询、事务管理、体系结构等方面的内容。