简体   繁体   English

如果Flume手动运行,天鹅座只会在MySql数据库上保存数据

[英]Cygnus only presists data on MySql database if Flume is run manually

So i had a problem with te presistance of the data on MySql databases before ( Cygnus not presisting data on MySql database ) and as you can see the problem was partially resolved. 因此,我之前在MySql数据库上存在数据持久性问题( Cygnus在MySql数据库上不存在数据 ),并且您可以看到问题已部分解决。 I'm asking another question because this is somewhat of a different topic inside of the question. 我问的是另一个问题,因为这与问题内的主题有些不同。

As you can see by the question i asked before, the problem was that the Cygnus was running but not starting any Flume component (any source, channel or sink) . 从我之前的问题中可以看到, 问题在于Cygnus正在运行,但没有启动任何Flume组件(任何源,通道或接收器) And i started the flume agent by doing: 我通过以下方式启动了水槽代理:

/usr/cygnus/bin/cygnus-flume-ng agent --conf /usr/cygnus/conf/ -f /usr/cygnus/conf/agent_a1.conf -n cygnusagent -Dflume.root.logger=INFO,console

If i did this all problems were solved and the values were presisted on the tables. 如果我这样做,所有问题都会解决,并且值会保留在表中。 But once i killed the process or exited the ssh connection (I'm working on a cloud) the values stop being presisted. 但是一旦我终止了该进程或退出了ssh连接(我在云上工作),这些值就不再存在。

You can see the log, data and scripts i'm using in the link i provided up above. 您可以在上面提供的链接中查看我正在使用的日志,数据和脚本。

Now your are trying to run Cygnus as a service, we need properly cnfigured the cygnus_instance_<id>.conf file in addition to the agent_<id>.conf one. 现在,您正在尝试运行天鹅作为一种服务,我们需要正确地cnfigured的cygnus_instance_<id>.conf文件中除了agent_<id>.conf之一。 HJaving a look your file, I've seen that: 看看您的文件,我已经看到:

AGENT_NAME=root

This is wrong, and should be cygnusagent instead of root . 这是错误的,应该使用cygnusagent而不是root As described in the comments: 如评论中所述:

# Name of the agent. The name of the agent is not trivial, since it is
# the base for the Flume parameters naming conventions, e.g. it appears
# in .sources.http-source.channels=...

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM