Configuring the Elasticsearch and River-mongodb plugins on Windows

Source: Internet
Author: User
Tags curl

Installing Elasticsearch

1. Download the Elasticsearch installation package. Https://www.elastic.co/downloads/elasticsearch

2. Unpack the Elasticsearch package to the installation directory. such as D:\Elasticsearch, and add D:\Elasticsearch\bin to the system path


Installing the JDK

1. Download JDK, minimum version jdk update u55. Http://www.oracle.com/technetwork/java/javase/overview/index.html

2. Configure the JAVA_HOME environment variable. The installation directory that points to the JDK, such as D:\Java\jdk\


Installing MAVEN

1. Download the MAVEN installation package. http://maven.apache.org/download.cgi

2. Unzip the MAVEN package to the installation directory. such as D:\Maven, and add D:\Maven\bin to the system path

3. Configure the MAVEN local warehousing location. Open D:\Maven\Config\setting.xml, add <localRepository>D:\Maven\m2\repository</localRepository>

Note: (1) Step 3 can be skipped, (2) If you do not want to install the River-mongodb plugin from the source, you can not install Maven


Installing the River-mongodb Plugin

1. Download the latest source package for the Elasticsearch-river-mongodb plugin. Https://github.com/richardwilly98/elasticsearch-river-mongodb

2. Unzip the source package and compile it. The command line enters the Elasticsearch-river-mongodb-master directory and executes the command MVN package-dmaven.test.skip=true

3. The compilation process is slow and needs to be waited patiently. Compile the generated plug-in in the Elasticsearch-river-mongodb-master\target\releases directory, The file name is shaped like Elasticsearch-river-mongodb-2.0.6-snapshot.zip

4. Install the build plugin. Unzip directly to the Plugins\river-mongodb directory in the Elasticsearch installation directory, or command line Run command plugin-i river-mongodb-u file:/e:\documents\ programming \ Elasticsearch\install\elasticsearch-river-mongodb-master\target\releases\ Elasticsearch-river-mongodb-2.0.6-snapshot.zip

Note: If you do not want to install the River-mongodb plugin from the source, you can run plugin-i directly at the command line com.github.richardwilly98.elasticsearch/ elasticsearch-river-mongodb/2.0.6 (here 2.0.6 is the version number)


Installing the Curl Tool

1. Download the Curl tool. Http://curl.haxx.se/dlwiz/?type=bin

2. Fool-type installation can be


Configure the MongoDB River

1. Download the Curl tool. Http://curl.haxx.se/dlwiz/?type=bin1. Run Elasticsearch. Run the Elasticsearch installation directory under Bin\elasticsearch.bat

2. Command line run Curl-xput "Http://127.0.0.1:9200/_river/icssa/_meta?pretty"-D "{\" type\ ": \" mongodb\ ", \" mongodb\ ": {\" host\ ": \" 127.0.0.1\ ", \" port\ ": \" 27017\ ", \" Credentials\ ": [{\" db\ ": \" admin\ ", \" User\ ": \" admin\ ", \" password\ ": \" 12345\ "}], \" db\ ": \" Icssa\ ", \" collection\ ": \" equipment\ "}, \" index\ ": {\" name\ ": \" Icssa\ ", \" type\ ": \" equipment\ "}}"

Note: (1) MongoDB must be configured as a replication cluster; (2) The port of my MongoDB routing process has changed to 27017


View Synchronization Results

1. The browser opens http://localhost:9200/_plugin/head/, provided you have installed the head plugin for Elasticsearch

2. The synchronization results are as follows:


Attention Elasticsearch, River-mongodb plug-ins, MongoDB three versions must be matched

Configuring the Elasticsearch and River-mongodb plugins on Windows

Related Article

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.