{"id":1814,"date":"2020-10-26T13:37:24","date_gmt":"2020-10-26T05:37:24","guid":{"rendered":"https:\/\/www.gbase8.cn\/?p=1814"},"modified":"2021-05-31T15:59:42","modified_gmt":"2021-05-31T07:59:42","slug":"gbase-8a%e6%95%b0%e6%8d%ae%e5%ba%93%e6%94%af%e6%8c%81sha256%e7%94%a8%e6%88%b7%e5%af%86%e7%a0%81%e5%8a%a0%e5%af%86%e7%9a%84%e5%8a%9f%e8%83%bdgbase_caching_sha2_password","status":"publish","type":"post","link":"https:\/\/www.gbase8.cn\/en\/1814","title":{"rendered":"\u5357\u5927\u901a\u7528GBase 8a\u6570\u636e\u5e93\u652f\u6301sha256\u7528\u6237\u5bc6\u7801\u52a0\u5bc6\u7684\u529f\u80fdgbase_caching_sha2_password"},"content":{"rendered":"<p>GBase 8a\u6570\u636e\u5e93\uff0c\u5728\u65b0\u7684\u7248\u672c\u91cc\u5f00\u59cb\u652f\u6301sha256\u7684\u7528\u6237\u5bc6\u7801\u52a0\u5bc6\uff0c\u5176\u53c2\u6570\u4e3agbase_caching_sha2_password\u3002\u5468\u8fb9\u5ba2\u6237\u7aef\u5728\u4f7f\u7528\u8fd9\u4e2a\u7528\u6237\u65f6\u9700\u8981\u914d\u5957\u7684\u652f\u6301sha256\u7684\u5ba2\u6237\u7aef\u3002\u5305\u62ec jdbc\uff0c odbc, c API. ado.net\u7b49\u5f00\u53d1\u63a5\u53e3\u3002<\/p>\n\n\n\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_84 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Directory Navigation<\/p>\n<label for=\"ez-toc-cssicon-toggle-item-6a2a973f736cf\" class=\"ez-toc-cssicon-toggle-label\"><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><\/label><input type=\"checkbox\"  id=\"ez-toc-cssicon-toggle-item-6a2a973f736cf\"  aria-label=\"Toggle\" \/><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:\/\/www.gbase8.cn\/en\/1814\/#%E5%8F%82%E6%95%B0\" >\u53c2\u6570<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/www.gbase8.cn\/en\/1814\/#%E4%BF%AE%E6%94%B9%E6%96%B9%E5%BC%8F\" >\u4fee\u6539\u65b9\u5f0f<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/www.gbase8.cn\/en\/1814\/#%E6%A0%B7%E4%BE%8B\" >\u6837\u4f8b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/www.gbase8.cn\/en\/1814\/#%E6%B6%89%E5%8F%8A%E7%9A%84%E5%85%83%E6%95%B0%E6%8D%AE%E8%A1%A8\" >\u6d89\u53ca\u7684\u5143\u6570\u636e\u8868<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/www.gbase8.cn\/en\/1814\/#%E5%8F%82%E8%80%83\" >\u53c2\u8003<\/a><\/li><\/ul><\/nav><\/div>\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E5%8F%82%E6%95%B0\"><\/span>\u53c2\u6570<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>gbase_caching_sha2_password=0<\/p>\n\n\n\n<p>0\uff0c\u4e0d\u5f00\u542f \u9ed8\u8ba4\u503c<br>1\uff0c \u5f00\u542f\uff0c\u4e4b\u540e\u521b\u5efa\u7528\u6237\u548c\u8bbe\u7f6e\u5bc6\u7801\u65f6\uff0c\u4f1a\u7528sha256\u8fdb\u884c\u52a0\u5bc6<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E4%BF%AE%E6%94%B9%E6%96%B9%E5%BC%8F\"><\/span>\u4fee\u6539\u65b9\u5f0f<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>\u53ea\u9700\u8981\u4fee\u6539\u6bcf\u4e2agcluster\u7684\u914d\u7f6e\u3002\u4e00\u822c\u5168\u65b0\u5b89\u88c5\u7684\u4f1a\u81ea\u52a8\u589e\u52a0\u8be5\u53c2\u6570\uff0c\u9ed8\u8ba4\u662f0<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>vi \/opt\/gcluster\/config\/gbase_8a_gcluster.cnf\n\n\u5728\u5176\u4e2d\u4fee\u6539\u6216\u589e\u52a0\u53c2\u6570\n\nmax_connections = 10000\nmax_connect_errors=1000000\nmax_allowed_packet = 64M\nnet_write_timeout = 1000000\nnet_read_timeout = 1000000\nconnect_timeout = 1000000\ninteractive_timeout  =1000000\nwait_timeout = 1000000\nopen_files_limit = 65535\n\ngbase_caching_sha2_password=1\n\ngbase_express_log = 1\n\ngcluster_connect_net_read_timeout  =  1000000\ngcluster_connect_net_write_timeout =  1000000\ngcluster_connect_timeout = 1000000\ngcluster_wait_query_cancel_timeout = 200\n\n<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E6%A0%B7%E4%BE%8B\"><\/span>\u6837\u4f8b<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>\u5982\u4e0b\u521b\u5efa\u4e86\u4e00\u4e2aabc\u7528\u6237\uff0c\u4ecegbase.user\u7684\u5143\u6570\u636e\u8868\u91cc\u53ef\u4ee5\u770b\u5230\u5176\u5bc6\u7801\u957f\u5ea6\u548c\u8001\u7684sha1\u4e0d\u540c\uff0c\u4e3a65\u4f4d\uff0c\u8001\u7684\u662f41\u4f4d\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>gbase> show variables like '%sha%';\n+-----------------------------+-------+\n| Variable_name               | Value |\n+-----------------------------+-------+\n| _gbase_gns_share_connection | 1     |\n| gbase_caching_sha2_password | ON    |\n+-----------------------------+-------+\n2 rows in set (Elapsed: 00:00:00.00)\n\ngbase> create user abc ;\nQuery OK, 0 rows affected (Elapsed: 00:00:00.01)\n\ngbase> grant all on testdb.* to abc identified by 'abc';\nQuery OK, 0 rows affected (Elapsed: 00:00:00.00)\n\ngbase> select * from gbase.user;\n+--------------------------------------------------------------+------------------+-------------------------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-----------+-------------+---------------+--------------+-----------+------------+-----------------+------------+------------+--------------+------------+-----------------------+------------------+--------------+-----------------+------------------+------------------+----------------+---------------------+--------------------+------------------+------------+--------------+----------+------------+-------------+--------------+---------------+-------------+-----------------+----------------------+----------+--------------+---------------+----------------+---------------+-------------------------+-------------------+------+\n| Host                                                         | User             | Password                                                          | Select_priv | Insert_priv | Update_priv | Delete_priv | Create_priv | Drop_priv | Reload_priv | Shutdown_priv | Process_priv | File_priv | Grant_priv | References_priv | Index_priv | Alter_priv | Show_db_priv | Super_priv | Create_tmp_table_priv | Lock_tables_priv | Execute_priv | Repl_slave_priv | Repl_client_priv | Create_view_priv | Show_view_priv | Create_routine_priv | Alter_routine_priv | Create_user_priv | Event_priv | Trigger_priv | ssl_type | ssl_cipher | x509_issuer | x509_subject | max_questions | max_updates | max_connections | max_user_connections | max_cpus | max_memories | max_tmp_space | resource_group | task_priority | user_limit_storage_size | user_storage_size | UID  |\n+--------------------------------------------------------------+------------------+-------------------------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-----------+-------------+---------------+--------------+-----------+------------+-----------------+------------+------------+--------------+------------+-----------------------+------------------+--------------+-----------------+------------------+------------------+----------------+---------------------+--------------------+------------------+------------+--------------+----------+------------+-------------+--------------+---------------+-------------+-----------------+----------------------+----------+--------------+---------------+----------------+---------------+-------------------------+-------------------+------+\n| %                                                            | root             |                                                                   | Y           | Y           | Y           | Y           | Y           | Y         | Y           | Y             | Y            | Y         | Y          | Y               | Y          | Y          | Y            | Y          | Y                     | Y                | Y            | Y               | Y                | Y                | Y              | Y                   | Y                  | Y                | Y          | Y            |          |            |             |              |             0 |           0 |               0 |                    0 |        0 |            0 |             0 |              0 |             2 |                         |                 0 |    1 |\n| %                                                            | gbase            | *9C0ADBD7F08FA9D49D82760B104110C55B943B8D                         | Y           | Y           | Y           | Y           | Y           | Y         | Y           | Y             | Y            | Y         | Y          | Y               | Y          | Y          | Y            | Y          | Y                     | Y                | Y            | Y               | Y                | Y                | Y              | Y                   | Y                  | Y                | Y          | Y            |          |            |             |              |             0 |           0 |               0 |                    0 |        0 |            0 |             0 |              0 |             2 |                         |                 0 |    2 |\n| %                                                            | abc              | *4F8B42C22DD3729B519BA6F68D2DA7CC5B2D606D05DAED5AD5128CC03E6C6358 | N           | N           | N           | N           | N           | N         | N           | N             | N            | N         | N          | N               | N          | N          | N            | N          | N                     | N                | N            | N               | N                | N                | N              | N                   | N                  | N                | N          | N            |          |            |             |              |             0 |           0 |               0 |                    0 |        0 |            0 |             0 |              0 |             2 |                         |                 0 | 2049 |\n+--------------------------------------------------------------+------------------+-------------------------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-----------+-------------+---------------+--------------+-----------+------------+-----------------+------------+------------+--------------+------------+-----------------------+------------------+--------------+-----------------+------------------+------------------+----------------+---------------------+--------------------+------------------+------------+--------------+----------+------------+-------------+--------------+---------------+-------------+-----------------+----------------------+----------+--------------+---------------+----------------+---------------+-------------------------+-------------------+------+\n3 rows in set (Elapsed: 00:00:00.00)\n<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E6%B6%89%E5%8F%8A%E7%9A%84%E5%85%83%E6%95%B0%E6%8D%AE%E8%A1%A8\"><\/span>\u6d89\u53ca\u7684\u5143\u6570\u636e\u8868<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>password\u5b57\u6bb5\u4ecevarchar(41)\u53d8\u6210varchar(65)<\/p>\n\n\n\n<p>gbase.db_links<\/p>\n\n\n\n<p>gbase.userg<\/p>\n\n\n\n<p>base.password_history<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E5%8F%82%E8%80%83\"><\/span>\u53c2\u8003<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<figure class=\"wp-block-embed-wordpress wp-block-embed is-type-wp-embed is-provider-\u8001\u7d2b\u7af9\u7684\u5bb6\"><div class=\"wp-block-embed__wrapper\">\n<blockquote class=\"wp-embedded-content\" data-secret=\"i7n4Vca4FS\"><a href=\"https:\/\/www.gbase8.cn\/en\/1818\/\">GBase 8a\u6570\u636e\u5e93JDBC\u8fde\u63a5\u62a5\u9519 Got packets out of order<\/a><\/blockquote><iframe loading=\"lazy\" title=\"\u300aGBase 8a\u6570\u636e\u5e93JDBC\u8fde\u63a5\u62a5\u9519 Got packets out of order\u300b\u2014\u8001\u7d2b\u7af9\u7684\u5bb6\" class=\"wp-embedded-content\" sandbox=\"allow-scripts\" security=\"restricted\" style=\"position: absolute; clip: rect(1px, 1px, 1px, 1px);\" src=\"https:\/\/www.gbase8.cn\/1818\/embed#?secret=i7n4Vca4FS\" data-secret=\"i7n4Vca4FS\" width=\"600\" height=\"338\" frameborder=\"0\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\"><\/iframe>\n<\/div><\/figure>","protected":false},"excerpt":{"rendered":"<p>\u5357\u5927\u901a\u7528GBase 8a\u6570\u636e\u5e93\u652f\u6301sha256\u7528\u6237\u5bc6\u7801\u52a0\u5bc6\u7684\u529f\u80fdgbase_caching_sha2_password<\/p>","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6],"tags":[31],"class_list":["post-1814","post","type-post","status-publish","format-standard","hentry","category-gbase8a","tag-31"],"_links":{"self":[{"href":"https:\/\/www.gbase8.cn\/en\/wp-json\/wp\/v2\/posts\/1814","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.gbase8.cn\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.gbase8.cn\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.gbase8.cn\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.gbase8.cn\/en\/wp-json\/wp\/v2\/comments?post=1814"}],"version-history":[{"count":3,"href":"https:\/\/www.gbase8.cn\/en\/wp-json\/wp\/v2\/posts\/1814\/revisions"}],"predecessor-version":[{"id":1873,"href":"https:\/\/www.gbase8.cn\/en\/wp-json\/wp\/v2\/posts\/1814\/revisions\/1873"}],"wp:attachment":[{"href":"https:\/\/www.gbase8.cn\/en\/wp-json\/wp\/v2\/media?parent=1814"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.gbase8.cn\/en\/wp-json\/wp\/v2\/categories?post=1814"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.gbase8.cn\/en\/wp-json\/wp\/v2\/tags?post=1814"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}