Ubuntu 18.04 can’t install mysql5.7

Time:2021-6-8

Ubuntu 18.04 cannot install mysql-5.7 solution

Yesterday, I installed an Ubuntu 18.04 at home, and found that mysql-5.7 could not be installed directly. After checking the relevant error information and relevant information, I found a solution, so I was ready to record the problem.

  • Download installation package update source

    First, go to the official website of Mysql to download the updated source of the installation package:dev.mysql.com/downloads/repo/apt/
  • Update system update source

    To update the update source to the system:
    sudo dpkg -i mysql-apt-config_0.*.****_all.deb
  • Install mysql-5.7

    During installation, select MySQL server & cluster, and then select mysql-5.7
  • After the installation, update the system software and execute the
    sudo apt-get update;
  • installmysql-server
    sudo apt-get install mysql-server;

    Select y and enter the password

    After waiting for all the installation, start the MySQL service, and you can see that MySQL 5.7 is ready to use. This is a relatively small problem, about this kind of problem record to avoid later encounter can be solved faster

This work adoptsCC agreementReprint must indicate the author and the link of this article