Linux serverNETWORK ADMINISTRATIONS

Mysql installation on centos 7

Step 1 : Need to Download rpm package
wget https://dev.mysql.com/get/mysql57-community-release-el7-9.noarch.rpm

Step 2 : Check Contact or what is Present of the inside file
rpm -qplp mysql57-community-release-el7-9.noarch.rpm
Step 3: add the rpm file in your system
rpm -ivh mysql57-community-release-el7-9.noarch.rpm
Step 4 : Install MySql
yum install -y mysql-server

Step 5 : start mySql Server
[root@localhost Desktop]# systemctl status mysqld
[root@localhost Desktop]# systemctl start mysqld
[root@localhost Desktop]# systemctl status mysqld

Step 6 : generate the temporary Password
[root@localhost Desktop]# sudo grep ‘temporary password’ /var/log/mysqld.log
[root@localhost Desktop]# systemctl restart mysqld
Step 7: validate password policy
[root@localhost Desktop]# vim /etc/my.cnf
[root@localhost Desktop]# systemctl restart mysqld

Step 9 :
[root@localhost Desktop]# mysql_secure_installation

Step 10 : Go inside MySql
[root@localhost Desktop]# mysql -uroot -p
Step 11 : create database
mysql# show databases;
mysql# create database India;
mysql# show databases;
mysql# use india
mysql# show tables;
mysql# use mysql
mysql# show tables;

source

centos 7