Knowledge Base Ever

Install MariaDB10.4 on CentOS7

2019-11-15 12:14:05

label: CentOS, MariaDB, CentOS7, MariaDB10.4, Install MariaDB

On CentOS7, YUM installs MariaDB5.5.60 by default. In order to install the latest version, you need to create a YUM configuration file first.
vim /etc/yum.repos.d/MariaDB.repo

# MariaDB 10.4 CentOS repository list - created 2019-08-03 17:26 UTC
# http://downloads.mariadb.org/mariadb/repositories/
name = MariaDB
baseurl = http://yum.mariadb.org/10.4/centos7-amd64
Then use the YUM command to install the MariaDB server and client, set it to run automatically when booting, and launch it.
sudo yum -y install MariaDB-server MariaDB-client

systemctl enable mariadb
systemctl start mariadb
Create a user and authorize:
CREATE USER 'username'@'host' IDENTIFIED BY 'password';

GRANT privileges ON database_name.table_name TO 'username'@'host';
If you need to create a user that can be authorized to other users, you need to perform:
GRANT privileges ON database_name.table_name TO 'username'@'host' WITH GRANT OPTION;


CentOS7 CentOS PHP Linux Python3 Python MySQL MariaDB YUM JavaScript CSS Redis MySQL8 caching_sha2_password HTML mysql_native_password PHP7 height network interface Shadowsocks-Libev unixODBC-devel error_get_last Port 80 string Aura INDENTIFIED BY password policy requirements SOCKS Web Development data Fedora Media Writer msodbcsql Redis5 SVN Deepin jemalloc SQLAlchemy absolute FuelPHP mysqlclient Shadowsocks toggle convert Error Control Operator margin PHPUnit Framework ss5.passwd at-symbol IIS password SOCKET vps daemon process Fatal Errors MongoDB4 sudoers center DATE_SUB Phalcon SQL Server 2017 WiFi .htaccess frequency conflict set_error_handler TestCase Compiling PHP Elasticsearch7.3 PHPUnit ss5.conf apr HTTP particles.js Slim Vincent Garreau daemon Failed to build these modules: _uuid MongoDB Sudo DATE_ADD ip command pg_bha.conf SQL Server width Frameworks MySQL-python scrollbar Tcp BBR Compiling Apache Elasticsearch libpython3.7m.so.1.0 PHPStorm ss5-3.8.9 Apache2.4 NodeJs show VIM CURLOPT_POSTFIELDS Failed to build these modules: _ctypes Minimal ISO substr Bluetooth INTERVAL PECL SQL Date Funcitons Wi-Fi date sub font-size root Tag Cloud CodeIgniter dual network interfaces Laravel ss5 apache httpd horiz-align node.js ShadowsocksR vertical-align CURLFille exec mb_substr PyCharm SUBDATE BarManager IntelliJIDEA PEAR SOCKS5 Proxy Server WebStorm date add find remi Tag Chrome du jQuery PHP5.5 src Apache hide nginx Shadowsocks-Python V2Ray cURL eth0 MariaDB10.4 PostgreSQL sub folder availability Install MongoDB pdo_sqlsrv SOCKS5 Web Server date File Upload mssql-tools register_shutdown_function Symfony DevExpress JetBrain php-fpm sqlsrv Zend Framework ADDDATE