{"id":625,"date":"2020-06-11T15:14:16","date_gmt":"2020-06-11T14:14:16","guid":{"rendered":"https:\/\/www.steve-meier.de\/?p=625"},"modified":"2020-06-14T12:14:11","modified_gmt":"2020-06-14T11:14:11","slug":"mariadb-5-5-10-4-auf-centos-7","status":"publish","type":"post","link":"https:\/\/www.steve-meier.de\/?p=625","title":{"rendered":"MariaDB 5.5 -> 10.4 auf CentOS 7"},"content":{"rendered":"\n<p>CentOS 7 kommt von Hause aus mit einer fast antiken MariaDB-Version 5.5.<\/p>\n\n\n\n<p>Diese zu ersetzen ist aber relativ einfach. Dazu installieren wir zun\u00e4chst das MariaDB-Repository mit wenigen Kommandos:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wget https:\/\/downloads.mariadb.com\/MariaDB\/mariadb_repo_setup\nchmod 755 mariadb_repo_setup\n.\/mariadb_repo_setup<\/pre>\n\n\n\n<p>Bevor wir den Austausch beginnen, machen wir sicherheitshalber ein vollst\u00e4ndiges Backup:<\/p>\n\n\n\n<pre class=\"wp-block-verse\">mysqldump -Ap &gt; mysqldump_20200610.sql<\/pre>\n\n\n\n<p>Nun stoppen wir den Server:<\/p>\n\n\n\n<pre class=\"wp-block-verse\">systemctl stop mariadb<\/pre>\n\n\n\n<p>Und starten anschlie\u00dfend das Upgrade \u00fcber yum:<\/p>\n\n\n\n<pre class=\"wp-block-verse\">yum update 'mariadb*'<\/pre>\n\n\n\n<p>Nach dem Upgrade starten wir MariaDB wieder und verifizieren die neue Version:<\/p>\n\n\n\n<pre class=\"wp-block-verse\"># systemctl start mariadb\n\n# mysql -p\n\nMariaDB [(none)]> SELECT VERSION();\n+-----------------+\n| VERSION()       |\n+-----------------+\n| 10.4.13-MariaDB |\n+-----------------+<\/pre>\n\n\n\n<p>Um das Upgrade abzuschlie\u00dfen, lassen wir nun noch mysql_upgrade laufen:<\/p>\n\n\n\n<pre class=\"wp-block-verse\"># mysql_upgrade -p\nPhase 1\/7: Checking and upgrading mysql database\nProcessing databases\nmysql\nmysql.columns_priv OK\nmysql.db OK\nmysql.event OK\nmysql.func OK\nmysql.help_category OK\nmysql.help_keyword OK\nmysql.help_relation OK\nmysql.help_topic OK\nmysql.host OK\nmysql.ndb_binlog_index OK\nmysql.plugin OK\nmysql.proc OK\nmysql.procs_priv OK\nmysql.proxies_priv OK\nmysql.servers OK\nmysql.tables_priv OK\nmysql.time_zone OK\nmysql.time_zone_leap_second OK\nmysql.time_zone_name OK\nmysql.time_zone_transition OK\nmysql.time_zone_transition_type OK\nmysql.user OK\nUpgrading from a version before MariaDB-10.1\nPhase 2\/7: Installing used storage engines\nChecking for tables with unknown storage engine\nPhase 3\/7: Fixing views\nPhase 4\/7: Running 'mysql_fix_privilege_tables'\nPhase 5\/7: Fixing table and database names\nPhase 6\/7: Checking and upgrading tables\nProcessing databases\n[...]\ninformation_schema\nperformance_schema\nPhase 7\/7: Running 'FLUSH PRIVILEGES'\nOK<\/pre>\n\n\n\n<p>Damit auch das neue MariaDB automatisch startet, muss es neu in Systemd eingebunden werden:<\/p>\n\n\n\n<pre class=\"wp-block-verse\"># systemctl enable mariadb<br>Created symlink from \/etc\/systemd\/system\/mysql.service to \/usr\/lib\/systemd\/system\/mariadb.service.<br>Created symlink from \/etc\/systemd\/system\/mysqld.service to \/usr\/lib\/systemd\/system\/mariadb.service.<br>Created symlink from \/etc\/systemd\/system\/multi-user.target.wants\/mariadb.service to \/usr\/lib\/systemd\/system\/mariadb.service.<\/pre>\n\n\n\n<p><strong>Fertig!<\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>CentOS 7 kommt von Hause aus mit einer fast antiken MariaDB-Version 5.5. Diese zu ersetzen ist aber relativ einfach. Dazu installieren wir zun\u00e4chst das MariaDB-Repository mit wenigen Kommandos: wget https:\/\/downloads.mariadb.com\/MariaDB\/mariadb_repo_setup chmod 755 mariadb_repo_setup&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[],"_links":{"self":[{"href":"https:\/\/www.steve-meier.de\/index.php?rest_route=\/wp\/v2\/posts\/625"}],"collection":[{"href":"https:\/\/www.steve-meier.de\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.steve-meier.de\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.steve-meier.de\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.steve-meier.de\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=625"}],"version-history":[{"count":4,"href":"https:\/\/www.steve-meier.de\/index.php?rest_route=\/wp\/v2\/posts\/625\/revisions"}],"predecessor-version":[{"id":629,"href":"https:\/\/www.steve-meier.de\/index.php?rest_route=\/wp\/v2\/posts\/625\/revisions\/629"}],"wp:attachment":[{"href":"https:\/\/www.steve-meier.de\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=625"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.steve-meier.de\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=625"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.steve-meier.de\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=625"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}