MongoDB 学习笔记之 mongo-connector安装

mac2022-06-30  67

mongo-connector安装:

 

https://github.com/mongodb-labs/mongo-connector

1. yum -y install openssl*

2.编译安装python3

下载地址:https://www.python.org/ftp/python/

tar zxvf Python-3.5.2.tgzcd Python-3.5.2./configuremake && make install

 (在安装结尾出可以看到pip3已经被安装的提示,如果提示require TLS/SSL,说明没有安装openssl-devel)

yum install openssl-devel -y

3.pip3安装成功后,安装mongo-connector: 

pip3 install --target=/usr/local/pythonpip/site-packages 'mongo-connector[elastic5]'

 

4.启动mongo集群

5.启动es集群

6.运行连接命令:

mongo-connector -m 192.168.1.151:27017 -t 192.168.1.151:9200 -d elastic2_doc_manager

7.验证mongoDB数据是否同步到ES:

 大功告成,可喜可贺!

转载于:https://www.cnblogs.com/AK47Sonic/p/7608812.html

最新回复(0)