{"id":937,"date":"2026-09-17T23:48:01","date_gmt":"2026-09-17T20:48:01","guid":{"rendered":"https:\/\/imaxis.ru\/?p=937"},"modified":"2026-09-18T00:06:03","modified_gmt":"2026-09-17T21:06:03","slug":"ustanovka-mariadb-na-rocky-linux-i-ubuntu","status":"publish","type":"post","link":"https:\/\/imaxis.ru\/?p=937","title":{"rendered":"\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 MariaDB \u043d\u0430 Rocky Linux \u0438 Ubuntu"},"content":{"rendered":"<h1>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 MariaDB \u043d\u0430 Rocky Linux \u0438 Ubuntu<\/h1>\n<p>MariaDB \u2014 \u0441\u0432\u043e\u0431\u043e\u0434\u043d\u0430\u044f \u0421\u0423\u0411\u0414, \u043e\u0442\u0432\u0435\u0442\u0432\u043b\u0435\u043d\u0438\u0435 MySQL. \u0412 \u044d\u0442\u043e\u0439 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0438 \u2014 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0438\u0437 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f \u041e\u0421 \u0438 \u0438\u0437 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430, \u0431\u0430\u0437\u043e\u0432\u0430\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0438 \u043e\u0442\u043a\u0440\u044b\u0442\u0438\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u0430.<\/p>\n<hr \/>\n<h2>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0438 \u0437\u0430\u043f\u0443\u0441\u043a<\/h2>\n<h3>CentOS \/ Rocky Linux<\/h3>\n<pre><code class=\"language-bash\">yum install mariadb-server\nsystemctl enable mariadb --now\n<\/code><\/pre>\n<p><strong>\u0414\u043b\u044f Rocky\/AlmaLinux 8+ \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 <code>dnf<\/code> \u2014 \u043a\u043e\u043c\u0430\u043d\u0434\u0430 \u0442\u0430 \u0436\u0435.<\/strong><\/p>\n<h3>Ubuntu \/ Debian<\/h3>\n<pre><code class=\"language-bash\">apt install mariadb-server\nsystemctl enable mariadb\n<\/code><\/pre>\n<p><strong>\u0412 Ubuntu \u0441\u0435\u0440\u0432\u0438\u0441 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442\u0441\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438, \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0439 <code>start<\/code> \u043d\u0435 \u043d\u0443\u0436\u0435\u043d.<\/strong><\/p>\n<hr \/>\n<h2>\u041f\u043e\u0441\u043b\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438<\/h2>\n<ol>\n<li>\u0417\u0430\u0434\u0430\u0451\u043c \u043f\u0430\u0440\u043e\u043b\u044c root-\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0421\u0423\u0411\u0414:<\/li>\n<\/ol>\n<pre><code class=\"language-bash\">mysqladmin -u root password\n<\/code><\/pre>\n<p><strong>\u041f\u0430\u0440\u043e\u043b\u044c \u0432\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u0434\u0432\u0430\u0436\u0434\u044b.<\/strong><\/p>\n<ol>\n<li>\u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435:<\/li>\n<\/ol>\n<pre><code class=\"language-bash\">mysql -uroot -p\n<\/code><\/pre>\n<pre><code>MariaDB [(none)]&gt;\n<\/code><\/pre>\n<p><strong>\u041f\u0440\u0438\u0433\u043b\u0430\u0448\u0435\u043d\u0438\u0435 \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u0441\u0435\u0440\u0432\u0435\u0440 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d \u0438 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442.<\/strong><\/p>\n<ol>\n<li>\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u2014 \u0432 <code>\/etc\/my.cnf<\/code> \u0438 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u043c\u044b\u0445 \u0444\u0430\u0439\u043b\u0430\u0445 <code>\/etc\/my.cnf.d\/<\/code>. \u041f\u043e\u0441\u043b\u0435 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439:<\/li>\n<\/ol>\n<pre><code class=\"language-bash\">systemctl restart mariadb\n<\/code><\/pre>\n<ol>\n<li>\u0414\u043b\u044f \u0443\u0434\u0430\u043b\u0451\u043d\u043d\u043e\u0433\u043e \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u043c \u043f\u043e\u0440\u0442 3306.<\/li>\n<\/ol>\n<p><strong>Firewalld:<\/strong><\/p>\n<pre><code class=\"language-bash\">firewall-cmd --permanent --add-port=3306\/tcp\nfirewall-cmd --reload\n<\/code><\/pre>\n<p><strong>iptables:<\/strong><\/p>\n<pre><code class=\"language-bash\">iptables -I INPUT -p tcp --dport 3306 -j ACCEPT\napt install iptables-persistent\nnetfilter-persistent save\n<\/code><\/pre>\n<hr \/>\n<h2>\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f<\/h2>\n<p>\u041f\u0430\u043a\u0435\u0442 \u0438\u0437 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f \u041e\u0421 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0443\u0441\u0442\u0430\u0440\u0435\u0432\u0448\u0438\u043c. \u041e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0439 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0439 \u2014 \u043d\u0430 <a href=\"https:\/\/downloads.mariadb.org\/mariadb\/repositories\">downloads.mariadb.org\/mariadb\/repositories<\/a>: \u0432\u044b\u0431\u0438\u0440\u0430\u0435\u043c \u041e\u0421, \u0432\u0435\u0440\u0441\u0438\u044e MariaDB \u0438 \u0437\u0435\u0440\u043a\u0430\u043b\u043e.<\/p>\n<h3>RPM (Rocky Linux \/ CentOS)<\/h3>\n<pre><code class=\"language-bash\">vi \/etc\/yum.repos.d\/mariadb.repo\n<\/code><\/pre>\n<pre><code class=\"language-ini\">[mariadb]\nname = MariaDB\nbaseurl = https:\/\/mirror.docker.ru\/mariadb\/yum\/11.4\/rocky9-amd64\ngpgkey=https:\/\/mirror.docker.ru\/mariadb\/yum\/RPM-GPG-KEY-MariaDB\ngpgcheck=1\n<\/code><\/pre>\n<h3>DEB (Debian \/ Ubuntu \/ Astra Linux)<\/h3>\n<pre><code class=\"language-bash\">apt install apt-transport-https curl\nmkdir -p \/etc\/apt\/keyrings\ncurl -o \/etc\/apt\/keyrings\/mariadb-keyring.pgp 'https:\/\/mariadb.org\/mariadb_release_signing_key.pgp'\nvi \/etc\/apt\/sources.list.d\/mariadb.sources\n<\/code><\/pre>\n<pre><code># MariaDB 11.4 repository list\nX-Repolib-Name: MariaDB\nTypes: deb\nURIs: https:\/\/mirrors.xtom.ee\/mariadb\/repo\/11.4\/ubuntu\nSuites: noble\nComponents: main main\/debug\nSigned-By: \/etc\/apt\/keyrings\/mariadb-keyring.pgp\n<\/code><\/pre>\n<p><strong>\u0412 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u2014 MariaDB \u0432\u0435\u0440\u0441\u0438\u0438 11.4 (\u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u0430\u044f \u0432\u0435\u0442\u043a\u0430 LTS). \u0417\u0430\u043c\u0435\u043d\u0438\u0442\u0435 <code>Suites<\/code> \u043d\u0430 \u043a\u043e\u0434\u043e\u0432\u043e\u0435 \u0438\u043c\u044f \u0432\u0430\u0448\u0435\u0433\u043e \u0434\u0438\u0441\u0442\u0440\u0438\u0431\u0443\u0442\u0438\u0432\u0430 (<code>jammy<\/code>, <code>noble<\/code> \u0438 \u0442. \u0434.).<\/strong><\/p>\n<p>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u043f\u043e\u0441\u043b\u0435 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f:<\/p>\n<p><strong>RPM:<\/strong><\/p>\n<pre><code class=\"language-bash\">yum makecache\nyum install mariadb-server\n<\/code><\/pre>\n<p><strong>DEB:<\/strong><\/p>\n<pre><code class=\"language-bash\">apt update\napt install mariadb-server\n<\/code><\/pre>\n<hr \/>\n<h2>\u0422\u043e\u043d\u043a\u043e\u0441\u0442\u0438 \u0438 \u043f\u043e\u0434\u0432\u043e\u0434\u043d\u044b\u0435 \u043a\u0430\u043c\u043d\u0438<\/h2>\n<ul>\n<li><strong>\u0412\u0435\u0440\u0441\u0438\u0438<\/strong> \u2014 \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0435 \u0432\u0435\u0442\u043a\u0438 MariaDB: 11.4 (LTS) \u0438 \u043d\u043e\u0432\u0435\u0435; \u0441\u0442\u0430\u0440\u044b\u0435 10.x \u043f\u043e\u0441\u0442\u0435\u043f\u0435\u043d\u043d\u043e \u0432\u044b\u0432\u043e\u0434\u044f\u0442\u0441\u044f.<\/li>\n<li><strong><code>Suites<\/code><\/strong> \u2014 \u0434\u043e\u043b\u0436\u043d\u043e \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u043e\u0432\u0430\u0442\u044c \u043a\u043e\u0434\u043e\u0432\u043e\u043c\u0443 \u0438\u043c\u0435\u043d\u0438 \u0434\u0438\u0441\u0442\u0440\u0438\u0431\u0443\u0442\u0438\u0432\u0430, \u0438\u043d\u0430\u0447\u0435 \u043f\u0430\u043a\u0435\u0442\u044b \u043d\u0435 \u043d\u0430\u0439\u0434\u0443\u0442\u0441\u044f.<\/li>\n<li><strong>\u041a\u043b\u044e\u0447 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f<\/strong> \u2014 \u0434\u043b\u044f DEB \u043a\u043b\u044e\u0447 \u043a\u043b\u0430\u0434\u0451\u0442\u0441\u044f \u0432 <code>\/etc\/apt\/keyrings<\/code>; \u043a\u043e\u043c\u0430\u043d\u0434\u0430 <code>apt-key<\/code> \u0443\u0441\u0442\u0430\u0440\u0435\u043b\u0430.<\/li>\n<li><strong>\u041f\u043e\u0440\u0442 3306<\/strong> \u2014 \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0439\u0442\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438; \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0432\u0430\u0439\u0442\u0435 \u0434\u043e\u0441\u0442\u0443\u043f \u043f\u043e IP.<\/li>\n<li><strong><code>mysqladmin password<\/code><\/strong> \u2014 \u0432 \u043d\u043e\u0432\u044b\u0445 \u0432\u0435\u0440\u0441\u0438\u044f\u0445 MariaDB root \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 <code>unix_socket<\/code>; \u0437\u0430\u0434\u0430\u043d\u0438\u0435 \u043f\u0430\u0440\u043e\u043b\u044f \u0432\u043a\u043b\u044e\u0447\u0430\u0435\u0442 \u043e\u0431\u044b\u0447\u043d\u0443\u044e \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044e.<\/li>\n<li><strong><code>\/etc\/my.cnf<\/code><\/strong> \u2014 \u043e\u0431\u0449\u0438\u0439 \u043a\u043e\u043d\u0444\u0438\u0433; \u043d\u0430 Ubuntu \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0432 <code>\/etc\/mysql\/mariadb.conf.d\/<\/code>.<\/li>\n<li><strong>\u041e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 major-\u0432\u0435\u0440\u0441\u0438\u0438<\/strong> \u2014 \u0442\u0440\u0435\u0431\u0443\u0435\u0442 <code>mariadb-upgrade<\/code>; \u0447\u0438\u0442\u0430\u0439\u0442\u0435 release notes.<\/li>\n<li><strong>\u0420\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0439 \u041e\u0421 vs \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0439<\/strong> \u2014 \u0434\u043b\u044f \u043f\u0440\u043e\u0434\u0430\u043a\u0448\u0435\u043d\u0430 \u043f\u0440\u0435\u0434\u043f\u043e\u0447\u0442\u0438\u0442\u0435\u043b\u0435\u043d \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0439 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0439 \u0441 \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u043c\u0438 \u043f\u0430\u0442\u0447\u0430\u043c\u0438.<\/li>\n<\/ul>\n<hr \/>\n<h2>\u0428\u043f\u0430\u0440\u0433\u0430\u043b\u043a\u0430<\/h2>\n<pre><code class=\"language-bash\"># \u0438\u0437 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f \u041e\u0421\ndnf install mariadb-server &amp;&amp; systemctl enable mariadb --now   # RPM\napt install mariadb-server &amp;&amp; systemctl enable mariadb         # DEB\n\nmysqladmin -u root password\nmysql -uroot -p\n\n# \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0439 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0439 (DEB)\ncurl -o \/etc\/apt\/keyrings\/mariadb-keyring.pgp 'https:\/\/mariadb.org\/mariadb_release_signing_key.pgp'\n# \/etc\/apt\/sources.list.d\/mariadb.sources -&gt; URIs, Suites, Signed-By\napt update &amp;&amp; apt install mariadb-server\n<\/code><\/pre>\n<p><em>\u041f\u0440\u043e\u0432\u0435\u0440\u0435\u043d\u043e \u043d\u0430: Ubuntu 22.04\/24.04, Rocky Linux 9 + MariaDB 11.4.<\/em><br \/>\n<em>\u0414\u0430\u0442\u0430: \u0421\u0435\u043d\u0442\u044f\u0431\u0440\u044c 2026.<\/em><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 MariaDB \u043d\u0430 Rocky Linux \u0438 Ubuntu MariaDB \u2014 \u0441\u0432\u043e\u0431\u043e\u0434\u043d\u0430\u044f<\/p>\n","protected":false},"author":0,"featured_media":972,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"footnotes":""},"categories":[3],"tags":[],"class_list":["post-937","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-linux"],"aioseo_notices":[],"views":18,"_links":{"self":[{"href":"https:\/\/imaxis.ru\/index.php?rest_route=\/wp\/v2\/posts\/937","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/imaxis.ru\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/imaxis.ru\/index.php?rest_route=\/wp\/v2\/types\/post"}],"replies":[{"embeddable":true,"href":"https:\/\/imaxis.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=937"}],"version-history":[{"count":2,"href":"https:\/\/imaxis.ru\/index.php?rest_route=\/wp\/v2\/posts\/937\/revisions"}],"predecessor-version":[{"id":940,"href":"https:\/\/imaxis.ru\/index.php?rest_route=\/wp\/v2\/posts\/937\/revisions\/940"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/imaxis.ru\/index.php?rest_route=\/wp\/v2\/media\/972"}],"wp:attachment":[{"href":"https:\/\/imaxis.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=937"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/imaxis.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=937"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/imaxis.ru\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=937"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}