{"id":2290,"date":"2015-08-10T13:57:40","date_gmt":"2015-08-10T04:57:40","guid":{"rendered":"http:\/\/www.whoocus.com\/blog\/?p=2290"},"modified":"2015-08-10T15:15:17","modified_gmt":"2015-08-10T06:15:17","slug":"centos6-7%e3%81%b8%e3%81%aemysql5-6%e3%81%ae%e3%82%a4%e3%83%b3%e3%82%b9%e3%83%88%e3%83%bc%e3%83%ab%e6%96%b9%e6%b3%95","status":"publish","type":"post","link":"https:\/\/www.blowfish.co.jp\/?p=2290","title":{"rendered":"CentOS6.7\u3078\u306eMySQL5.6\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u65b9\u6cd5"},"content":{"rendered":"<p>\u4e45\u3057\u3076\u308a\u306bMySQL\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3002<br \/>\n\u3053\u306e\u624b\u306e\u8a2d\u5b9a\u306f\u30012\u5e74\u306b\u4e00\u5ea6\u304f\u3089\u3044\u3057\u304b\u3057\u306a\u3044\u306e\u3067\u899a\u3048\u66f8\u304d\u3002<\/p>\n<p>OS : CentOS6.7<\/p>\n<p>\u305d\u3046\u3044\u3048\u3070\u3001<a href=\"https:\/\/www.blowfish.co.jp\/?p=744\" target=\"_blank\">\u524d\u56de<\/a>\u306f\u3001CentOS 5.8\u306bMySQL5.5 \u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u3044\u305f\u3002<br \/>\n\u3057\u304b\u3082 yum \u3067\u306f\u306a\u304frpm\u3067\u30fb\u30fb\u30fb\u3002\u61d0\u304b\u3057\u3044\u3002<\/p>\n<p>\u305d\u306e\u307e\u307e\u3067\u3001yum install \u3057\u3066\u3082\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u308c\u308b\u5bfe\u8c61\u306f\u3001MySQL5.1\u306e\u70ba\u3001MySQL5.6\u306b\u3057\u305f\u3044\u3002<\/p>\n<p>[bash]<br \/>\nyum install http:\/\/dev.mysql.com\/get\/mysql-community-release-el6-5.noarch.rpm<br \/>\n[\/bash]<\/p>\n<p><strong>\u30d1\u30c3\u30b1\u30fc\u30b8\u60c5\u5831\u306e\u78ba\u8a8d<\/strong><\/p>\n<p>yum info\u3067\u3001\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u30d1\u30c3\u30b1\u30fc\u30b8\u306e\u60c5\u5831\u3092\u8868\u793a\u3059\u308b<\/p>\n<p>[bash]<br \/>\nyum info mysql-community-server<br \/>\n\u8aad\u307f\u8fbc\u3093\u3060\u30d7\u30e9\u30b0\u30a4\u30f3:fastestmirror, security<br \/>\nLoading mirror speeds from cached hostfile<br \/>\n * base: centos.usonyx.net<br \/>\n * extras: ftp.iij.ad.jp<br \/>\n * updates: centos.usonyx.net<br \/>\n\u5229\u7528\u53ef\u80fd\u306a\u30d1\u30c3\u30b1\u30fc\u30b8<br \/>\n\u540d\u524d                : mysql-community-server<br \/>\n\u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3      : x86_64<br \/>\n\u30d0\u30fc\u30b8\u30e7\u30f3          : 5.6.26<br \/>\n\u30ea\u30ea\u30fc\u30b9            : 2.el6<br \/>\n\u5bb9\u91cf                : 53 M<br \/>\n\u30ea\u30dd\u30b8\u30c8\u30ea\u30fc        : mysql56-community<br \/>\n\u8981\u7d04                : A very fast and reliable SQL database server<br \/>\n&#8230;<br \/>\n[\/bash]<\/p>\n<p><strong>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/strong><\/p>\n<p>\u4e0a\u8a18\u3067\u8abf\u3079\u305f\u5229\u7528\u53ef\u80fd\u306a\u30d1\u30c3\u30b1\u30fc\u30b8\u540d\u3092\u6307\u5b9a\u3057\u3066\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u3002<\/p>\n<p>[bash]<br \/>\n$ yum install mysql-community-server<br \/>\n\u8aad\u307f\u8fbc\u3093\u3060\u30d7\u30e9\u30b0\u30a4\u30f3:fastestmirror, security<br \/>\n\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u51e6\u7406\u306e\u8a2d\u5b9a\u3092\u3057\u3066\u3044\u307e\u3059<br \/>\nLoading mirror speeds from cached hostfile<br \/>\n * base: centos.usonyx.net<br \/>\n * extras: ftp.iij.ad.jp<br \/>\n * updates: centos.usonyx.net<br \/>\n\u4f9d\u5b58\u6027\u306e\u89e3\u6c7a\u3092\u3057\u3066\u3044\u307e\u3059<\/p>\n<p>&#8230;<\/p>\n<p>\u4f9d\u5b58\u6027\u3092\u89e3\u6c7a\u3057\u307e\u3057\u305f<\/p>\n<p>====================================================================================================<br \/>\n \u30d1\u30c3\u30b1\u30fc\u30b8                        \u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3<br \/>\n                                                \u30d0\u30fc\u30b8\u30e7\u30f3            \u30ea\u30dd\u30b8\u30c8\u30ea\u30fc             \u5bb9\u91cf<br \/>\n====================================================================================================<br \/>\n\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u3044\u307e\u3059:<br \/>\n mysql-community-libs              x86_64       5.6.26-2.el6          mysql56-community       1.9 M<br \/>\n     \u7f6e\u304d\u63db\u3048\u3066\u3044\u307e\u3059  mysql-libs.x86_64 5.1.73-5.el6_6<br \/>\n mysql-community-libs-compat       x86_64       5.6.26-2.el6          mysql56-community       1.6 M<br \/>\n     \u7f6e\u304d\u63db\u3048\u3066\u3044\u307e\u3059  mysql-libs.x86_64 5.1.73-5.el6_6<br \/>\n mysql-community-server            x86_64       5.6.26-2.el6          mysql56-community        53 M<br \/>\n\u4f9d\u5b58\u6027\u95a2\u9023\u3067\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3092\u3057\u307e\u3059\u3002:<br \/>\n mysql-community-client            x86_64       5.6.26-2.el6          mysql56-community        18 M<br \/>\n mysql-community-common            x86_64       5.6.26-2.el6          mysql56-community       307 k<br \/>\n perl-DBI                          x86_64       1.609-4.el6           base                    705 k<\/p>\n<p>\u30c8\u30e9\u30f3\u30b6\u30af\u30b7\u30e7\u30f3\u306e\u8981\u7d04<br \/>\n====================================================================================================<br \/>\n\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb         6 \u30d1\u30c3\u30b1\u30fc\u30b8<\/p>\n<p>\u7dcf\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u5bb9\u91cf: 75 M<br \/>\n\u3053\u308c\u3067\u3044\u3044\u3067\u3059\u304b? [y\/N]<br \/>\n\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u3044\u307e\u3059:<br \/>\n(1\/6): mysql-community-client-5.6.26-2.el6.x86_64.rpm                        |  18 MB     00:05<br \/>\n(2\/6): mysql-community-common-5.6.26-2.el6.x86_64.rpm                        | 307 kB     00:00<br \/>\n(3\/6): mysql-community-libs-5.6.26-2.el6.x86_64.rpm                          | 1.9 MB     00:00<br \/>\n(4\/6): mysql-community-libs-compat-5.6.26-2.el6.x86_64.rpm                   | 1.6 MB     00:00<br \/>\n(5\/6): mysql-community-server-5.6.26-2.el6.x86_64.rpm                        |  53 MB     00:12<br \/>\n(6\/6): perl-DBI-1.609-4.el6.x86_64.rpm                                       | 705 kB     00:00<br \/>\n&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-<br \/>\n\u5408\u8a08                                                                3.9 MB\/s |  75 MB     00:19<\/p>\n<p>&#8230;<\/p>\n<p>\u3053\u308c\u3067\u3044\u3044\u3067\u3059\u304b? [y\/N]y<br \/>\nrpm_check_debug \u3092\u5b9f\u884c\u3057\u3066\u3044\u307e\u3059<br \/>\n\u30c8\u30e9\u30f3\u30b6\u30af\u30b7\u30e7\u30f3\u306e\u30c6\u30b9\u30c8\u3092\u5b9f\u884c\u3057\u3066\u3044\u307e\u3059<br \/>\n\u30c8\u30e9\u30f3\u30b6\u30af\u30b7\u30e7\u30f3\u306e\u30c6\u30b9\u30c8\u3092\u6210\u529f\u3057\u307e\u3057\u305f<br \/>\n\u30c8\u30e9\u30f3\u30b6\u30af\u30b7\u30e7\u30f3\u3092\u5b9f\u884c\u3057\u3066\u3044\u307e\u3059<br \/>\n  \u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u3044\u307e\u3059  : mysql-community-common-5.6.26-2.el6.x86_64                          1\/7<br \/>\n  \u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u3044\u307e\u3059  : mysql-community-libs-5.6.26-2.el6.x86_64                            2\/7<br \/>\n  \u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u3044\u307e\u3059  : mysql-community-client-5.6.26-2.el6.x86_64                          3\/7<br \/>\n  \u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u3044\u307e\u3059  : perl-DBI-1.609-4.el6.x86_64                                         4\/7<br \/>\n  \u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u3044\u307e\u3059  : mysql-community-server-5.6.26-2.el6.x86_64                          5\/7<br \/>\n  \u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u3044\u307e\u3059  : mysql-community-libs-compat-5.6.26-2.el6.x86_64                     6\/7<br \/>\n  \u524a\u9664\u4e2d                  : mysql-libs-5.1.73-5.el6_6.x86_64                                    7\/7<br \/>\n  Verifying               : mysql-community-common-5.6.26-2.el6.x86_64                          1\/7<br \/>\n  Verifying               : perl-DBI-1.609-4.el6.x86_64                                         2\/7<br \/>\n  Verifying               : mysql-community-libs-5.6.26-2.el6.x86_64                            3\/7<br \/>\n  Verifying               : mysql-community-server-5.6.26-2.el6.x86_64                          4\/7<br \/>\n  Verifying               : mysql-community-client-5.6.26-2.el6.x86_64                          5\/7<br \/>\n  Verifying               : mysql-community-libs-compat-5.6.26-2.el6.x86_64                     6\/7<br \/>\n  Verifying               : mysql-libs-5.1.73-5.el6_6.x86_64                                    7\/7<\/p>\n<p>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb:<br \/>\n  mysql-community-libs.x86_64 0:5.6.26-2.el6     mysql-community-libs-compat.x86_64 0:5.6.26-2.el6<br \/>\n  mysql-community-server.x86_64 0:5.6.26-2.el6<\/p>\n<p>\u4f9d\u5b58\u6027\u95a2\u9023\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3057\u305f:<br \/>\n  mysql-community-client.x86_64 0:5.6.26-2.el6     mysql-community-common.x86_64 0:5.6.26-2.el6<br \/>\n  perl-DBI.x86_64 0:1.609-4.el6<\/p>\n<p>\u7f6e\u63db:<br \/>\n  mysql-libs.x86_64 0:5.1.73-5.el6_6<\/p>\n<p>\u5b8c\u4e86\u3057\u307e\u3057\u305f!<br \/>\n[\/bash]<\/p>\n<p><strong>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u305fMySQL\u306e\u30d0\u30fc\u30b8\u30e7\u30f3\u306e\u78ba\u8a8d<\/strong><\/p>\n<p>[bash]<br \/>\n$ mysqld &#8211;version<br \/>\n mysqld  Ver 5.6.26 for Linux on x86_64 (MySQL Community Server (GPL))<br \/>\n[\/bash]<\/p>\n<p><strong>\u81ea\u52d5\u8d77\u52d5\u306e\u8a2d\u5b9a<\/strong><\/p>\n<p>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u5f8c\u306f\u3001\u81ea\u52d5\u8d77\u52d5\u304coff\u306b\u306a\u3063\u3066\u3044\u308b\u306e\u3067\u3001\u81ea\u52d5\u8d77\u52d5\u3059\u308b\u3088\u3046\u306b\u8a2d\u5b9a\u3059\u308b\u3002<\/p>\n<p>[bash]<br \/>\n$ chkconfig mysqld &#8211;list<br \/>\nmysqld          0:off   1:off   2:off   3:off   4:off   5:off   6:off<br \/>\n$ chkconfig mysqld on<br \/>\n$ chkconfig mysqld &#8211;list<br \/>\nmysqld          0:off   1:off   2:on    3:on    4:on    5:on    6:off<br \/>\n[\/bash]<\/p>\n<p><strong>MySQL\u306e\u8d77\u52d5<\/strong><\/p>\n<p>[bash]<br \/>\n$ service mysqld start<br \/>\nMySQL \u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3092\u521d\u671f\u5316\u4e2d:  2015-08-10 14:06:31 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use &#8211;explicit_defaults_for_timestamp server option (see documentation for more details).<br \/>\n2015-08-10 14:06:31 0 [Note] \/usr\/sbin\/mysqld (mysqld 5.6.26) starting as process 24192 &#8230;<br \/>\n2015-08-10 14:06:31 24192 [Note] InnoDB: Using atomics to ref count buffer pool pages<br \/>\n2015-08-10 14:06:31 24192 [Note] InnoDB: The InnoDB memory heap is disabled<\/p>\n<p>a new database to be created!<\/p>\n<p>&#8230;<br \/>\n                                                           [  OK  ]<br \/>\nmysqld \u3092\u8d77\u52d5\u4e2d:                                           [  OK  ]<br \/>\n[\/bash]<\/p>\n<p><strong>root\u30d1\u30b9\u30ef\u30fc\u30c9\u306e\u5909\u66f4<\/strong><\/p>\n<p>[bash]<br \/>\n$ \/usr\/bin\/mysqladmin -u root password &#8216;new-password&#8217;<br \/>\n[\/bash]<\/p>\n<p><strong>\u30c7\u30d5\u30a9\u30eb\u30c8\u6587\u5b57\u30b3\u30fc\u30c9\u306e\u5909\u66f4<\/strong><\/p>\n<p>\u30c7\u30d5\u30a9\u30eb\u30c8\u3067\u306f\u3001\u6587\u5b57\u30b3\u30fc\u30c9\u304c\u4e0b\u8a18\u306e\u3088\u3046\u306b\u306a\u3063\u3066\u3044\u308b\u3002<\/p>\n<p>[bash]<br \/>\nmysql&gt; show variables like &#8216;character_set%&#8217;;<br \/>\n+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-+<br \/>\n| Variable_name            | Value                      |<br \/>\n+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-+<br \/>\n| character_set_client     | utf8                       |<br \/>\n| character_set_connection | utf8                       |<br \/>\n| character_set_database   | latin1                     |<br \/>\n| character_set_filesystem | binary                     |<br \/>\n| character_set_results    | utf8                       |<br \/>\n| character_set_server     | latin1                     |<br \/>\n| character_set_system     | utf8                       |<br \/>\n| character_sets_dir       | \/usr\/share\/mysql\/charsets\/ |<br \/>\n+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-+<br \/>\n8 rows in set (0.01 sec)<br \/>\n[\/bash]<\/p>\n<p>\u305d\u3053\u3067\u3001\/etc\/my.cnf \u306e\u8a2d\u5b9a\u306b\u8ffd\u8a18\u3059\u308b\u3002<\/p>\n<p>[bash]<br \/>\n[mysqld]<br \/>\ncharacter-set-server=utf8<\/p>\n<p>[mysql]<br \/>\ndefault-character-set=utf8<br \/>\n[\/bash]<\/p>\n<p>MySQL\u30b5\u30fc\u30d0\u306e\u518d\u8d77\u52d5\u3002<\/p>\n<p>[bash]<br \/>\n$ service mysqld restart<br \/>\n[\/bash]<\/p>\n<p>\u30c7\u30d5\u30a9\u30eb\u30c8\u6587\u5b57\u30b3\u30fc\u30c9\u306e\u8a2d\u5b9a\u306e\u78ba\u8a8d\u3092\u3059\u308b\u3002<\/p>\n<p>[bash]<br \/>\nmysql&gt; show variables like &#8216;character_set%&#8217;;<br \/>\n+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-+<br \/>\n| Variable_name            | Value                      |<br \/>\n+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-+<br \/>\n| character_set_client     | utf8                       |<br \/>\n| character_set_connection | utf8                       |<br \/>\n| character_set_database   | utf8                       |<br \/>\n| character_set_filesystem | binary                     |<br \/>\n| character_set_results    | utf8                       |<br \/>\n| character_set_server     | utf8                       |<br \/>\n| character_set_system     | utf8                       |<br \/>\n| character_sets_dir       | \/usr\/share\/mysql\/charsets\/ |<br \/>\n+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-+<br \/>\n8 rows in set (0.00 sec)<br \/>\n[\/bash]<\/p>\n<p>latin1 \u3067\u3042\u3063\u305f\u90e8\u5206\u304c utf8 \u306b\u5909\u66f4\u3055\u308c\u305f\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4e45\u3057\u3076\u308a\u306bMySQL\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3002 \u3053\u306e\u624b\u306e\u8a2d\u5b9a\u306f\u30012\u5e74\u306b\u4e00\u5ea6\u304f\u3089\u3044\u3057\u304b\u3057\u306a\u3044\u306e\u3067\u899a\u3048\u66f8\u304d\u3002 OS : CentOS6.7 \u305d\u3046\u3044\u3048\u3070\u3001\u524d\u56de\u306f\u3001CentOS 5.8\u306bMySQL5.5 \u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u3044\u305f\u3002 \u3057\u304b\u3082  [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"saved_in_kubio":false,"footnotes":""},"categories":[5,11,4],"tags":[],"class_list":["post-2290","post","type-post","status-publish","format-standard","hentry","category-centos","category-mysql","category-tech"],"_links":{"self":[{"href":"https:\/\/www.blowfish.co.jp\/index.php?rest_route=\/wp\/v2\/posts\/2290","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.blowfish.co.jp\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.blowfish.co.jp\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.blowfish.co.jp\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.blowfish.co.jp\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2290"}],"version-history":[{"count":11,"href":"https:\/\/www.blowfish.co.jp\/index.php?rest_route=\/wp\/v2\/posts\/2290\/revisions"}],"predecessor-version":[{"id":2301,"href":"https:\/\/www.blowfish.co.jp\/index.php?rest_route=\/wp\/v2\/posts\/2290\/revisions\/2301"}],"wp:attachment":[{"href":"https:\/\/www.blowfish.co.jp\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2290"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.blowfish.co.jp\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2290"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.blowfish.co.jp\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2290"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}