当前位置:网站首页>[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
边栏推荐
- Interesting! Database is also serverless!
- 优质笔记软件综合评测和详细盘点(一) Notion、Obsidian、RemNote、FlowUs
- Arduino Stepper库驱动28BYJ-48步进电机测试程序
- Modsim basic use (Modbus simulator)
- 8K HDR!|为 Chromium 实现 HEVC 硬解 - 原理/实测指南
- EasyCVR通过国标GB28181协议接入设备,出现设备自动拉流是什么原因?
- 上大学后明白了哪些坑人的事?
- STC 32-bit 8051 single chip microcomputer development example tutorial II i/o working mode and its configuration
-
- Leetcode 1380 lucky numbers in matrix [array] the leetcode path of heroding
猜你喜欢

Arduino stepper library drive 28byj-48 stepper motor test program

Related concepts of cookies and sessions

优质笔记软件综合评测和详细盘点(一) Notion、Obsidian、RemNote、FlowUs

On the next generation entrance of the metauniverse -- the implementation of brain computer interface

Use Zadig to build a continuous delivery platform from 0 to 1

Optimization of the problem that the request flow fails to terminate during page switching of easycvr cluster video Plaza

使用Zadig从0到1搭建持续交付平台

运动捕捉系统原理
![[untitled]](/img/6c/df2ebb3e39d1e47b8dd74cfdddbb06.gif)
[untitled]

有意思了!数据库也搞Serverless!
随机推荐
SQL getting started plan-1-select
Procédure de mesure du capteur d'accord vibrant par le module d'acquisition d'accord vibrant
Set object value changes null value object
【蓝桥杯Web】2022年第十三届蓝桥杯Web大学组国赛真题解析
Using win7 vulnerability to crack the system login password
C#联合halcon应用——大华相机采集类
Error in installing sharp
STC 32-bit 8051 single chip microcomputer development example tutorial II i/o working mode and its configuration
基于图的 Affinity Propagation 聚类计算公式详解和代码示例
STC 32位8051单片机开发实例教程 二 I/O工作模式及其配置
How to turn off the boot auto start software in win11
[untitled]
[C language] explain the usage of memset() function in detail
关于元宇宙下一代入口——脑机接口的实现
P2433 [deep foundation 1-2] primary school mathematics n in one
墨天轮沙龙 | 清华乔嘉林:Apache IoTDB,源于清华,建设开源生态之路
windows环境 redis安装和启动(后台启动)
C#聯合halcon應用——大華相機采集類
DS transunet: Dual Swing transformer u-net for medical image segmentation