当前位置:网站首页>[mysql] install mysql5.7
[mysql] install mysql5.7
2022-07-01 20:04:00 【just-do-it-zzj】
Catalog
2. Download installation package
install Mysql5.7
1. summary
This experiment is used in Linux7.6 install mysql5.7, For personal learning Mysql Basic function , The production environment may not be suitable .
2. Download installation package
mysql-community-client-5.7.18-1.el7.x86_64.rpm
mysql-community-common-5.7.18-1.el7.x86_64.rpm
mysql-community-libs-5.7.18-1.el7.x86_64.rpm
mysql-community-server-5.7.18-1.el7.x86_64.rpm
3. Check before installation
explain : If the installation fails or needs to be reinstalled Mysql, You can also refer to the following execution steps .
3.1 Check if it is installed mysql
rpm -qa | grep mysql
If the result is returned , Then execute the delete command , Delete package
rpm -e mysql-xxx
3.2 Check for installation mariadb
rpm -qa | grep mariadb # Find out if it comes with mariadb library
If the result is returned , Then execute the delete command , Delete package
rpm -e mariadbxxx --nodeps # Delete
3.3 Check if there is Mysql Related configuration files
find / -name mysql # Find and mysql Related files or folders
If the result is returned , Then execute the delete command one by one
rm –rf /xxx/xxx/mysql # Delete and mysql Relevant files or folders
rm -rf /etc/my.cnf # Delete profile
4. install Mysql
rpm When installing , There are four bags , The installation sequence is as follows :common—>lib—>client—>server,
Unload in reverse order . The following two parameters are not required in the installation :—force –nodeps, Otherwise, you may make mistakes and don't notice , Instead, the installation failed .
Installation sequence ( Strictly follow the order ):
rpm -ivh mysql-community-common-5.7.18-1.el7.x86_64.rpm
rpm -ivh mysql-community-libs-5.7.18-1.el7.x86_64.rpm
rpm -ivh mysql-community-client-5.7.18-1.el7.x86_64.rpm
rpm -ivh mysql-community-server-5.7.18-1.el7.x86_64.rpm
5. start-up Mysql
5.1 start-up
systemctl start mysqld.service
5.2 Set up mysql The service is startup
systemctl enable mysqld
6. Login and setup
6.1 Query initial password
You need to find the initial password before logging in for the first time after installation , Execute the following command to find the initial password
cat /var/log/mysqld.log | grep password
6.2 Sign in
mysql -uroot -p< password >
6.3 Set the password
You need to change your password after logging in for the first time , Execute the following command to change the password
Mode one :
set password for [email protected]=password('[email protected]');
Mode two :
set password = password('[email protected]');
alter user 'root'@'localhost' password expire never;
flush privileges;
7. common problem
7.1 rpm Abuse parameters during installation --nodeps
Incorrect installation sequence . such as mysql-libs The installation of requires mysql-common For the premise , If not installed mysql-common when , install mysql-libs It's time —nodeps, No error will be prompted , But there are actually problems
边栏推荐
- Difference between redo and undo
- Procédure de mesure du capteur d'accord vibrant par le module d'acquisition d'accord vibrant
- [research data] observation on the differences of health preservation concepts among people in 2022 - Download attached
- Error in installing sharp
- Arduino Stepper库驱动28BYJ-48步进电机测试程序
- Problems encountered in installing MySQL in docker Ubuntu container
- P2433 [deep foundation 1-2] primary school mathematics n in one
- 人脸识别系统 —— OpenCV人脸检测
- Bind this of the current scope for callback functions in other cases such as timers and delayers
- Tensorflow reports an error, could not load dynamic library 'libcudnn so. eight
猜你喜欢
随机推荐
走进如心小镇,数智化变革连接“未来社区”
Getting started with fastdfs
一个程序员如何快速成长
February 15, 2022: sweeping robot. There is a floor sweeping robot in the room (represented by a grid). Each grid in the grid has two possibilities: empty and obstacles. The sweeping robot provides fo
大厂做狼,小厂做狗?
Interesting! Database is also serverless!
#yyds干货盘点#SQL聚合查询方法总结
fastDFS入门
上大学后明白了哪些坑人的事?
使用Zadig从0到1搭建持续交付平台
How can a programmer grow rapidly
Detailed configuration of network security "Splunk" in national vocational college skills competition
Win11暂停更新点不了怎么办?Win11暂停更新是灰色的如何解决?
3D全景模型展示可视化技术演示
Difference between redo and undo
internship:复杂json格式数据编写接口
List is divided into sets that meet and do not meet conditions (partitioningby)
STC 32位8051单片机开发实例教程 三 程序编译设置与下载
Win11 how to hide the taskbar? Win11 method to hide the taskbar
internship:逐渐迈向项目开发