{"id":3089,"date":"2010-12-01T12:27:14","date_gmt":"2010-12-01T10:27:14","guid":{"rendered":"http:\/\/code.openark.org\/blog\/?p=3089"},"modified":"2010-12-01T12:27:14","modified_gmt":"2010-12-01T10:27:14","slug":"guide-to-mysql-installation-files","status":"publish","type":"post","link":"https:\/\/code.openark.org\/blog\/mysql\/guide-to-mysql-installation-files","title":{"rendered":"Guide to MySQL installation files"},"content":{"rendered":"<p>Even for DBAs already familiar with MySQL, the choice of installation methods and the variety of install\/package files is overwhelming and confusing.<\/p>\n<p>I&#8217;ll make a (very!) brief introduction to the various installation options, concentrating on the Linux operating system, and provide with a simple shopping list.<\/p>\n<p>For illustration, I&#8217;ll refer to the MySQL <strong>5.1.52<\/strong> community edition, the latest at the time of this writing. Downloads are available at <a href=\"http:\/\/dev.mysql.com\/downloads\/mysql\/5.1.html\">http:\/\/dev.mysql.com\/downloads\/mysql\/5.1.html<\/a>.<\/p>\n<p>I will then refer to alternate distributions.<\/p>\n<h4>A note for Windows users<\/h4>\n<p>You are lucky: your choice is very clear. Download the Windows MSI package. Choose <strong>32<\/strong> or <strong>64<\/strong> bit architecture according to your OS. If you know about the other ways to install and setup MySQL under Windows, you don&#8217;t need this post.<\/p>\n<h4>Linux: repositories<\/h4>\n<p>Easiest way to install MySQL on linux would be to use your distro&#8217;s repository. Just:<\/p>\n<blockquote>\n<pre>sudo apt-get install mysql-server-5.1<\/pre>\n<\/blockquote>\n<p>or<\/p>\n<blockquote>\n<pre>sudo yum install MySQL-Server-5.1<\/pre>\n<\/blockquote>\n<p>Your distro should resolve any package dependencies.<\/p>\n<p>I&#8217;m in the opinion that if MySQL is the main application to be used on a server, distribution&#8217;s default repositories are <em>not<\/em> the way to go. Reasons include MySQL outdated version, incapability of installing multiple instance, danger of automatic upgrades or downgrades. Read <a href=\"http:\/\/code.openark.org\/blog\/mysql\/to-not-yum-or-to-not-apt-get\">this post and discussion<\/a> that follows for more.<\/p>\n<h4>Linux: packages<\/h4>\n<p>If you&#8217;re a RedHat\/CentOS\/SuSE user, you&#8217;re in luck: MySQL provides pre-built RPM packages for your system. I vaguely remember MySQL announcing that Ubuntu is to be supported. That was a couple years ago; there is still no package for Debian\/Ubuntu.<\/p>\n<p><!--more-->So, assuming you&#8217;re a RedHat\/CentOs user, which packages should you download?<\/p>\n<p>There&#8217;s over <strong>60<\/strong> different RPMs available for download. I always need to stress my eyes to get it right. Here&#8217;s the simple answer (again, if you know better, you don&#8217;t need this post). Choose <strong>&#8220;RedHat &amp; Oracle Enterprise Linux&#8221;<\/strong>; download:<\/p>\n<ul>\n<li><strong>MySQL-client-community-5.1.52-1.rhel5.x86_64.rpm<\/strong><\/li>\n<li><strong>MySQL-server-community-5.1.52-1.rhel5.x86_64.rpm<\/strong><\/li>\n<li><strong>MySQL-shared-community-5.1.52-1.rhel5.x86_64.rpm<\/strong><\/li>\n<li><strong>MySQL-shared-compat-5.1.52-1.rhel5.x86_64.rpm<\/strong><\/li>\n<\/ul>\n<p>The above assumes a RedHat\/CentOS 5.x and a 64 bit Intel\/AMD processor.<\/p>\n<p>The aforementioned post relays my opinion of using RPMs; these are still susceptible to <strong>yum<\/strong>&#8216;s whims. Be careful.<\/p>\n<h4>Linux: binary<\/h4>\n<p>Not afraid to install by hand? Want to avoid limitations introduced by pre-built packages? Download a binary distribution:<\/p>\n<ul>\n<li>Choose <strong>&#8220;Linux &#8211; Generic&#8221;<\/strong>. Downlaod <strong>mysql-5.1.52-linux-x86_64-glibc23.tar.gz<\/strong><\/li>\n<\/ul>\n<p>This <em>tar.gz<\/em> distribution includes server &amp; client. It includes <em>glibc<\/em> so it does not depend on your OS installed <em>glibc<\/em> version (a pain to upgrade\/downgrade as it is used by so many packages).<\/p>\n<p>You may still want to download and install the <em>shared-compat<\/em> RPM package (see previous section) to have all possible libmysqlclientX.X packages installed.<\/p>\n<h4>Linux: source<\/h4>\n<p>If you got here, then you either know your way around (why do you keep reading?) or you have a good reason to use a source distribution.<\/p>\n<p>What good reason could that be?<\/p>\n<p>A more and more common reason is that you want to add something to MySQL. Sphinx search storage engine is such a common addition.<\/p>\n<ul>\n<li>Choose <strong>&#8220;Source Code&#8221;<\/strong>: download <strong>mysql-5.1.52.tar.gz<\/strong> (Architecture Independent).<\/li>\n<\/ul>\n<h4>Non MySQL downloads<\/h4>\n<p>You don&#8217;t have to download the official MySQL distribution. Two good alternatives are:<\/p>\n<ul>\n<li>Percona Server; download from <a href=\"http:\/\/www.percona.com\/software\/percona-server\/\">http:\/\/www.percona.com\/software\/percona-server\/<\/a>. The Percona Server (a MySQL fork by <a href=\"http:\/\/www.percona.com\/\">Percona<\/a>) is available in RPM, DEB, BSD, Binary, Source distributions. There are no Windows distributions.<\/li>\n<li>MariaDB, download from <a href=\"http:\/\/askmonty.org\/wiki\/MariaDB:Download\">http:\/\/askmonty.org\/wiki\/MariaDB:Download<\/a>. MariaDB is a MySQL fork by <a href=\"http:\/\/mariadb.org\/\">Montry Program AB<\/a>, and is available for Windows, Linux, Solaris, in Source, Binary, RPM and DEB distributions.<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Even for DBAs already familiar with MySQL, the choice of installation methods and the variety of install\/package files is overwhelming and confusing. I&#8217;ll make a (very!) brief introduction to the various installation options, concentrating on the Linux operating system, and provide with a simple shopping list. For illustration, I&#8217;ll refer to the MySQL 5.1.52 community [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"enabled":false},"version":2}},"categories":[5],"tags":[10],"class_list":["post-3089","post","type-post","status-publish","format-standard","hentry","category-mysql","tag-installation"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p2bZZp-NP","_links":{"self":[{"href":"https:\/\/code.openark.org\/blog\/wp-json\/wp\/v2\/posts\/3089","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/code.openark.org\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/code.openark.org\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/code.openark.org\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/code.openark.org\/blog\/wp-json\/wp\/v2\/comments?post=3089"}],"version-history":[{"count":10,"href":"https:\/\/code.openark.org\/blog\/wp-json\/wp\/v2\/posts\/3089\/revisions"}],"predecessor-version":[{"id":3099,"href":"https:\/\/code.openark.org\/blog\/wp-json\/wp\/v2\/posts\/3089\/revisions\/3099"}],"wp:attachment":[{"href":"https:\/\/code.openark.org\/blog\/wp-json\/wp\/v2\/media?parent=3089"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/code.openark.org\/blog\/wp-json\/wp\/v2\/categories?post=3089"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/code.openark.org\/blog\/wp-json\/wp\/v2\/tags?post=3089"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}