
1. Tổng quan:
– Môi trường thực hiện: CentOs 6.6
– Cài đặt Mysql
– Đặt mật khẩu cho tài khoản root
– Khởi động Mysql cùng hệ thống
2. Cài đặt
– Chạy lệnh cài đặt:
yum install mysql mysql-server
– Sau khi cài xong, chạy lệnh bên dưới để khởi động dịch vụ Mysql:
service mysqld start
– Đặt mật khẩu cho tài khoản root, chạy lệnh:
mysql_secure_installation Enter current password for root (enter for none): --Nhan Enter Set root password? [Y/n] --Nhan Enter New password: -- Nhap mat khau Re-enter new password: --Nhap lai mat khau Remove anonymous users? [Y/n] --Nhan Enter Disallow root login remotely? [Y/n] n --Nhap 'n' roi nhan Enter Remove test database and access to it? [Y/n] --Nhan Enter Reload privilege tables now? [Y/n] --Nhan Enter
– Cho phép dịch vụ Mysql khởi động cùng hệ thống:
chkconfig mysqld on
Hy vọng hữu ích với bạn!
Nosomovo