在使用 Apache Flume的时候,开启 agent 指令:
bin/flume-ng agent -c conf -f conf/console.conf --name agent1
出现报错:
org.apache.commons.cli.MissingOptionException: Missing required option: n
at org.apache.commons.cli.Parser.checkRequiredOptions(Parser.java:299)
at org.apache.commons.cli.Parser.parse(Parser.java:231)
at org.apache.commons.cli.Parser.parse(Parser.java:85)
at org.apache.flume.node.Application.main(Application.java:263)
原因: 你可能会觉得我加 name
参数了呀,但参数顺序是有问题的,只需要把 --name 提到最前面就可以解决问题了。
bin/flume-ng agent --name agent1 -c conf -f conf/console.conf