 {"id":568,"date":"2012-12-06T14:25:59","date_gmt":"2012-12-06T06:25:59","guid":{"rendered":"http:\/\/www.qyuef.com\/?p=568"},"modified":"2012-12-06T14:25:59","modified_gmt":"2012-12-06T06:25:59","slug":"%e6%9e%ab%e5%8f%b6%e5%8d%9a%e5%ae%a2%e5%91%8a%e8%af%89%e4%bd%a0%e5%bf%98%e8%ae%b0%e4%ba%86mysql%e7%9a%84root%e5%af%86%e7%a0%81%e6%80%8e%e4%b9%88%e5%8a%9e%ef%bc%9f","status":"publish","type":"post","link":"http:\/\/www.qyuef.com\/?p=568","title":{"rendered":"\u67ab\u53f6\u535a\u5ba2\u544a\u8bc9\u4f60\u5fd8\u8bb0\u4e86mysql\u7684root\u5bc6\u7801\u600e\u4e48\u529e\uff1f"},"content":{"rendered":"<p>mysql\u6709\u65f6\u5019\u5fd8\u8bb0\u5bc6\u7801\u4e86\u600e\u4e48\u529e?\u6211\u7ed9\u51fa\u6848\u4f8b\u548c\u8bf4\u660e!\u4e00\u4e0b\u5c31\u89e3\u51b3\u4e86!<\/p>\n<p>\n\t\u3000\u3000Windows\u4e0b\u7684\u5b9e\u9645\u64cd\u4f5c\u5982\u4e0b<\/p>\n<p>\n\t\u3000\u30001.\u5173\u95ed\u6b63\u5728\u8fd0\u884c\u7684MySQL\u3002<\/p>\n<p>\n\t\u3000\u30002.\u6253\u5f00DOS\u7a97\u53e3\uff0c\u8f6c\u5230mysql\\bin\u76ee\u5f55\u3002<\/p>\n<p>\n\t\u3000\u30003.\u8f93\u5165mysqld &#8211;skip-grant-tables\u56de\u8f66\u3002\u5982\u679c\u6ca1\u6709\u51fa\u73b0\u63d0\u793a\u4fe1\u606f\uff0c\u90a3\u5c31\u5bf9\u4e86\u3002<\/p>\n<p>\n\t\u3000\u30004.\u518d\u5f00\u4e00\u4e2aDOS\u7a97\u53e3(\u56e0\u4e3a\u521a\u624d\u90a3\u4e2aDOS\u7a97\u53e3\u5df2\u7ecf\u4e0d\u80fd\u52a8\u4e86)\uff0c\u8f6c\u5230mysql\\bin\u76ee\u5f55\u3002<\/p>\n<p>\n\t\u3000\u30005.\u8f93\u5165mysql\u56de\u8f66\uff0c\u5982\u679c\u6210\u529f\uff0c\u5c06\u51fa\u73b0MySQL\u63d0\u793a\u7b26 &gt;<\/p>\n<p>\n\t\u3000\u30006. \u8fde\u63a5\u6743\u9650\u6570\u636e\u5e93&gt;use mysql; (&gt;\u662f\u672c\u6765\u5c31\u6709\u7684\u63d0\u793a\u7b26,\u522b\u5fd8\u4e86\u6700\u540e\u7684\u5206\u53f7)<\/p>\n<p>\n\t\u3000\u30006.\u6539\u5bc6\u7801\uff1a&gt; update user set password=password(&quot;123456&quot;) where user=&quot;root&quot;; (\u522b\u5fd8\u4e86\u6700\u540e\u7684\u5206\u53f7)<\/p>\n<p>\n\t\u3000\u30007.\u5237\u65b0\u6743\u9650(\u5fc5\u987b\u7684\u6b65\u9aa4)&gt;flush privileges;<\/p>\n<p>\n\t\u3000\u30008.\u9000\u51fa &gt; \\q<\/p>\n<p>\n\t\u3000\u30009.\u6ce8\u9500\u7cfb\u7edf\uff0c\u518d\u8fdb\u5165\uff0c\u5f00MySQL\uff0c\u4f7f\u7528\u7528\u6237\u540droot\u548c\u521a\u624d\u8bbe\u7f6e\u7684\u65b0\u5bc6\u7801123456\u767b\u9646\u3002<\/p>\n<p>\n\t\u3000\u3000\u7b2c\u4e00\u6b65<\/p>\n<p>\n\t\u3000\u3000C:\\Documents and Settings\\Administrator&gt;cd D:\\web\\www.qyuef.com\\Mysql\\MySQL Se<\/p>\n<p>\n\t\u3000\u3000rver5.5\\bin<\/p>\n<p>\n\t\u3000\u3000C:\\Documents and Settings\\Administrator&gt;d:<\/p>\n<p>\n\t\u3000\u3000D:\\web\\www.qyuef.com\\Mysql\\MySQL Server5.5\\bin&gt;mysqld &#8211;skip-grant-tables<\/p>\n<p>\n\t\u3000\u3000\u7b2c\u4e8c\u6b65<\/p>\n<p>\n\t\u3000\u3000Microsoft Windows [\u7248\u672c 5.2.3790]\n<p>\n\t\u3000\u3000(C) \u7248\u6743\u6240\u6709 1985-2003 Microsoft Corp.<\/p>\n<p>\n\t\u3000\u3000C:\\Documents and Settings\\Administrator&gt;cd D:\\web\\www.qyuef.comMysql\\MySQL Se<\/p>\n<p>\n\t\u3000\u3000rver5.5\\bin<\/p>\n<p>\n\t\u3000\u3000C:\\Documents and Settings\\Administrator&gt;d:<\/p>\n<p>\n\t\u3000\u3000D:\\web\\www.qyuef.com\\Mysql\\MySQL Server5.5\\bin&gt;mysql<\/p>\n<p>\n\t\u3000\u3000Welcome to the MySQL monitor. Commands end with ; or \\g.<\/p>\n<p>\n\t\u3000\u3000Your MySQL connection id is 1<\/p>\n<p>\n\t\u3000\u3000Server version: 5.5.10 MySQL Community Server (GPL)<\/p>\n<p>\n\t\u3000\u3000Copyright (c) 2000, 2010, Oracle and\/or its affiliates. All rights reserved.<\/p>\n<p>\n\t\u3000\u3000Oracle is a registered trademark of Oracle Corporation and\/or its<\/p>\n<p>\n\t\u3000\u3000affiliates. Other names may be trademarks of their respective<\/p>\n<p>\n\t\u3000\u3000owners.<\/p>\n<p>\n\t\u3000\u3000Type &#39;help;&#39; or &#39;\\h&#39; for help. Type &#39;\\c&#39; to clear the current input statement.<\/p>\n<p>\n\t\u3000\u3000mysql&gt; use mysql;<\/p>\n<p>\n\t\u3000\u3000Database changed<\/p>\n<p>\n\t\u3000\u3000mysql&gt; update user set password=password(&quot;123456&quot;) where user=&quot;root&quot;;<\/p>\n<p>\n\t\u3000\u3000Query OK, 1 row affected (0.00 sec)<\/p>\n<p>\n\t\u3000\u3000Rows matched: 1 Changed: 1 Warnings: 0<\/p>\n<p>\n\t\u3000\u3000mysql&gt; flush privileges;<\/p>\n<p>\n\t\u3000\u3000Query OK, 0 rows affected (0.00 sec)<\/p>\n<p>\n\t\u3000\u3000mysql&gt; \\q<\/p>\n<p>\n\t\u3000\u3000Bye<\/p>\n<p>\n\t\u3000\u3000D:\\web\\www.qyuef.com\\Mysql\\MySQL Server5.5\\bin&gt;<\/p>\n<p><!--\u5185\u5bb9\u5173\u8054\u6295\u7968--><\/p>\n","protected":false},"excerpt":{"rendered":"<p>mysql\u6709\u65f6\u5019\u5fd8\u8bb0\u5bc6\u7801\u4e86\u600e\u4e48\u529e?\u6211\u7ed9\u51fa\u6848\u4f8b\u548c\u8bf4\u660e!\u4e00\u4e0b\u5c31\u89e3\u51b3\u4e86! Windows\u4e0b\u7684\u5b9e\u9645\u64cd\u4f5c\u5982\u4e0b 1.\u5173\u95ed\u6b63\u5728\u8fd0\u884c\u7684MySQL\u3002 2.\u6253\u5f00DOS\u7a97\u53e3\uff0c\u8f6c\u5230mysql\\bin\u76ee\u5f55\u3002 3.\u8f93\u5165mysqld &#8211;skip-grant-tables\u56de\u8f66\u3002\u5982\u679c\u6ca1\u6709\u51fa\u73b0\u63d0\u793a\u4fe1\u606f\uff0c\u90a3\u5c31\u5bf9\u4e86\uff01<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[6],"tags":[25,33],"tcat":[],"_links":{"self":[{"href":"http:\/\/www.qyuef.com\/index.php?rest_route=\/wp\/v2\/posts\/568"}],"collection":[{"href":"http:\/\/www.qyuef.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.qyuef.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.qyuef.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.qyuef.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=568"}],"version-history":[{"count":0,"href":"http:\/\/www.qyuef.com\/index.php?rest_route=\/wp\/v2\/posts\/568\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.qyuef.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=568"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.qyuef.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=568"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.qyuef.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=568"},{"taxonomy":"tcat","embeddable":true,"href":"http:\/\/www.qyuef.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftcat&post=568"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}