当前位置:网站首页>day10--install mysql on linux
day10--install mysql on linux
2022-07-30 03:45:00 【Ning Mang】
1. Download the installation package and upload it to linux
2. Create a new directory mysql in the /usr/local directory
1) Enter /usr/local
Command: cd /usr/local
2) Create a directory
Command: mkdir mysql
3. Unzip the mysql installation package
1) Enter the installation path of the mysql installation package
Command: cd /home/xqy
2) Unzip the installation package to /usr/local/mysql
Command: tar -xvf MySQL-5.6.22-1.el6.i686.rpm-bundle.tar -C /usr/local/mysql
4. Install mysql under /usr/local/mysql
1) Install the server side: rpm -ivh MySQL-server-5.6.22-1.el6.i686.rpm
2) Install the client: rpm -ivh MySQL-client-5.6.22-1.el6.i686.rpm
5. Start mysql
Command: service mysql start
6. Add mysql to the system service and set the startup to start
Command: chkconfig --add mysql Add to system service
Command: chkconfig mysql on autostart
7. Login to mysql
1) After mysql is installed, a temporary random password will be generated, which is stored in /root/.mysql_secret
Command: cat /root/.mysql_secret View file content

2) Log in to mysql
Command: msyql –u root -p
3) Modify mysql password
Command: set password = password('root');
4) Open mysql remote login
By default, mysql does not support remote login to mysql for security reasons, so you need to set the permission to enable remote login to mysql
Command : grant all privileges on *.* to 'root' @'%' identified by 'root';
Flush privileges;
5) Open Linux port 3306 for external access
Enter the command in the linux environment:
/sbin/iptables -I INPUT -p tcp --dport 3306 -j ACCEPT
/etc/rc.d/init.d/iptables save to permanently save changes to the firewall
边栏推荐
- Record NLP various resource URLs
- Basic introduction to protect the network operations
- 26 basic models in 6 categories that operators must master
- 小程序毕设作品之微信二手交易小程序毕业设计成品(3)后台功能
- NLP Natural Language Processing (1)
- 小程序毕设作品之微信积分商城小程序毕业设计成品(8)毕业设计论文模板
- Mini Program Graduation Works WeChat Second-hand Trading Mini Program Graduation Design Finished Works (3) Background Functions
- sql中 exists的用法
- Nacos命名空间
- Nacos service registration and discovery
猜你喜欢

写给技术人的管理入门知识1:什么是管理

Answer these 3 interview questions correctly, and the salary will go up by 20K

CDH/CDP 是什么?

Nacos实现高可用

小程序毕设作品之微信积分商城小程序毕业设计成品(6)开题答辩PPT

Hystrix 服务熔断

Organizations Going Online: A New Trend in Organizational Digital Transformation
![[C Supplement] Conversion of Integer to String](/img/61/4261ea9bf3001dfa8deed424fce145.jpg)
[C Supplement] Conversion of Integer to String

LoadBalancer 负载均衡

Is the snowflake the same question?
随机推荐
curl命令获取外网ip
Monitor page deployment
WPF递归获取窗体中指定控件类型列表
The most important transport layer
小程序毕设作品之微信二手交易小程序毕业设计成品(7)中期检查报告
监控页面部署
EasyNVR平台级联到EasyCVR,视频播放一会就无法播放是什么原因?
flutter 记录学习不一样的动画(一)
Wechat second-hand transaction small program graduation design finished product (1) Development overview
小程序毕设作品之微信二手交易小程序毕业设计成品(5)任务书
sublime text 3 设置
Nacos 安装与部署
【Node访问MongoDB数据库】
对均匀采样信号进行重采样
【Use of scientific research tools】A
Nacos Configuration Center
HCIP experiment (05) OSPF comprehensive experiment
2022-07-29 第四小组 修身课 学习笔记(every day)
小程序毕设作品之微信积分商城小程序毕业设计成品(2)小程序功能
BindingExpression path error: ‘selectMenusList‘ property not found on ‘object‘ ‘‘ViewModel“