Facebook Twitter Instagram
    TecAdmin
    • Home
    • Ubuntu 20.04
      • Upgrade Ubuntu
      • Install Java
      • Install Node.js
      • Install Docker
      • Install LAMP Stack
    • Tutorials
      • AWS
      • Shell Scripting
      • Docker
      • Git
      • MongoDB
    • FeedBack
    • Submit Article
    • About Us
    Facebook Twitter Instagram
    TecAdmin
    Home»Databases»MySQL»How To Install MySQL 8.0 on Fedora 34/33

    How To Install MySQL 8.0 on Fedora 34/33

    RahulBy RahulOctober 5, 20183 Mins ReadUpdated:June 13, 2021

    MySQL is a relational database management system. MySQL 8 is the latest version available for installation on Linux systems.

    If you need to install MySQL 5.7, the official repository provides packages up to Fedora 31. The latest Fedora version are recommended to use MySQL 8.0. Use other article to install MySQL 5.7 on Fedora 31/30 and earlier versions.

    This tutorial will help you to install MySQL 8.0 on Fedora 34/33/32/31/30 Linux systems.

    Step 1 – Prerequisites

    Login to your Fedora system and open a terminal. Now upgrade the current packages to the latest version by running the following command.

    sudo dnf update
    

    Step 2 – Setup Yum Repository

    The MySQL team officially provides yum repository for the installation of MySQL community server on a Fedora systems. Create a new yum repository file using the content below:

    vim /etc/yum.repos.d/mysql-community.repo
    
    File: /etc/yum.repos.d/mysql-community.repo
    [mysql80-community]
    name=MySQL 8.0 Community Server
    baseurl=http://repo.mysql.com/yum/mysql-8.0-community/fc/$releasever/$basearch/
    enabled=1
    gpgcheck=1
    gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
    

    Save file and close.

    Step 3 – Install MySQL Server

    Now, run the following command to install the mysql-community-server packages on your Fedora system. This will also install all other required dependencies on your system.

    sudo dnf install mysql-community-server
    

    sudo systemctl enable mysqld.service
    sudo systemctl start mysqld.service
    

    Now, follow the post-installation instructions.

    Step 4 – MySQL Post Installation Setup

    The MySQL community server has been installed on your system. The installer will also generate a random password and set for the root user. You can find the root user password in log files.

    grep 'A temporary password is generated' /var/log/mysqld.log | tail -1
    
    2018-10-16T11:49:31.216147Z 1 [Note] A temporary password is generated for [email protected]: ,yJrusM58kW7
    

    Now run the following command to apply security on the MySQL server. Simply execute the below command and follow the security wizard.

    sudo mysql_secure_installation
    

    Follow the onscreen instructions. Change your root account password and Press Y for all other operations to apply improved security.

    • Change the password for root? – Press y and change root password
    • Remove anonymous users? Press y
    • Disallow root login remotely? Press y
    • Remove test database and access to it? (Press y
    • Reload privilege tables now? Press y

    Step 5 – Connect MySQL Terminal

    All done. You can now connect to the MySQL server using the command line. The following command will connect MySQL running on the localhost as the root user. This will prompt for the root account password. You can also install LAMP stack on Fedora and configure PHPMyAdmin on fedora to access databases graphically.

    mysql -u root -p
    

    installing mysql 8 Fedora

    That’s it. You have successfully installed MySQL Server 8.0 on your Fedora Linux system.

    fedora Install MySQL MySQL MySQL 8
    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email WhatsApp
    Previous ArticleHow to Install Django on Debian Linux
    Next Article How To Install Redis on Debian Linux

    Related Posts

    How To Install Linux, Nginx, MySQL, & PHP (LEMP Stack) on Ubuntu 22.04

    Updated:April 7, 20227 Mins Read

    How To Install MySQL Server on Ubuntu 22.04

    Updated:April 6, 20224 Mins Read

    How To Install LAMP Stack on Ubuntu 22.04 LTS

    Updated:April 20, 20225 Mins Read

    Top 5 Most Stable Linux Distributions in 2022

    Updated:January 11, 20226 Mins Read

    How To Install MariaDB on Debian 11

    4 Mins Read

    How to Install Anaconda on Fedora 35/34

    Updated:April 18, 20224 Mins Read

    9 Comments

    1. Will on September 15, 2020 1:31 pm

      hi, the ‘install LAMP stack on Fedora’ link at the bottom of the article doesn’t work.

      Reply
      • Rahul on September 16, 2020 4:04 am

        Thanks Will, Link has been updated.

        Reply
    2. uncle on May 22, 2020 3:33 pm

      solved secure login problem

      Reply
    3. Daawud Bakare on March 15, 2020 2:15 am

      very many thanks brother.

      Reply
    4. ECA on December 5, 2019 11:00 pm

      Cannot find temporary password generated in step 4. grep simply returns ‘Binary file /var/log/mysqld.log matches’.

      Reply
    5. imm on October 11, 2019 12:55 pm

      Failed to enable unit: Unit file mysqld.service does not exist. when typing sudo systemctl enable mysqld.service

      Reply
    6. Daniel Sobrinho on July 28, 2019 7:09 pm

      Thanks a lot my friend very usefull for me. I have this problem and this step help a lot.

      Reply
    7. Powerhouse on April 21, 2019 1:45 am

      I get error when doing;

      sudo dnf install mysql-community-server

      warning: /var/cache/dnf/mysql80-community-4fbb8be86665a18d/packages/mysql-community-server-8.0.15-1.fc28.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY
      Public key for mysql-community-server-8.0.15-1.fc28.x86_64.rpm is not installed
      Public key for mysql-community-common-8.0.15-1.fc28.x86_64.rpm is not installed
      Public key for mysql-community-client-8.0.15-1.fc28.x86_64.rpm is not installed
      Public key for mysql-community-libs-8.0.15-1.fc28.x86_64.rpm is not installed

      Please help.

      Reply
      • Tisu on May 2, 2019 12:45 pm

        https://dev.mysql.com/doc/refman/8.0/en/linux-installation-yum-repo.html

        Use this instead if you are still having this issue.

        Reply

    Leave A Reply Cancel Reply

    Recent Posts
    • How to Enable / disable Firewall in Windows
    • How to Install JAVA on Ubuntu 22.04
    • Switching Display Manager in Ubuntu – GDM, LightDM & SDDM
    • Changing the Login Screen Background in Ubuntu 22.04 & 20.04
    • How To Install PHP (8.1, 7.4 or 5.6) on Ubuntu 22.04
    Facebook Twitter Instagram Pinterest
    © 2022 Tecadmin.net. All Rights Reserved | Terms  | Privacy Policy

    Type above and press Enter to search. Press Esc to cancel.