Https://www.mediawiki.org/wiki/Manual:Installing_MediaWiki
Detects if the system is installed with MySQL:
Rpm-qa | grep MySQL
Unloading
RPM-E MySQL // Normal Delete mode rpm-e--nodeps mysql // Brute Force Delete mode, if you use the above command to delete, prompted to have other dependent files, then use this command can be Brute Force removal
Install MySQL
Yum install mysqlyum install MySQL-serveryum install MySQL-devel
Start MySQL:
Service mysqld Start
In the case of CentOS 7, because the MySQL database has been removed from the default program list, you can use MARIADB instead:
Yum install mariadb-server mariadb chown add mysql /var/lib/mysqlsystemctl start mariadb # Start Mariadbsystemctl stop mariadb #停止MariaDBsystemctl restart mariadb #重启MariaDBsystemctl enable mariadb # Set boot up
After the MySQL installation is successful, the default root user password is empty and you can use the following command to create the root user's password:
mysqladmin-u root password "new_password";
You can connect to the MySQL server by using the following command:
Mysql-u root-p
Linux Build Wiki