Hướng dẫn cài mysql trên redhat (ok)

https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/9/html/configuring_and_using_database_servers/assembly_using-mysql_configuring-and-using-database-servers

3.2. Installing MySQL

RHEL 9.0 provides MySQL 8.0 as the initial version of this Application Stream, which you can install easily as an RPM package.

To install MySQL, use the following procedure.

Procedure

  1. Install MySQL server packages:

    # dnf install mysql-server
  2. Start the mysqld service:

    # systemctl start mysqld.service
  3. Enable the mysqld service to start at boot:

    # systemctl enable mysqld.service
  4. Recommended: To improve security when installing MySQL, run the following command:

    $ mysql_secure_installation

    The command launches a fully interactive script, which prompts for each step in the process. The script enables you to improve security in the following ways:

    • Setting a password for root accounts

    • Removing anonymous users

    • Disallowing remote root logins (outside the local host)

Note

The MySQL and MariaDB database servers cannot be installed in parallel in RHEL 9 due to conflicting RPM packages. In RHEL 9, different versions of database servers can be used in containers.

Last updated