Mysql Installation in Linux can be done in many ways like rpm, yum, docker, repository etc. Today in this article we will learn how to install MySQL in Linux through tarball and rpm utility.
Table of Contents
Please follow the below instructions step by step to install mysql in Linux :
1.Go to the website: MySQL Tarball Download for Linux Redhat 7 and click on Download the tarball for installing MySQL 8.0.35. It will take some time as the size is 981M.
2. Go to your Downloads folder once the download is finished:
3. Copy this file to the server into any location like below . Here we have copied in mountpoint /u01/mysql1.
4. Untar it and you will get all the extracted files as below :
tar -xvf mysql-8.0.35-1.el7.x86_64.rpm-bundle.tar
5. Now we have to install the necessary rpms through the rpm utility. We need the below rpms to be installed :
mysql-community-common-8.0.35-1.el7.x86_64.rpm
mysql-community-client-plugins-8.0.35-1.el7.x86_64.rpm
mysql-community-libs-8.0.35-1.el7.x86_64.rpm
mysql-community-libs-compat-8.0.35-1.el7.x86_64.rpm
mysql-community-client-8.0.35-1.el7.x86_64.rpm
mysql-community-icu-data-files-8.0.35-1.el7.x86_64.rpm
mysql-community-server-8.0.35-1.el7.x86_64.rpm
[root@vm3 mysql]# rpm -ivh mysql-community-common-8.0.35-1.el7.x86_64.rpm
warning: mysql-community-common-8.0.35-1.el7.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID 3a79bd29: NOKEY
Preparing... ################################# [100%]
Updating / installing...
1:mysql-community-common-8.0.35-1.e################################# [100%]
[root@vm3 mysql]# rpm -ivh mysql-community-client-plugins-8.0.35-1.el7.x86_64.rpm
warning: mysql-community-client-plugins-8.0.35-1.el7.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID 3a79bd29: NOKEY
Preparing... ################################# [100%]
Updating / installing...
1:mysql-community-client-plugins-8.################################# [100%]
[root@vm3 mysql]# rpm -ivh mysql-community-libs-8.0.35-1.el7.x86_64.rpm
warning: mysql-community-libs-8.0.35-1.el7.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID 3a79bd29: NOKEY
Preparing... ################################# [100%]
Updating / installing...
1:mysql-community-libs-8.0.35-1.el7################################# [100%]
[root@vm3 mysql]# rpm -ivh mysql-community-libs-compat-8.0.35-1.el7.x86_64.rpm
warning: mysql-community-libs-compat-8.0.35-1.el7.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID 3a79bd29: NOKEY
Preparing... ################################# [100%]
Updating / installing...
1:mysql-community-libs-compat-8.0.3################################# [100%]
[root@vm3 mysql]# rpm -ivh mysql-community-client-8.0.35-1.el7.x86_64.rpm
warning: mysql-community-client-8.0.35-1.el7.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID 3a79bd29: NOKEY
Preparing... ################################# [100%]
Updating / installing...
1:mysql-community-client-8.0.35-1.e################################# [100%]
[root@vm3 mysql]# rpm -ivh mysql-community-icu-data-files-8.0.35-1.el7.x86_64.rpm
warning: mysql-community-icu-data-files-8.0.35-1.el7.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID 3a79bd29: NOKEY
Preparing... ################################# [100%]
package mysql-community-icu-data-files-8.0.35-1.el7.x86_64 is already installed
[root@vm3 mysql]# rpm -ivh mysql-community-server-8.0.35-1.el7.x86_64.rpm
warning: mysql-community-server-8.0.35-1.el7.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID 3a79bd29: NOKEY
Preparing... ################################# [100%]
Updating / installing...
1:mysql-community-server-8.0.35-1.e################################# [100%]
6. Now start mysqld service by issuing below command :
systemctl start mysqld
Congratulations!! You have successfully installed MySQL in your Server. Now check the status and start it. So it is active and running.
In the next article, we will see how to log in to MySQL database after the first Installation!!
Pingback: Error: Failed dependencies:mariadb-libs is obsoleted by mysql-community-libs
Pingback: How to Login to MySQL database after the first Installation
Pingback: Basic MySQL Commands for DBA:
Pingback: Mysql Asynchronous Replication Setup Step by Step