First on the code, follow-up analysis.
The jar package is directly under the ES package, implemented by the following functions:
1. Create an index
2. Query specific Documents
Import Java.util.Date;
Import Java.util.HashMap;
Import Java.util.Map;
Import Org.elasticsearch.action.get.GetResponse;
Import Org.elasticsearch.action.index.IndexResponse;
Import org.elasticsearch.client.Client;
Import org.elasticsearch.client.transport.TransportClient;
Import org.elasticsearch.common.settings.Immutable
ES is reduced when the JVM begins to swapping, it is possible to set the ES_MIN_MEM and ES_MAX_MEM two environment variables to the same value, and to ensure that the machine has enough memory allocated to ES. Also allow Elasticsearch process to lock memory, Linux can be through the ' ulimit-l Unlimited ' command.
network.bind_host:192.168.0.1
Sets the IP address of the binding, which can be IPv4 or IPv6, and defaults to 0.0.0.0.
network.publish_host:192.168.0.1
Set the IP address of the other
switches produced by Intel for the reference of network administrators.
Quick installation
The installation of Intel Express 9000 Series routers is complicated. In my practical work, I have summarized a set of Installation procedures. It is difficult to handle router configuration errors. First, write down the MAC address of the vro configured in the LAN. The MAC address is in the following format: 000080 xxxxxx for later installation.
Then, start hardware installation and connect the five UTP
example of any field list sent in the previous two days. Shows how to open the sorting list.
To be able to change parameters in tracing, we must create several more data items. We need five data items in ascending and descending order (up and down) and three columns (A, B, and C) to be sorted ). As shown in:
The data expression is the value to be received by the parameter. The up data item is 'up '.
Next, add the sorted image to the column header, click unlock, and place the image c
location:Path. plugins:/path/to/plugins14. Plug-in hosting location. If a plug-in the list is not installed, the node cannot be started:Plugin. Mandatory: mapper-attachments, Lang-Groovy15. When the JVM starts to switch, elasticsearch does not perform well: You need to ensure that the JVM does not switch. You can set Bootstrap. mlockall to true to disable switching:Bootstrap. mlockall: TrueMake sure that the values of es_min_mem and es_max_mem are the same, and elasticsearch can be allocated wi
Centos7 install ELK and centos7 install elk1. Overview
ELK Introduction ELK is short for Elasticsearch + Logstash + Kibana:Elasticsearch is a Lucene-based search server. It provides a distributed full-text search engine with multi-user capabilities, developed based on javaLogstash is a tool for receiving, processing, and forwarding logs.Kibana is a browser-based front-end Elasticsearch display tool. Kibana is all written in HTML and Javascript.
Operating system version
cat /etc/redhat-releas
shutdownnode.close();Another common use is to start node and then use the Client for unit/integration testing. In this case, we should start a "local" node. This is just a simple setting to start node. Note that "local" means running on the local JVM. Two local services running on the same JVM can discover each other and form a cluster.import static org.elasticsearch.node.NodeBuilder.*;// on startupNode node = nodeBuilder().local(true).node();Client client = node.client();// on shutdownnode.clo
Centos7 uses the firewall: lt; 1 gt; for example, to query whether port 9200 is opened by the following command: firewall-cmd -- query-port = 9200/tcp, return yes, indicating to open lt; 2 gt; run the following command to open port 9300: firewall-cmd -- add-p
Centos 7 adopts the firewall:
Command: firewall-cmd -- query-port = 9200/tcp
Yes indicates opening
Command: firewall-cmd -- add-port = 9300/tcp
/plugins14. Plugin hosting location, if one of the plugins in the list is not installed, the node will not start:Plugin.mandatory:mapper-attachments,lang-groovyWhen the JVM starts swapping, Elasticsearch does not perform well: you need to protect the JVM from swapping, and you can set Bootstrap.mlockall to true to disallow swapping:Bootstrap.mlockall:trueMake sure that the values for the Es_min_mem and Es_max_mem are the same, and that you can allocate enough intrinsic to the elasticsearch and l
configurable and flexible to configure.Interface:provides two sets of API interfaces based on whether or not to use Java,elasticsearch: JAVA API and RESTful API.Two built-in clients are available for Java Api,elasticsearch:
node Client: The node client joins the cluster with no data node (none), in other words, it does not store any data itself, but it knows where the data is in the cluster and is able to forward the request directly to the corresponding node.
Transport clients (T
: Path.plugins:/path/to/plugins14. Plugin hosting location, if one of the plugins in the list is not installed, the node will not start: Plugin.mandatory:mapper-attachments,lang-groovyWhen the JVM starts swapping, Elasticsearch does not perform well: you need to protect the JVM from swapping, and you can set Bootstrap.mlockall to True to disable swapping: Bootstrap.mlockall:trueMake sure that the values for the Es_min_mem and Es_max_mem are the same, and that you can allocate enough intrinsic to
Problem: Normal access during intranet testing, but deployed to extranet client connection Elasticsearch error: None of the configured nodes is available: []Cause: By default, Elasticsearch uses the 0.0.0.0 address and opens Port 9200-9300 for the HTTP transport, opens port 9300-9400 for node-to-node communication, deploys to the external network to modify the ELASTICSEARCH.YML configurationOperation:Modify
to 0.0.0.0. network.publish_host:192.168.0.1 Set the other node and the IP address of the node interaction, if not set it will automatically determine that the value must be a real IP address. network.host:192.168.0.1 This parameter is used to set both Bind_host and Publish_host above two parameters. transport.tcp.port:9300 Set the TCP port for interaction between nodes, which is 9300 by default. Transport
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.