wu-sheng closed pull request #23: 修复日期错误问题
URL: https://github.com/apache/incubator-skywalking-website/pull/23
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/docs/zh/blog/2019-01-02-skywalking-elasticsearch-basic.md 
b/docs/zh/blog/2019-01-02-skywalking-elasticsearch-basic.md
new file mode 100644
index 0000000..a739dcb
--- /dev/null
+++ b/docs/zh/blog/2019-01-02-skywalking-elasticsearch-basic.md
@@ -0,0 +1,61 @@
+### 关于使用elasticsearch,需要basic认证问题
+
+skywalking依赖elasticsearch集群,如果elasticsearch安装有x-pack插件的话,那么就会存在一个Basic认证,导致skywalking无法调用elasticsearch,解决方法是使用nginx做代理,让nginx来做这个Basic认证,那么这个问题就自然解决了。
+
+方法如下:
+
+1.安装nginx
+
+> yum install -y nginx
+
+
+2.配置nginx
+
+```xml
+
+
+server {
+        listen       9200 default_server;
+        server_name  _;
+        
+        location / {
+                 proxy_set_header Host $host;
+                 proxy_set_header X-Real-IP $remote_addr;
+                 proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
+                 proxy_pass http://localhost:9200;
+                 #Basic字符串就是使用你的用户名(admin),密码(12345)编码后的值
+                 #注意:在进行Basic加密的时候要使用如下格式如:admin 123456 
注意中间有个空格,如果使用其它格式,那么结果我们是无法预知的,最起码笔者使用上诉格式没有出现问题。
+                 proxy_set_header Authorization "Basic YWRtaW4gMTIzNDU2";
+        }
+    }
+
+
+```
+
+3.验证
+
+> curl localhost:9200
+
+```xml
+{
+  "name" : "Yd0rCp9",
+  "cluster_name" : "es-cn-4590xv9md0009doky",
+  "cluster_uuid" : "jAPLrqY5R6KWWgHnGCWOAA",
+  "version" : {
+    "number" : "6.3.2",
+    "build_flavor" : "default",
+    "build_type" : "tar",
+    "build_hash" : "053779d",
+    "build_date" : "2018-07-20T05:20:23.451332Z",
+    "build_snapshot" : false,
+    "lucene_version" : "7.3.1",
+    "minimum_wire_compatibility_version" : "5.6.0",
+    "minimum_index_compatibility_version" : "5.0.0"
+  },
+  "tagline" : "You Know, for Search"
+}
+
+
+```
+
+## 看到如上结果那么恭喜你成功了。


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to