1、Flume内存参数设置及优化
ERROR hdfs.HDFSEventSink: process failed
java.lang.OutOfMemoryError: GC overhead limit exceeded
(1)在hadoop102服务器的/opt/module/flume/conf/flume-env.sh文件中增加如下配置
export JAVA_OPTS="-Xms100m -Xmx2000m -Dcom.sun.management.jmxremote"
(2)同步配置到hadoop103、hadoop104服务器
[yang@hadoop102 conf]$ xsync flume-env.sh
JVM heap一般设置为4G或更高,部署在单独的服务器上(4核8线程16G内存)
-Xmx与-Xms最好设置一致,减少内存抖动带来的性能影响,如果设置不一致容易导致频繁fullgc。
2、file channel优化
3、flume采集数据会丢失吗
数据传输本身有两个事务来维护数据不丢失,channel可以选择file channel 把数据存储在文件系统中
文章来源: https://blog.csdn.net/qq_34897849/article/details/91399842