Centos 7 mysql 安装记
Posted 快乐无限
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Centos 7 mysql 安装记相关的知识,希望对你有一定的参考价值。
自从某次在美团云把1G 1核的 centos 7 装到死机,我就断了源码编译安装mysql的心思。
本次实践历程如下
- 安装命令
wget http://dev.mysql.com/get/mysql-community-release-el7-5.noarch.rpm rpm -ivh mysql-community-release-el7-5.noarch.rpm yum install mysql-community-server
- 配置mysql
service mysqld restart mysql -u root mysql> set password for ‘root‘@‘localhost‘ =password(‘vm_52.102‘);
[[email protected]alhost liuhui]# service mysqld restart Redirecting to /bin/systemctl restart mysqld.service [[email protected] liuhui]# mysql -u root Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 2 Server version: 5.6.34 MySQL Community Server (GPL) 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> set password for ‘root‘@‘localhost‘ =password(‘password‘); Query OK, 0 rows affected (0.00 sec)
以上是关于Centos 7 mysql 安装记的主要内容,如果未能解决你的问题,请参考以下文章