{"id":2232,"date":"2014-05-01T21:08:00","date_gmt":"2014-05-01T13:08:00","guid":{"rendered":"http:\/\/www.zuola.com\/weblog\/2014\/05\/2232.htm"},"modified":"2014-05-01T21:08:00","modified_gmt":"2014-05-01T13:08:00","slug":"ubuntu%e4%b8%8b%e7%9a%84mysql%e8%87%aa%e5%8a%a8%e5%81%9c%e6%ad%a2%e7%9a%84%e8%a7%a3%e5%86%b3%e6%96%b9%e6%a1%88","status":"publish","type":"post","link":"https:\/\/www.zuola.com\/weblog\/2014\/05\/2232.htm","title":{"rendered":"Ubuntu\u4e0b\u7684mysql\u81ea\u52a8\u505c\u6b62\u7684\u89e3\u51b3\u65b9\u6848"},"content":{"rendered":"<p>mysql\u8001\u662f\u81ea\u52a8\u505c\u6b62\uff0c\u5bfc\u81f4wordpress\u8fde\u63a5\u6570\u636e\u5e93\u5931\u8d25\uff0c\u4e8e\u662f\u6211\u53bb<a href=\"https:\/\/twitter.com\/zuola\/status\/461749059863056385\">\u6c42\u52a9\u4f1f\u5927\u7684\u63a8\u795e<\/a>:&nbsp;\u6211\u7684digtalocean\u4e0aVPS\u4e0a\u7684mysql\u6570\u636e\u5e93\u8001\u662f\u81ea\u52a8\u505c\u6389\uff0c\u8fd9\u662f\u600e\u4e48\u56de\u4e8b\u554a\uff1f\u6211\u7528\u7684\u64cd\u4f5c\u7cfb\u7edf\u662f Ubuntu 12.10 , \/var\/log\/ \u5e95\u4e0b \u7684mysqld.log mysql.err &nbsp;mysql.log \u90fd\u662f\u7a7a\u7684\uff0c\u4e0d\u77e5\u9053\u53d1\u751f\u4ec0\u4e48\u4e8b\u4e86.\u8fc7\u4e86\u4e00\u4f1a\u513f\uff0c\u5927\u795e\u51fa\u73b0\u4e86\uff1a<\/p>\n<blockquote lang=\"zh-cn\"><p><a href=\"https:\/\/twitter.com\/zuola\">@zuola<\/a> \u770bdmesg\u6709\u65e0\u7cfb\u7edf\u7ea7\u9519\u8bef\uff0c\u6211\u9047\u5230\u8fc7\u6570\u636e\u5e93\u5206\u914d\u7684\u5185\u5b58\u8fc7\u591a\u88ab\u7cfb\u7edf\u7ed9\u6740\u6b7b\u4e86<br \/>\u2014 \u8717\u725b(sn)\u2026\u2026 (@ZealYi) <a href=\"https:\/\/twitter.com\/ZealYi\/statuses\/461752588442955776\">2014\u5e745\u67081\u65e5<\/a><\/p><\/blockquote>\n<p>\u6211\u8f93\u5165dmesg\uff0c\u679c\u7136\u53d1\u73b0mysql respawning too fast,\u7684\u5b57\u6837\u4e86<\/p>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[422425.267037] send sigkill to 5605 (mysqld), adj 0, size 16693<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[422425.348455] init: mysql main process (5605) killed by KILL signal<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[422425.356550] init: mysql main process ended, respawning<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[422425.811580] init: mysql main process (10805) terminated with status 1<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[422425.811629] init: mysql main process ended, respawning<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[422426.728623] init: mysql post-start process (10806) terminated with status 1<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[422426.779367] init: mysql main process (10840) terminated with status 1<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[422426.779402] init: mysql respawning too fast, stopped<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452934.665293] select 1 (init), adj 0, size 285, to kill<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452934.665301] select 379 (rsyslogd), adj 0, size 695, to kill<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452934.665304] select 1006 (apache2), adj 0, size 1975, to kill<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452934.665306] select 18429 (apache2), adj 0, size 10799, to kill<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452934.665309] select 11546 (mysqld), adj 0, size 16458, to kill<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452934.665311] send sigkill to 11546 (mysqld), adj 0, size 16458<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452934.761547] init: mysql main process (11546) killed by KILL signal<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452934.768425] init: mysql main process ended, respawning<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452935.139794] init: mysql main process (17045) terminated with status 1<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452935.139829] init: mysql main process ended, respawning<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452935.157952] init: mysql post-start process (17046) terminated with status 1<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452935.207468] init: mysql main process (17072) terminated with status 1<\/div>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">[452935.207501] init: mysql respawning too fast, stopped<\/div>\n<p>\u4e0a\u7f51\u641c\u7d22&nbsp;mysql respawning too fast\uff0c\u627e\u5230<br \/><a href=\"http:\/\/askubuntu.com\/questions\/127264\/cant-start-mysql-mysql-respawning-too-fast-stopped\">http:\/\/askubuntu.com\/questions\/127264\/cant-start-mysql-mysql-respawning-too-fast-stopped<\/a><\/p>\n<p>\u89e3\u51b3\u529e\u6cd5\u662f<br \/>dpkg-reconfigure mysql-server-5.5<br \/>\u4e0d\u8981\u5148\u5220\u9664\u4f4e\u7248\u672c\u7684mysql<\/p>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">apt-get remove mysql-server-5.5<\/div>\n<p>\u518d\u5b89\u88c5<br \/>&nbsp;<span style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">apt-get install mysql-server-5.5<\/span><\/p>\n<p>\u7136\u540e\u624d\u80fd\u4f7f\u7528<\/p>\n<div style=\"background-color: black; color: #29f914; font-family: 'Andale Mono'; font-size: 12px;\">dpkg-reconfigure mysql-server-5.5<\/div>\n<p>\u5148\u8bd5\u8bd5\u770b\uff0c\u597d\u50cfmysql\u8fd8\u4f1a\u4e0d\u4f1a\u81ea\u52a8\u505c\u6b62\u6389\u4e86\u3002<\/p>\n<p>\u9020\u6210mysql\u81ea\u52a8\u505c\u6b62\u7684\u539f\u56e0\u4f3c\u4e4e\u662f\u5b57\u7b26\u7f16\u7801\u95ee\u9898,\u4e0d\u4f7f\u7528\u4e0a\u9762\u7684\u65b9\u6cd5\uff0c\u53ef\u4ee5\u76f4\u63a5\u4fee\u6539 \/etc\/mysql\/my.cnf &nbsp;\u6587\u4ef6<\/p>\n<p>\u8981\u4fee\u6539 \/etc\/mysql\/my.cnf \u91cc\u7684 &nbsp;[client]\u548c[myslqd] \u4e2d\u7684\u5185\u5bb9\uff0c\u6dfb\u52a0\u6307\u5b9a\u5b57\u4f53\u7f16\u7801<br \/>&nbsp;[client]<br \/>default-character-set=utf8<\/p>\n<div><\/div>\n<div>[myslqd]<br \/>character_set_server=utf8<br \/>collation_server = utf8_general_ci<\/div>\n<div>\u518dreboot\u670d\u52a1\u5668\uff0c\u7136\u540edmesg,\u679c\u7136\u6ca1\u6709 mysql respawning too fast\u3002\u534a\u5929\u8fc7\u53bb\u4e86\uff0cwordpress\u4e5f\u6ca1\u6709\u51fa\u73b0\u65e0\u6cd5\u94fe\u63a5\u6570\u636e\u5e93\u4e86\u3002<\/p>\n<\/div>\n<div>\u53c2\u8003\u94fe\u63a5\uff1a<\/div>\n<div><a href=\"http:\/\/gm100861.blog.51cto.com\/1930562\/896173\">http:\/\/gm100861.blog.51cto.com\/1930562\/896173<\/a>&nbsp;<\/div>\n<div>\u6765\u81ea\u5468\u66d9\u5149\u7684BLOGSPOT\u7a7a\u95f4<\/div>\n","protected":false},"excerpt":{"rendered":"<p>mysql\u8001\u662f\u81ea\u52a8\u505c\u6b62\uff0c\u5bfc\u81f4wordpress\u8fde\u63a5\u6570\u636e\u5e93\u5931\u8d25\uff0c\u4e8e\u662f\u6211\u53bb\u6c42\u52a9\u4f1f\u5927\u7684 <span class=\"readmore\"><a href=\"https:\/\/www.zuola.com\/weblog\/2014\/05\/2232.htm\">Continue Reading &#8230;<\/a><\/span><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-2232","post","type-post","status-publish","format-standard","hentry","category-random"],"views":109,"_links":{"self":[{"href":"https:\/\/www.zuola.com\/weblog\/wp-json\/wp\/v2\/posts\/2232","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.zuola.com\/weblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.zuola.com\/weblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.zuola.com\/weblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.zuola.com\/weblog\/wp-json\/wp\/v2\/comments?post=2232"}],"version-history":[{"count":0,"href":"https:\/\/www.zuola.com\/weblog\/wp-json\/wp\/v2\/posts\/2232\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.zuola.com\/weblog\/wp-json\/wp\/v2\/media?parent=2232"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.zuola.com\/weblog\/wp-json\/wp\/v2\/categories?post=2232"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.zuola.com\/weblog\/wp-json\/wp\/v2\/tags?post=2232"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}