﻿{"id":275,"date":"2013-02-18T17:39:01","date_gmt":"2013-02-19T01:39:01","guid":{"rendered":"http:\/\/www.anvilsoftcraft.com\/weblog\/?p=275"},"modified":"2013-02-18T17:39:01","modified_gmt":"2013-02-19T01:39:01","slug":"mysql-%e3%83%a6%e3%83%bc%e3%82%b6%e3%81%ae%e8%bf%bd%e5%8a%a0","status":"publish","type":"post","link":"https:\/\/www.anvilsoftcraft.com\/weblog\/?p=275","title":{"rendered":"MySQL \u30e6\u30fc\u30b6\u306e\u8ffd\u52a0"},"content":{"rendered":"<p>\u3057\u3070\u3089\u304fMySQL\u304b\u3089\u9060\u3056\u304b\u3063\u3066\u3044\u305f\u306e\u3067\u30b3\u30de\u30f3\u30c9\u30e9\u30a4\u30f3\u304b\u3089\u306e\u30e6\u30fc\u30b6\u8ffd\u52a0\u3092\u5fd8\u308c\u3066\u3057\u307e\u3063\u3066\u3044\u305f\u3002\u3002\u3002\u3068\u3044\u3046\u308f\u3051\u3067\u30e1\u30e2\u3002<br \/>\n<a href=\"http:\/\/dev.mysql.com\/doc\/refman\/5.1\/ja\/adding-users.html\" target=\"_blank\">\u8a73\u7d30\u306f\u3053\u3053<\/a>\u306b\u66f8\u3044\u3066\u3042\u308b\u304c\u6700\u521d\u304b\u3089GRANT\u3059\u308b\u3068\u30a8\u30e9\u30fc\u306b\u306a\u3063\u3066\u3057\u307e\u3063\u305f\u306e\u3067CREATE USER\u304b\u3089\u5b9f\u884c\u3002<\/p>\n<p>\u30eb\u30fc\u30c8\u6a29\u9650\u3067\u307e\u305a\u30ed\u30b0\u30a4\u30f3<\/p>\n<p>mysql -u root -p<br \/>\nEnter password: xxxxxx\u00a0 \u3000\u3000\u3000\u3000&lt;-\u3053\u3053\u3067\u30d1\u30b9\u30ef\u30fc\u30c9\u5165\u529b<\/p>\n<p>mysql&gt;CREATE USER testuser IDENTIFIED BY &#8216;testpasswd&#8217;;<\/p>\n<p>\u3053\u308c\u3067\u2019testuser\u2019\u3068\u3044\u3046\u30e6\u30fc\u30b6\u540d\u3067\u2019testpasswd\u2019\u3068\u3044\u3046\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u6301\u3063\u305f\u30e6\u30fc\u30b6\u304c\u8ffd\u52a0\u3055\u308c\u308b\u3002\u6700\u521d\u306f\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u30b7\u30f3\u30b0\u30eb\u30af\u30aa\u30fc\u30c8\u3067\u62ec\u308b\u306e\u3092\u5fd8\u308c\u3066\u3044\u3066\u30a8\u30e9\u30fc\u306b\u306a\u3063\u3066\u3044\u305f\u3002<\/p>\n<p>\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u8a2d\u5b9a\/\u5909\u66f4\u3059\u308b\u306b\u306f<br \/>\nSET PASSWORD FOR testuser = PASSWORD(&#8216;testpasswd2&#8217;);<\/p>\n<p>\u3053\u308c\u3067testuser\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u3092testpassed2\u306b\u5909\u66f4\u3055\u308c\u308b\u3002\u306a\u304apassword\u95a2\u6570\u3067\u6697\u53f7\u5316\u3057\u306a\u3044\u3068\u3044\u3051\u306a\u3044\u306e\u3067\u6ce8\u610f\u3002<\/p>\n<p>GRANT ALL TO user&#8230;\u306f\u4e0a\u8a18\u30e6\u30fc\u30b6\u4f5c\u6210\u5f8c\u306b\u3059\u308b\u3079\u304d\u6a29\u9650\u8a2d\u5b9a\u3067\u3001\u30e6\u30fc\u30b6\u4f5c\u6210\u5f8c\u306b\u4e0b\u8a18\u30b3\u30de\u30f3\u30c9\u3067\u6a29\u9650\u3092\u8a2d\u5b9a\u3002<\/p>\n<p>GRANT ALL PRIVILEGES ON *.* TO testuser IDENTIFIED BY &#8216;testpasswd2&#8217;;<\/p>\n<p>\u3042\u3068\u306fSHOW GRANT\u3067\u6a29\u9650\u3092\u78ba\u8a8d<\/p>\n<p>SHOW GRANTS FOR testuser;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3057\u3070\u3089\u304fMySQL\u304b\u3089\u9060\u3056\u304b\u3063\u3066\u3044\u305f\u306e\u3067\u30b3\u30de\u30f3\u30c9\u30e9\u30a4\u30f3\u304b\u3089\u306e\u30e6\u30fc\u30b6\u8ffd\u52a0\u3092\u5fd8\u308c\u3066\u3057\u307e\u3063\u3066\u3044\u305f\u3002\u3002\u3002\u3068\u3044\u3046\u308f\u3051\u3067\u30e1\u30e2\u3002 \u8a73\u7d30\u306f\u3053\u3053\u306b\u66f8\u3044\u3066\u3042\u308b\u304c\u6700\u521d\u304b\u3089GRANT\u3059\u308b\u3068\u30a8\u30e9\u30fc\u306b\u306a\u3063\u3066\u3057\u307e\u3063\u305f\u306e\u3067CREATE USER\u304b\u3089\u5b9f\u884c &hellip; <a href=\"https:\/\/www.anvilsoftcraft.com\/weblog\/?p=275\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5,6],"tags":[],"class_list":["post-275","post","type-post","status-publish","format-standard","hentry","category-software-development","category-6"],"_links":{"self":[{"href":"https:\/\/www.anvilsoftcraft.com\/weblog\/index.php?rest_route=\/wp\/v2\/posts\/275","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.anvilsoftcraft.com\/weblog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.anvilsoftcraft.com\/weblog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.anvilsoftcraft.com\/weblog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.anvilsoftcraft.com\/weblog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=275"}],"version-history":[{"count":0,"href":"https:\/\/www.anvilsoftcraft.com\/weblog\/index.php?rest_route=\/wp\/v2\/posts\/275\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.anvilsoftcraft.com\/weblog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=275"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.anvilsoftcraft.com\/weblog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=275"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.anvilsoftcraft.com\/weblog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=275"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}