Last active
November 12, 2025 12:50
-
-
Save Rusydy/c1b85806d598b036d1c41ffb5c17f48f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Install MySQL 5.7 Community Server on AlmaLinux 10 | |
| ## source: https://computingforgeeks.com/install-mysql-5-7-on-centos-rhel-linux/ | |
| ## Add MySQL Community Repository | |
| sudo vim /etc/yum.repos.d/mysql-community.repo | |
| ## Disable MySQL 8.0 Community Repository | |
| sudo dnf config-manager --disable mysql80-community | |
| ## Enable MySQL 5.7 Community Repository | |
| sudo dnf config-manager --enable mysql57-community | |
| ## Install MySQL 5.7 Community Server | |
| sudo dnf install mysql-community-server | |
| ## After the installation, start mysqld service. | |
| sudo systemctl enable --now mysqld.service | |
| ## Copy the generated random password for the root user | |
| sudo grep 'A temporary password' /var/log/mysqld.log |tail -1 | |
| ### Take note of the printed password: | |
| 2025-11-12T12:16:18.004506Z 1 [Note] A temporary password is generated for root@localhost: EQ(9h)1AsZen | |
| ## Start MySQL Secure Installation to change the root password, Disallow root login remotely, remove anonymous users and remove test database. | |
| sudo mysql_secure_installation | |
| ## Authenticate with your generated temporary password. This will ask you to set a new password for the root user. | |
| ### Change the password for root ? ((Press y|Y for Yes, any other key for No) : Yes | |
| : ' | |
| New password: | |
| Re-enter new password: | |
| Estimated strength of the password: 100 | |
| Do you wish to continue with the password provided?: Yes | |
| Remove anonymous users?: Yes | |
| Success. | |
| Disallow root login remotely? : Yes | |
| Success. | |
| Remove test database and access to it? : Yes | |
| - Dropping test database... | |
| Success. | |
| - Removing privileges on test database... | |
| Success. | |
| Reload privilege tables now? (Press y|Y for Yes) : Yes | |
| Success. | |
| All done! | |
| ' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment