Kibana AnSo

 Kibana visual interface

Kibana is an open source analysis and visualization platform designed for and Elasticsearch work together.

You use Kibana to search, view, and stored in Elasticsearch data index to interact.

You can easily perform advanced data analysis, and icons in various forms, tables, and maps of visual data.

Kibana such a large amount of data becomes easy to be understood. It's simple, browser-based interface allows you to quickly create and share dynamic dashboards, real-time display Elasticsearch change the query.

first step

Upload Kibana and decompression, decompression success in the following figure, more than a Kibana file directory.

Unzip command: tar -zxvf kibana-6.4.3-linux-x86_64.tar.gz

 

The second step

Port number of the configuration file, ip address, es access address.

vim config / kibana.yml

# The default configuration read as follows:

server.port: 5601

server.host: "192.168.0.110"

elasticsearch.url: "http:// 192.168.0.110:9200"

 

 

third step

启动 Kibana ./bin/kibana 

 

 

the fourth step

Access Kibana, the following page appears if it means a successful start.

http://192.168.0.110:5601/app/kibana

 Creating an index

GET _search
{
"query": {
"match_all": {}
}
}
##### 创建索引
PUT /myindex

##### 查询索引
GET myindex


##### 创建一个文档 /索引/类型/id
PUT /myindex/user/1
{
"name":"mingtian",
"age":24,
"sex":"男"
}

#### 查询文档
GET /myindex/user/1


##### 删除索引
DELETE /myindex

#### 查询索引
GET myindex

 

Elasticsearch版本控制

1.为什么要进行版本控制

为了保证数据再多线程操作下的准确性

 

2.悲观锁和乐观锁

悲观锁:假设会发生并发冲突,屏蔽一切可能违反数据准确性的操作

悲观锁:假设不会发生并发冲突,只在提交操作是检查是否违反数据完整性。

 

3.内部版本控制和外部版本控制

内部版本控制:_version自增长,修改数据后,_version会自动的加1

 

外部版本控制:为了保持_version与外部版本控制的数值一致

使用version_type=external检查数据当前的version值是否小于请求中的version值

##### 创建一个文档 /索引/类型/id
PUT /myindex/user/1
{
"name":"mingtian",
"age":24,
"sex":"男"
}

Guess you like

Origin www.cnblogs.com/ming-blogs/p/10989757.html