{"id":3122,"date":"2021-08-09T23:35:43","date_gmt":"2021-08-09T14:35:43","guid":{"rendered":"https:\/\/obenkyolab.com\/?p=3122"},"modified":"2022-01-17T06:56:40","modified_gmt":"2022-01-16T21:56:40","slug":"%e3%80%90mysql%e3%80%91phpmyadmin%e3%81%a7%e3%83%87%e3%83%bc%e3%82%bf%e3%83%99%e3%83%bc%e3%82%b9%e3%81%8c%e8%a6%8b%e3%81%88%e3%81%aa%e3%81%84%e5%a0%b4%e5%90%88%e3%81%ae%e5%af%be%e5%87%a6%e6%b3%95","status":"publish","type":"post","link":"https:\/\/obenkyolab.com\/?p=3122","title":{"rendered":"\u3010MySQL\u3011phpMyAdmin\u3067\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u304c\u898b\u3048\u306a\u3044\u5834\u5408\u306e\u5bfe\u51e6\u6cd5"},"content":{"rendered":"\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_80 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/obenkyolab.com\/?p=3122\/#%E7%97%87%E7%8A%B6\" >\u75c7\u72b6<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/obenkyolab.com\/?p=3122\/#%E8%AA%BF%E6%9F%BB\" >\u8abf\u67fb<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/obenkyolab.com\/?p=3122\/#%E5%8E%9F%E5%9B%A0\" >\u539f\u56e0<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/obenkyolab.com\/?p=3122\/#%E5%AF%BE%E5%87%A6\" >\u5bfe\u51e6<\/a><\/li><\/ul><\/nav><\/div>\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E7%97%87%E7%8A%B6\"><\/span>\u75c7\u72b6<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>phpMyAdmin\u3067MySQL\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u3092\u5b9f\u65bd\u3057\u3088\u3046\u3068\u601d\u3044\u3001\u30ed\u30b0\u30a4\u30f3\u3057\u305f\u3068\u3053\u308d\u4f55\u6545\u304binformation_schema\u3057\u304b\u8868\u793a\u3055\u308c\u307e\u305b\u3093\u3067\u3057\u305f\u3002<\/p>\n\n\n\n<figure class=\"wp-block-image size-large waku\"><img loading=\"lazy\" decoding=\"async\" width=\"700\" height=\"255\" src=\"https:\/\/obenkyolab.com\/wp-content\/uploads\/2021\/08\/image-1-700x255.png\" alt=\"\" class=\"wp-image-3124\" srcset=\"https:\/\/obenkyolab.com\/wp-content\/uploads\/2021\/08\/image-1-700x255.png 700w, https:\/\/obenkyolab.com\/wp-content\/uploads\/2021\/08\/image-1-300x109.png 300w, https:\/\/obenkyolab.com\/wp-content\/uploads\/2021\/08\/image-1-768x279.png 768w, https:\/\/obenkyolab.com\/wp-content\/uploads\/2021\/08\/image-1.png 1256w\" sizes=\"auto, (max-width: 700px) 100vw, 700px\" \/><\/figure>\n\n\n\n<p>\u30ed\u30b0\u30a4\u30f3\u306b\u4f7f\u7528\u3057\u305fMySQL\u30e6\u30fc\u30b6\u306f\u5168\u6a29\u3092GRANT\u3057\u3066\u304a\u308a\u3001\u666e\u6bb5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u63a5\u7d9a\u3057\u3066\u3044\u308b\u3068\u304d\u306f\u3059\u3079\u3066\u306e\u30c7\u30fc\u30bf\u3079\u304c\u898b\u3048\u3066\u3044\u308b\u72b6\u614b\u306a\u306e\u3067\u3001\u306a\u305c\uff1f\uff1f\u3068\u306a\u308a\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>\u3000<\/p>\n\n\n\n<p>\u3000<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>\u57fa\u672c\u304b\u3089php&amp;MySQL\u3092\u5b66\u3073\u305f\u3044\u3068\u304d\u306f\u672c\u304c\u304a\u3059\u3059\u3081\u3067\u3059\u3002<\/p>\n\n\n\n<iframe style=\"width:120px;height:240px;\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\" frameborder=\"0\" src=\"https:\/\/rcm-fe.amazon-adsystem.com\/e\/cm?ref=tf_til&amp;t=sebone0f-22&amp;m=amazon&amp;o=9&amp;p=8&amp;l=as1&amp;IS2=1&amp;detail=1&amp;asins=4873113652&amp;linkId=5649da2921d32e56ce1db74e6fbe6c13&amp;bc1=000000&amp;lt1=_blank&amp;fc1=333333&amp;lc1=0066c0&amp;bg1=ffffff&amp;f=ifr\">\n    <\/iframe>\n\n\n\n<p>\u3000<\/p>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E8%AA%BF%E6%9F%BB\"><\/span>\u8abf\u67fb<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>\u4ee5\u4e0b\u306eSQL\u3092\u5b9f\u884c\u3057\u3001\u30e6\u30fc\u30b6\u6bce\u306e\u6a29\u9650\u3092\u78ba\u8a8d\u3057\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-sql\" data-lang=\"SQL\"><code>--\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u6307\u5b9a\nUSE mysql;\n\n--\u30e6\u30fc\u30b6\u78ba\u8a8d\nSELECT user, host FROM user;<\/code><\/pre><\/div>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: sql; title: ; notranslate\" title=\"\">\n\n<\/pre><\/div>\n\n\n<p>\u4eca\u56de\u4f7f\u7528\u3057\u3066\u3044\u308b\u30e6\u30fc\u30b6\u3092\u4eee\u306buser01\u3001MySQL\u30b5\u30fc\u30d0\u30fc\u306eIP\u30a2\u30c9\u30ec\u30b9\u3092192.168.1.1\u3068\u3059\u308b\u3068\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u7d50\u679c\u3068\u306a\u308a\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<figure class=\"wp-block-table is-style-regular\"><table><thead><tr><th>user<\/th><th>host<\/th><\/tr><\/thead><tbody><tr><td>user01<\/td><td>%<\/td><\/tr><tr><td>root<\/td><td>127.0.0.1<\/td><\/tr><tr><td>user01<\/td><td>192.168.1.%<\/td><\/tr><tr><td>root<\/td><td>::1<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>\u7d50\u679c\u3092\u898b\u308b\u9650\u308ahost\u5358\u4f4d\u3067user01\u3092\u78ba\u8a8d\u3059\u308b\u5fc5\u8981\u304c\u3042\u308b\u6c17\u304c\u3042\u308a\u305d\u3046\u3060\u3063\u305f\u305f\u3081\u3001\u3055\u3089\u306b\u4ee5\u4e0b\u306eSQL\u3067host\u5358\u4f4d\u306e\u6a29\u9650\u4ed8\u4e0e\u72b6\u6cc1\u3092\u78ba\u8a8d\u3057\u3066\u307f\u308b\u3053\u3068\u306b\u3002<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-sql\" data-lang=\"SQL\"><code>--host %\u306b\u5bfe\u3059\u308b\u6a29\u9650\u78ba\u8a8d\nSHOW GRANTS for &#39;user01&#39;@&#39;%&#39;\n--\u7d50\u679c\nGRANT USAGE ON *.* TO &#39;user01&#39;@&#39;%&#39; IDENTIFIED BY PASSWORD &#39;xxxxxxx&#39;\n\n--host 192.168.1.%\u306b\u5bfe\u3059\u308b\u6a29\u9650\u78ba\u8a8d\nSHOW GRANTS for &#39;user01&#39;@&#39;192.168.1.%&#39;;\n--\u7d50\u679c\nGRANT ALL PRIVILEGES ON *.* TO &#39;user01&#39;@&#39;192.168.1.%&#39; IDENTIFIED BY PASSWORD &#39;xxxxxx&#39;<\/code><\/pre><\/div>\n\n\n\n<p> <\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>\u3068\u3044\u3046\u3053\u3068\u3067\u3001\u3069\u3046\u3084\u3089\u30db\u30b9\u30c8\u306eIP\u6307\u5b9a\u3067\u3057\u304b\u5168\u6a29\u4ed8\u4e0e\u304c\u3055\u308c\u3066\u3044\u306a\u3044\u3068\u3044\u3046\u7d50\u679c\u304c\u3067\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E5%8E%9F%E5%9B%A0\"><\/span>\u539f\u56e0<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>\u304a\u305d\u3089\u304f\u3001\u6700\u521d\u306b\u30e6\u30fc\u30b6\u4f5c\u6210\u6642\u306b\u30db\u30b9\u30c8\u6307\u5b9a\u3057\u3066\u5168\u6a29\u4ed8\u4e0e\u3057\u305f\u306e\u3067\u3059\u304c\u3001\u666e\u6bb5\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u63a5\u7d9a\u3057\u3066\u3044\u308b\u3068\u304d\u306fhost\u6307\u5b9a\u3057\u3066\u63a5\u7d9a\u3057\u3066\u3044\u308b\u306e\u3067\u7279\u306b\u554f\u984c\u304c\u306a\u3044\u3067\u3059\u304c\u3001phpMyAdmin\u3067\u63a5\u7d9a\u3059\u308b\u5834\u5408\u3001phpMyAdmin\u304b\u3089\u898b\u308b\u3068\u30ed\u30fc\u30ab\u30eb\u30db\u30b9\u30c8\u3067MySQL\u3078\u63a5\u7d9a\u3059\u308b\u3053\u3068\u306b\u306a\u308b\u306e\u3067\u3001\u30ea\u30e2\u30fc\u30c8\u63a5\u7d9a\u306eGRANT\u3060\u3051\u3067\u306f\u4e0d\u5341\u5206\u3060\u3063\u305f\u3088\u3046\u3067\u3059\u3002<\/p>\n\n\n\n<p>\u6700\u521d\u3042\u307e\u308a\u6c17\u306b\u3057\u3066\u3044\u306a\u304b\u3063\u305f\u3067\u3059\u304c\u3001phpMyAdmin\u304b\u3089\u3082localhost\u63a5\u7d9a\u3068\u3057\u3066\u8868\u793a\u3055\u308c\u3066\u3044\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<figure class=\"wp-block-image size-full waku\"><img loading=\"lazy\" decoding=\"async\" width=\"567\" height=\"226\" src=\"https:\/\/obenkyolab.com\/wp-content\/uploads\/2021\/08\/image-5.png\" alt=\"\" class=\"wp-image-3126\" srcset=\"https:\/\/obenkyolab.com\/wp-content\/uploads\/2021\/08\/image-5.png 567w, https:\/\/obenkyolab.com\/wp-content\/uploads\/2021\/08\/image-5-300x120.png 300w\" sizes=\"auto, (max-width: 567px) 100vw, 567px\" \/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E5%AF%BE%E5%87%A6\"><\/span>\u5bfe\u51e6<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>\u4ee5\u4e0b\u306eSQL\u3092\u5b9f\u884c\u3057localhost\u63a5\u7d9a\u306e\u5834\u5408\u3067\u3082\u5168\u6a29\u4ed8\u4e0e\u3057\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-sql\" data-lang=\"SQL\"><code>GRANT ALL PRIVILEGES ON *.* TO &#39;user01&#39;@&#39;%&#39;;<\/code><\/pre><\/div>\n\n\n\n<p>\u518d\u5ea6phpMyAdmin\u3067\u78ba\u8a8d\u3057\u305f\u3068\u3053\u308d\u3001\u305d\u306e\u4ed6\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3082\u7121\u4e8b\u898b\u3048\u308b\u3088\u3046\u306b\u306a\u3063\u3066\u3044\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u75c7\u72b6 phpMyAdmin\u3067MySQL\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u3092\u5b9f&#46;&#46;&#46;<\/p>\n","protected":false},"author":1,"featured_media":3128,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_locale":"ja","_original_post":"https:\/\/obenkyolab.com\/?p=3122","footnotes":""},"categories":[57,56],"tags":[],"class_list":["post-3122","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-mysql","category-php","ja"],"_links":{"self":[{"href":"https:\/\/obenkyolab.com\/index.php?rest_route=\/wp\/v2\/posts\/3122","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/obenkyolab.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/obenkyolab.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/obenkyolab.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/obenkyolab.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3122"}],"version-history":[{"count":11,"href":"https:\/\/obenkyolab.com\/index.php?rest_route=\/wp\/v2\/posts\/3122\/revisions"}],"predecessor-version":[{"id":4668,"href":"https:\/\/obenkyolab.com\/index.php?rest_route=\/wp\/v2\/posts\/3122\/revisions\/4668"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/obenkyolab.com\/index.php?rest_route=\/wp\/v2\/media\/3128"}],"wp:attachment":[{"href":"https:\/\/obenkyolab.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3122"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/obenkyolab.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3122"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/obenkyolab.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3122"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}