{"id":14,"date":"2009-10-10T01:42:17","date_gmt":"2009-10-10T08:42:17","guid":{"rendered":"https:\/\/www.zacwitte.com\/?p=14"},"modified":"2009-10-10T01:42:17","modified_gmt":"2009-10-10T08:42:17","slug":"upgrading-mysql-and-php-on-centos-plesk","status":"publish","type":"post","link":"https:\/\/zacwitte.com\/?p=14","title":{"rendered":"Upgrading to MySQL 5.1 and PHP 5.3.0 on Centos with Plesk"},"content":{"rendered":"<p>This is an  account of my experience trying to upgrade MySQL to version 5.1 on my  MediaTemple (dv) 3.5 dedicated virtual server. It may help people not on  MediaTemple servers, especially if you\u2019re trying to upgrade MySQL  without damaging Plesk. There are a lot of forum posts out there that  lead you down the wrong path so beware.<\/p>\n<p>Before you go any further, this could really mess up your server and  its not totally tested so if you have anything you depend on, I would be  very careful. In this process I actually had to do a complete restore  because I screwed the server up so royally before I figured everything  out.<\/p>\n<p>First, obviously, you need to install the developer tools through the  (mt) control panel which enabled root access and SSH. Then you need to  install yum, following the directions in the (mt) knowledgebase article.  There\u2019s also a note at the bottom of that article about removing  SiteBuilder, which you should do, but don\u2019t bother installing the atomix  repository.<\/p>\n<p>Then, you\u2019ll see that mysql 5.0.x is the latest in the existing  repositories. Remi\u2019s repos have all the latest goodies so we need to  enable that. This page is helpful:  http:\/\/blog.famillecollet.com\/pages\/Config-en<\/p>\n<p>wget http:\/\/download.fedora.redhat.com\/pub\/epel\/5\/i386\/epel-release-5-4.noarch.rpm<br \/>\nwget http:\/\/rpms.famillecollet.com\/enterprise\/remi-release-5.rpm<br \/>\nrpm -Uvh remi-release-5*.rpm epel-release-5*.rpm<\/p>\n<p>A quirk about centos is that after adding a repo it\u2019s not actually  enabled by default. There are two ways to go about getting access to the  files. Either add the option \u2013enablerepo=remi to the yum command or  edit the \/etc\/yum.repo.d\/remi.repo file and change enabled=1. Now if you  do yum \u2013enablerepo=remi info mysql it SHOULD say the latest 5.1.x  version. But there are a couple other tricky bits.<\/p>\n<p>If you try upgrading mysql you\u2019ll notice that there are two packages  creating conflicts. php-mhash and php-ncurses. Those two packages are  safe to remove (yum remove php-mhash php-ncurses). Now you should be  able upgrade mysql, which will also upgrade php to 5.3.0 (but if you try  to upgrade php alone, you\u2019ll get errors). yum \u2013enablerepo=remi upgrade  mysql<\/p>\n<p>You\u2019re almost there. You\u2019ll notice that mysql won\u2019t start, which is  because there are old settings in \/etc\/my.cnf that trip it up. I\u2019m doing  this upgrade on a completely fresh system and I don\u2019t have to worry  about loosing any settings or even any databases that already exist, so I  moved \/etc\/my.cnf to a new location and restarted mysql, which  regenerates a fresh my.cnf. The final step is to run \u201cmysql_upgrade -u  admin -p\u201d. The password is your plesk admin password.<\/p>\n<p>The one unsolved part of this mystery is updating the plesk tables.  All of these tables fail the update script. Still, I\u2019ve clicked around  and Plesk seems to be working OK.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This is an account of my experience trying to upgrade MySQL to version 5.1 on my MediaTemple (dv) 3.5 dedicated virtual server. It may help people not on MediaTemple servers, especially if you\u2019re trying to upgrade MySQL without damaging Plesk. There are a lot of forum posts out there that lead you down the wrong [&hellip;]<\/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":[],"class_list":["post-14","post","type-post","status-publish","format-standard","hentry","category-tech"],"_links":{"self":[{"href":"https:\/\/zacwitte.com\/index.php?rest_route=\/wp\/v2\/posts\/14","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/zacwitte.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/zacwitte.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/zacwitte.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/zacwitte.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=14"}],"version-history":[{"count":0,"href":"https:\/\/zacwitte.com\/index.php?rest_route=\/wp\/v2\/posts\/14\/revisions"}],"wp:attachment":[{"href":"https:\/\/zacwitte.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=14"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/zacwitte.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=14"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/zacwitte.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=14"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}