EverKB

Knowledge Base Ever

Installer MariaDB10.4 på CentOS7

2019-11-15 12:14:05

tag: CentOS, MariaDB, CentOS7, MariaDB10.4, Installer MariaDB

På CentOS7 installerer YUM MariaDB5.5.60 som standard. For å installere den nyeste versjonen, må du opprette en YUM-konfigurasjonsfil først.
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/
[mariadb]
name = MariaDB
baseurl = http://yum.mariadb.org/10.4/centos7-amd64
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck=1
Bruk deretter YUM-kommandoen til å installere MariaDB-serveren og klienten, angi at den skal kjøres automatisk når du starter opp, og start den.
sudo yum -y install MariaDB-server MariaDB-client

systemctl enable mariadb
systemctl start mariadb
Opprett en bruker og autoriser:
CREATE USER 'username'@'host' IDENTIFIED BY 'password';

GRANT privileges ON database_name.table_name TO 'username'@'host';
Hvis du trenger å opprette en bruker som kan autoriseres til andre brukere, må du utføre:
GRANT privileges ON database_name.table_name TO 'username'@'host' WITH GRANT OPTION;

tag

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