{"id":8003,"date":"2020-06-22T15:40:07","date_gmt":"2020-06-22T07:40:07","guid":{"rendered":"https:\/\/www.linuxcool.com\/?p=8003"},"modified":"2020-06-22T15:40:08","modified_gmt":"2020-06-22T07:40:08","slug":"redis-cli","status":"publish","type":"post","link":"https:\/\/www.linuxcool.com\/redis-cli","title":{"rendered":"redis-cli\u547d\u4ee4 – redis\u5ba2\u6237\u7aef\u7ba1\u7406\u5de5\u5177"},"content":{"rendered":"\n
Redis\u662f\u4e00\u4e2a\u5f00\u653e\u6e90\u7801\uff08BSD\u6388\u6743\uff09\u7684\u5185\u5b58\u6570\u636e\u7ed3\u6784\u5b58\u50a8\uff0c\u7528\u4f5c\u6570\u636e\u5e93\u3001\u7f13\u5b58\u548c\u6d88\u606f\u4e2d\u4ecb\u3002\u540c\u65f6\u662f\u4e00\u4e2a\u9ad8\u6027\u80fd\u7684key-value\u6570\u636e\u5e93\u3002<\/p>\n\n\n\n
redis-cli\u547d\u4ee4\u662fredis-server\u7684\u547d\u4ee4\u884c\u5ba2\u6237\u7aef\u3002<\/p>\n\n\n\n
\u8bed\u6cd5\u683c\u5f0f\uff1a<\/strong>redis-cli [\u53c2\u6570]<\/p>\n\n\n\n \u5e38\u7528\u53c2\u6570\uff1a<\/strong><\/p>\n\n\n\n \u53c2\u8003\u5b9e\u4f8b<\/strong><\/p>\n\n\n\n \u4f7f\u7528\u9ed8\u8ba4\u7aef\u53e3\uff0c\u8fde\u63a5redis\u670d\u52a1\u5668\uff1a<\/p>\n\n\n\n \u901a\u8fc7\u6307\u5b9a\u7aef\u53e3\u8fde\u63a5redis\uff1a<\/p>\n\n\n\n \u4f7f\u7528\u5bc6\u7801\u8ba4\u8bc1\u8fde\u63a5\uff1a<\/p>\n\n\n\n Redis\u662f\u4e00\u4e2a\u5f00\u653e\u6e90\u7801\uff08BSD\u6388\u6743\uff09\u7684\u5185\u5b58\u6570\u636e\u7ed3\u6784\u5b58\u50a8\uff0c\u7528\u4f5c\u6570\u636e\u5e93\u3001\u7f13\u5b58\u548c\u6d88\u606f\u4e2d\u4ecb\u3002\u540c\u65f6\u662f\u4e00\u4e2a\u9ad8\u6027\u80fd\u7684key […]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[11],"tags":[],"_links":{"self":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/8003"}],"collection":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/comments?post=8003"}],"version-history":[{"count":5,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/8003\/revisions"}],"predecessor-version":[{"id":8079,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/8003\/revisions\/8079"}],"wp:attachment":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/media?parent=8003"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/categories?post=8003"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/tags?post=8003"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}-h<\/td> \u670d\u52a1\u5668\u4e3b\u673a\u540d\u79f0<\/td><\/tr> -p<\/td> \u670d\u52a1\u5668\u7aef\u53e3<\/td><\/tr> -a<\/td> \u8fde\u63a5\u5230\u670d\u52a1\u5668\u65f6\u4f7f\u7528\u7684\u5bc6\u7801<\/td><\/tr> -r<\/td> \u6267\u884c\u6307\u5b9a\u547d\u4ee4N\u6b21<\/td><\/tr> -n<\/td> \u6570\u636e\u5e93\u7f16\u53f7<\/td><\/tr> --csv<\/td> \u4ee5csv\u683c\u5f0f\u8f93\u51fa<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n [root@linuxcool ~]# redis-cli -h 127.0.0.1<\/pre>\n\n\n\n
[root@linuxcool ~]# redis-cli -h 192.168.1.1 -p 6380<\/pre>\n\n\n\n
[root@linuxcool ~]# redis-cli -h 127.0.0.1 -p 6379 -a myPassword<\/pre>\n","protected":false},"excerpt":{"rendered":"