我在公司防火墙后面的windows服务器上运行MiNiFi。我的NiFi运行在Hortonworks集群上(3个节点,例如:SJ46、sj47、sj48)。
RemoteProcessGroup:
nifi.properties:
nifi.remote.input.host=
nifi.remote.input.http.enabled=true
nifi.remote.input.http.transaction.ttl=30 sec
nifi.remote.input.secure=True
nifi.remote.input.socket.port=6698
nifi.cluster.node.protocol.port=6699
nifi.web.http.port=
nifi.web.https.host=sj46.xxxx
nifi.web.https.port=6689
MiNiFi Config Version: 3
Flow Controller:
name: min2510
comment: ''
Core Properties:
flow controller graceful shutdown period: 10 sec
flow service write delay interval: 500 ms
administrative yield duration: 30 sec
bored yield duration: 10 millis
max concurrent threads: 1
variable registry properties: ''
FlowFile Repository:
partitions: 256
checkpoint interval: 2 mins
always sync: false
Swap:
threshold: 20000
in period: 5 sec
in threads: 1
out period: 5 sec
out threads: 4
Content Repository:
content claim max appendable size: 10 MB
content claim max flow files: 100
always sync: false
Provenance Repository:
provenance rollover time: 1 min
implementation: org.apache.nifi.provenance.MiNiFiPersistentProvenanceRepository
Component Status Repository:
buffer size: 1440
snapshot frequency: 1 min
Security Properties:
keystore: ''
keystore type: ''
keystore password: ''
key password: ''
truststore: ''
truststore type: ''
truststore password: ''
ssl protocol: ''
Sensitive Props:
key:
algorithm: PBEWITHMD5AND256BITAES-CBC-OPENSSL
provider: BC
Processors:
- id: 50420aac-ef66-30ac-0000-000000000000
name: FetchFile
class: org.apache.nifi.processors.standard.FetchFile
max concurrent tasks: 1
scheduling strategy: TIMER_DRIVEN
scheduling period: 0 sec
penalization period: 30 sec
yield period: 1 sec
run duration nanos: 0
auto-terminated relationships list:
- failure
- not.found
- permission.denied
Properties:
Completion Strategy: None
File to Fetch: ${absolute.path}/${filename}
Log level when file not found: ERROR
Log level when permission denied: ERROR
Move Conflict Strategy: Rename
Move Destination Directory:
- id: ae4799d5-073c-3dd6-0000-000000000000
name: ListFile
class: org.apache.nifi.processors.standard.ListFile
max concurrent tasks: 1
scheduling strategy: TIMER_DRIVEN
scheduling period: 0 sec
penalization period: 30 sec
yield period: 1 sec
run duration nanos: 0
auto-terminated relationships list: []
Properties:
File Filter: '[^\.].*'
Ignore Hidden Files: 'true'
Include File Attributes: 'true'
Input Directory: C:\minifi to EFT
Input Directory Location: Local
Maximum File Age:
Maximum File Size:
Minimum File Age: 0 sec
Minimum File Size: 0 B
Path Filter:
Recurse Subdirectories: 'true'
target-system-timestamp-precision: auto-detect
Controller Services: []
Process Groups: []
Input Ports: []
Output Ports: []
Funnels: []
Connections:
- id: 95dde9e7-96a4-3bea-0000-000000000000
name: FetchFile/success/eef78a5f-cc55-1d33-0000-0000481921e3
source id: 50420aac-ef66-30ac-0000-000000000000
source relationship names:
- success
destination id: eef78a5f-cc55-1d33-0000-0000481921e3
max work queue size: 10000
max work queue data size: 1 GB
flowfile expiration: 0 sec
queue prioritizer class: ''
- id: 2ba13196-5ac6-3966-0000-000000000000
name: ListFile/success/FetchFile
source id: ae4799d5-073c-3dd6-0000-000000000000
source relationship names:
- success
destination id: 50420aac-ef66-30ac-0000-000000000000
max work queue size: 10000
max work queue data size: 1 GB
flowfile expiration: 0 sec
queue prioritizer class: ''
Remote Process Groups:
- id: 6bd4b280-646b-3b93-0000-000000000000
name: ''
url: https://sj46.xxxx:6689/nifi
comment: ''
timeout: 30 sec
yield period: 10 sec
transport protocol: HTTP
proxy host: ''
proxy port: ''
proxy user: ''
proxy password: ''
local network interface: ''
Input Ports:
- id: eef78a5f-cc55-1d33-0000-0000481921e3
name: From MiNiFi
comment: ''
max concurrent tasks: 1
use compression: false
Output Ports: []
NiFi Properties Overrides: {}
2019-03-27 15:50:09,152 WARN [Remote Process Group 6bd4b280-646b-3b93-0000-000000000000 Thread-1] o.a.n.r.util.SiteToSiteRestApiClient Failed to get controller from https://sj46.xxxx:6689/nifi-api due to org.apache.http.conn.HttpHostConnectException: Connect to sj46.xxxx:6689 [sj46.xxxx/x.x.x.x] failed: Connection timed out: connect
2019-03-27 15:50:09,160 WARN [Remote Process Group 6bd4b280-646b-3b93-0000-000000000000 Thread-1] o.a.n.remote.StandardRemoteProcessGroup Unable to communicate with remote instance RemoteProcessGroup[https://sj46.xxxx:6689/nifi]
org.apache.nifi.controller.exception.CommunicationsException: org.apache.nifi.controller.exception.CommunicationsException: Unable to communicate with Remote NiFi at URI https://sj46.xxxx:6689/nifi due to: Connect to sj46.xxxx:6689 [sj46.xxxx/x.x.x.x] failed: Connection timed out: connect
at org.apache.nifi.remote.StandardRemoteProcessGroup.refreshFlowContents(StandardRemoteProcessGroup.java:882)
at org.apache.nifi.remote.StandardRemoteProcessGroup.lambda$initialize$0(StandardRemoteProcessGroup.java:193)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: org.apache.nifi.controller.exception.CommunicationsException: Unable to communicate with Remote NiFi at URI https://sj46.xxxx:6689/nifi due to: Connect to sj46.xxxx:6689 [sj46.xxxx/x.x.x.x] failed: Connection timed out: connect
at org.apache.nifi.remote.StandardRemoteProcessGroup.refreshFlowContents(StandardRemoteProcessGroup.java:844)
... 8 common frames omitted
有关于如何解决此问题的指示吗?
通过禁用MiNiFi服务器的防火墙,上述问题得到了解决。现在我得到了另一个问题,如下所示:
WARN [Remote Process Group 6bd4b280-646b-3b93-0000-000000000000 Thread-1] o.a.n.r.util.SiteToSiteRestApiClient Failed to get controller from https://sj46.xxxx:6689/nifi-api due to javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
WARN [Remote Process Group 6bd4b280-646b-3b93-0000-000000000000 Thread-1] o.a.n.remote.StandardRemoteProcessGroup Unable to connect to RemoteProcessGroup[https://sj46.xxxx:6689/nifi] due to javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
通过将SSl证书(您可以在nifi.properties,特别是keystore.jks和truststore.jks中引用该证书)导入到minifi,解决了SSLHandshakeException的上述问题。我们需要手动修改miniFi中的config.yml。
ERROR [Timer-Driven Process Thread-6] o.a.n.c.t.ContinuallyRunConnectableTask RemoteGroupPort[name=From MiNiFi,targets=https://sj46.xxxx:6689/nifi] failed to process session due to java.lang.RuntimeException: java.lang.NoSuchMethodError: org.apache.http.impl.client.HttpClientBuilder.setSSLContext(Ljavax/net/ssl/SSLContext;)Lorg/apache/http/impl/client/HttpClientBuilder;
ERROR [Timer-Driven Process Thread-6] o.a.n.c.t.ContinuallyRunConnectableTask
java.lang.RuntimeException: java.lang.NoSuchMethodError: org.apache.http.impl.client.HttpClientBuilder.setSSLContext(Ljavax/net/ssl/SSLContext;)Lorg/apache/http/impl/client/HttpClientBuilder;
我看到您的远程端口配置为6698。
>
尝试从运行MiNiFi的计算机远程登录6698上的NiFi主机。尝试查看NiFi主机上配置的入站规则。(Telnetting到特定端口上的远程主机是为了检查您是否能够通过该特定端口与该主机通信。它与您计算机上的特定端口是否打开无关。)
将#Site下NiFi.Properties中的NiFi主机名添加到Site属性
属性:
端口:6698主机名:
对于config.yml和nifi.properties修改引用,请检查以下内容。
我是一个初学者,如果你能让我知道,我将不胜感激。
我在一个代理之下,并且我在相当长一段时间内成功地推进git 现在我无法突然进入git 我已经设置了RSA密钥和代理,并对它们进行了双重检查,但没有结果,git向我抛出了页面标题中显示的错误。
我需要使用Gmail作为SMTP服务器从我的应用程序发送电子邮件。这是我的邮件连接器类,我在一个单独的属性文件中设置了值 属性: 然后我实现了一个邮件发送者类,名为“GroupEmail.class” 毕竟,我在需要触发要发送的电子邮件的地方调用了“GroupEmail.class”。 我在localhost使用Tomcat v8服务器,当应用程序工作时,我得到了以下异常。
下面是应用程序的代码。我一直在尝试使用eclipse IDE来运行它。我还添加了所有必需的java邮件jar文件,即。但会出现以下错误。 没有防火墙阻止访问,因为ping smtp.gmail.com时会收到回复。我甚至这样试过: null
这是我用来发送电子邮件的代码: javax.mail.MessagingException:无法连接到SMTP主机:SMTP.gmail.com,端口:465; 嵌套异常为: java.net.connectException:连接被拒绝 在com.sun.mail.SMTP.smtpransport.openserver(smtpransport.java:1961) 在com.sun.mail