{"id":254,"date":"2023-02-24T06:11:16","date_gmt":"2023-02-23T22:11:16","guid":{"rendered":"https:\/\/www.appblog.cn\/?p=254"},"modified":"2023-04-30T15:18:40","modified_gmt":"2023-04-30T07:18:40","slug":"mysql-assign-specified-database-to-user-under-linux","status":"publish","type":"post","link":"https:\/\/www.appblog.cn\/index.php\/2023\/02\/24\/mysql-assign-specified-database-to-user-under-linux\/","title":{"rendered":"Linux\u4e0bMySQL\u4e3a\u7528\u6237\u5206\u914d\u6307\u5b9a\u6570\u636e\u5e93"},"content":{"rendered":"<h3>\u521b\u5efa\u7528\u6237<\/h3>\n<pre><code>> create user &#039;usertest&#039;@&#039;localhost&#039; identified by &#039;test_user&#039;;<\/code><\/pre>\n<p><!-- more --><\/p>\n<h3>\u8fdb\u5165mysql\u6570\u636e\u5e93<\/h3>\n<pre><code>> use mysql;<\/code><\/pre>\n<h3>\u521b\u5efa\u6570\u636e\u5e93<\/h3>\n<pre><code>> create database applog_dw default charset utf8 collate utf8_general_ci;<\/code><\/pre>\n<h3>\u4e3a\u7528\u6237\u5206\u914d\u6307\u5b9a\u6570\u636e\u5e93\u6743\u9650<\/h3>\n<pre><code>> grant all privileges on `applog_dw`.* to &#039;AppLog&#039;@&#039;localhost&#039;;\u00a0\n> flush privileges;<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u521b\u5efa\u7528\u6237 > create user &#039;usertest&#039;@&#039;localhost [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[13],"tags":[],"class_list":["post-254","post","type-post","status-publish","format-standard","hentry","category-mysql"],"_links":{"self":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/254","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/comments?post=254"}],"version-history":[{"count":0,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/254\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/media?parent=254"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/categories?post=254"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/tags?post=254"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}