- Installation
- Server installation. Use command: sudo yum-y install Mysql-server
- Client Installation. Use command: sudo yum-y install MySQL
- Set boot up
- Sudo/sbin/chkconfig--add mysqld
- Sudo/sbin/chkconfig mysqld on
- Sudo/sbin/service mysqld Start
- Set Root password
- sudo mysqladmin-u root password ' test123 '
- Connect to MySQL
- Mysql-u root-p test123
- Modify root Remote access permissions
- Close mysqld Service: Sudo/sbin/service mysqld stop
- Safe Mode login: sudo mysqld_safe--user=mysql--skip-grant-tables--skip-networking &
- Execute current permission Query command: show grants; (This step is optional)
- Add Permission: Grant all privileges on *. * to ' root ' @ ' * ' identified by ' 123456 ' with Grant option;
- Refresh Permissions table: Flush privileges;
- Exit Mysql:quit
- Restart MySQL service: Sudo/sbin/service mysqld start
- Iptables Open 3306 Service:
#/sbin/iptables-i input-p TCP--dport 3306-j ACCEPT
#/etc/rc.d/init.d/iptables Save:
# Service Iptables Restart restart effective
- Or shut down the firewall: sudo service iptables stop
- Connect using a remote DB tool such as Navicat
- Creating databases: Create Database XXX;
- Enter the database: use XXX;
Linux system installation MySQL and related configuration