当前位置:网站首页>Nifi fast installation and file synchronization
Nifi fast installation and file synchronization
2022-04-23 16:43:00 【A hundred nights】
Nifi In short, it is a data pull 、 A system for data processing and data distribution .
Nifi Running requires JVM, need jdk,nifi 1.x The above needs jdk8 above ,0.x need jdk7 above .
This article is in Centos 7 Install in nifi-1.8.0-bin.tar.gz
Download address :nifi.apache.org/download (xx.tar.gz yes Linux edition ,xx.zip yes Windows edition )
User manual :http://nifi.apache.org/docs.html
install
1. Download installation package
wget -b http://mirror.bit.edu.cn/apache/nifi/1.8.0/nifi-1.8.0-bin.tar.gz
2. Unzip the installation package
tar -zxf nifi-1.8.0-bin.tar.gz
3. modify nifi/conf Under the table of contents nifi.properties file
Modify host number and port number
nifi.web.http.host= Host number
nifi.web.http.port= Service port number [ Customize ]
# web properties #
nifi.web.war.directory=./lib
nifi.web.http.host=192.168.197.106 // Change to your own host ip
nifi.web.http.port=8182 // Default 8080, Prevent port occupation , It can be modified to other ports
nifi.web.http.network.interface.default=
nifi.web.https.host=
nifi.web.https.port=
nifi.web.https.network.interface.default=
nifi.web.jetty.working.directory=./work/jetty
nifi.web.jetty.threads=200
nifi.web.max.header.size=16 KB
nifi.web.proxy.context.path=
nifi.web.proxy.host=
4. Service startup
Get into nifi/bin Catalog , function nifi.sh file , The front and rear operation commands are as follows
./nifi.sh run // The front desk operation
./nifi.sh start // Background operation
The following prompt appears: the service is started successfully ,
Java home: /opt/soft/jdk180
NiFi home: /opt/soft/nifi-1.8.0
Bootstrap Config File: /opt/soft/nifi-1.8.0/conf/bootstrap.conf
see nifi Start state
./nifi.sh stauts
-----------------------------------------------------------------------------------------------------------
Java home: /opt/soft/jdk180
NiFi home: /opt/soft/nifi-1.8.0
Bootstrap Config File: /opt/soft/nifi-1.8.0/conf/bootstrap.conf
2021-05-01 17:24:49,589 INFO [main] org.apache.nifi.bootstrap.Command Apache NiFi is currently running, listening to Bootstrap on port 43069, PID=2099
5. Service closing
If it's a foreground operation , direct Ctrl+C Exit Service .
If it's running in the background , Access to nifi/bin Catalog , Execute the following command
./nifi.sh stop
6.web UI
Service startup 1-5 Minutes later , Can open web see ,http:192.168.197.106:8182/nifi, As shown in the figure .
Use
File synchronization
Realization : take /opt/act.log Synchronize file contents to /opt/data Empty directory , And keep the source file .
Processor required GetFile ( Read and delete files ) + PutFile( Save the file )
Drag and drop a... In the toolbar Processor Go to the canvas , Input ’local’, choice ’GetFile’ processor , Click on ADD Add to canvas , The same operation creates a ’PutFile’ processor .
To configure GetFile processor
1. Select processor , Right click selection “configure”,“settings” The admission “success”, Automatically terminate the relationship .
2.“properties” Attribute configuration .
- Input Directory: Enter the source directory
- File Filter: File filter
- Keep Source File: Do you want to keep the source file , Default false
- Recurse Subdirectories: Whether to pull the files in the subdirectory , Default true
After configuration , Click on ‘apply’ Save application .
To configure PutFile processor
1. Select processor , Right click selection “configure”, stay “settings” The admission “failure” and “success”.
2.“properties” Attribute configuration
- Directory: Target directory
- Conflict Resolution Strategy: Specify the operation after a file with the same name exists . Optional value :replace Replace existing files ,fail Execution failure , Don't generate files ,ignore Ignore .
- Create Missing Directories: Specify whether the target directory does not exist or not to create a directory . Optional value :true newly build ,false No new .
After configuration , Click on ‘apply’ Save application .
Connecting the processor
1. Move the mouse to ’GetFile’ On , The following arrow appears , Click and drag to ’PutFile’ On .
2. To configure “Settings”, Set up name:demo1, Increase priority ,‘FirstInFirstOutPrioritizer’. Click on ’add’, Create connection .
3. Right click the canvas and select ’Start‘, Visible data flow .GetFile Read file output 7.36KB,PutFile Write files to the target directory ,7.36KB, Also visible in the target directory act.log file .
版权声明
本文为[A hundred nights]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204231401521069.html
边栏推荐
- 【PIMF】OpenHarmony啃论文俱乐部—在ACM Survey闲逛是什么体验
- OMNeT学习之新建工程
- Differences between MySQL BTREE index and hash index
- Installation and management procedures
- Detailed explanation of gzip and gunzip decompression parameters
- PyMySQL
- Qipengyuan horizon credible meta universe social system meets diversified consumption and social needs
- On the security of key passing and digital signature
- How does flash cache data in memory?
- Detailed explanation of file operation (2)
猜你喜欢
How magical is the unsafe class used by all major frameworks?
人脸识别框架之dlib
DanceNN:字节自研千亿级规模文件元数据存储系统概述
ACL 2022 | DialogVED:用于对话回复生成的预训练隐变量编码-解码模型
vim编辑器的实时操作
阿里研发三面,面试官一套组合拳让我当场懵逼
Detailed explanation of file operation (2)
The font of the soft cell changes color
DDT + Excel for interface test
ACL 2022 | dialogved: a pre trained implicit variable encoding decoding model for dialogue reply generation
随机推荐
关于 background-image 渐变gradient()那些事!
无线鹅颈麦主播麦手持麦无线麦克风方案应当如何选择
JIRA screenshot
LVM与磁盘配额
MySQL的btree索引和hash索引区别
Xinwangda: HEV and Bev super fast charging fist products are shipped on a large scale
Detailed explanation of information abstract, digital signature, digital certificate, symmetric encryption and asymmetric encryption
JSP learning 2
5分钟NLP:Text-To-Text Transfer Transformer (T5)统一的文本到文本任务模型
The most detailed knapsack problem!!!
基于GPU实例的Nanopore数据预处理
05 Lua 控制结构
Report FCRA test question set and answers (11 wrong questions)
七朋元视界可信元宇宙社交体系满足多元化的消费以及社交需求
ByteVCharts可视化图表库,你想要的我都有
Disk management and file system
Construction of promtail + Loki + grafana log monitoring system
Public variables of robotframework
Install MySQL on MAC
5-minute NLP: text to text transfer transformer (T5) unified text to text task model