当前位置:网站首页>Installing MySQL under Linux
Installing MySQL under Linux
2022-07-24 11:03:00 【AscendKing】
download
http://dev.mysql.com/downloads/mysql/
Or use wget download :
wget http://dev.mysql.com/get/Downloads/MySQL-5.6/MySQL-5.6.22-1.el6.i686.rpm-bundle.tar
install
Check if it has been installed mysql
rpm -qa | grep mysql
If already installed , Unload it , Such as :
rpm -e --nodeps mysql-libs-5.1.73-5.el6_6.i686
install mysql
- mkdir /usr/local/src/mysql
- cd /usr/local/src/mysql
- tar -xvf MySQL-5.6.22-1.el6.i686.rpm-bundle.tar( If in cd /usr/local/src/mysql Decompress in the directory , Need to put MySQL-5.6.22-1.el6.i686.rpm-bundle.tar Save in cd /usr/local/src/mysql Next )
- install server rpm -ivh MySQL-server-5.6.22-1.el6.i686.rpm error : Installation dependency :yum -y install libaio.so.1 libgcc_s.so.1 libstdc++.so.6 Need to upgrade libstdc++-4.4.7-4.el6.x86_64 yum update libstdc++-4.4.7-4.el6.x86_64
If an error is reported after installation ( install mini The version will report the following error , There will be no error when installing the full version , Because these libraries have been installed in the full version )
Just install the following libraries
yum install -y perl-Module-Install.noarch
- Installing :
- install client rpm -ivh MySQL-client-5.6.22-1.el6.i686.rpm
Installation dependency :yum -y install libncurses.so.5 libtinfo.so.5
- Inquire about mysq Service running status service mysql status Service not started .
- start-up mysql service service mysql start
- Use root To login mysql –uroot –p( This password needs vi /root/.mysql_secret see ) Tips : In the installation mysql server There is a hint : Be careful : This password is not secure , All need to change the initial password .
- Log in with password mysql account number :mysql -uroot -p
- modify root password ( Here is an example , Set the password to 123456)
SET PASSWORD = PASSWORD('123456');
Automatically start when the system starts mysql service
Add to system services :
chkconfig --add mysql
Auto start :
chkconfig mysql on
Query list :
chkconfig
explain : It's not closed (off) There is no automatic start .
Turn on Remote Access
Sign in :
mysql -uroot -p123456
Set up remote access ( Use root password ):
grant all privileges on *.* to 'root' @'%' identified by '123456';
flush privileges;
Firewall on 3306 port
/sbin/iptables -I INPUT -p tcp --dport 3306 -j ACCEPT
/etc/rc.d/init.d/iptables save
/etc/init.d/iptables status
边栏推荐
猜你喜欢

Signal processing: < three > DFT and FFT

Docker installs 3 master and 3 slave redis clusters

cookie sessionStorage localStorage 区别

View the source code of idea Download

浅析拉格朗日乘数法及其对偶问题

Hongmeng's first note

2018 arXiv | Objective-Reinforced Generative Adversarial Networks (ORGAN) for Sequence Generation Mo

Simply use MySQL index

Taking advantage of the momentum, oceanbase promotes the lean growth of digital payment

QT create application tray and related functions
随机推荐
[live registration] analysis of location cache module and detailed explanation of OCP monitoring and alarm
Zero basic learning canoe panel (9) -- combobox
[FPGA]: IP core -- xadc
Take care of me when I meet you for the first time
Cross platform audio playback Library
Simply use MySQL index
Five network IO models
UNIX C language POSIX thread creation, obtaining thread ID, merging thread, separating thread, terminating thread, thread comparison
Zero basic learning canoe panel (7) -- file selection (pathdiaglog)
[FPGA]: IP core -- rapid IO
Golang Li Kou leetcode 494. goals and
对话ACE第四期:分布式数据库未来发展的挑战和机遇
Redismission inventory deduction demo
"Low power Bluetooth module" master-slave integrated Bluetooth sniffer - help smart door lock
STM32+ESP8266+MQTT协议连接阿里云物联网平台
Idea hidden Idea folder hides.Iml files
Artifact ffmpeg - operation video, extremely comfortable
小熊派学习——内核开发
Detailed explanation and example demonstration of Modbus RTU communication protocol
How to gracefully realize idempotency and distributed current limiting of distributed interfaces (glory Collection Edition)