elastalert
elastalert copied to clipboard
error when test rule
Traceback (most recent call last):
File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
"main", fname, loader, pkg_name)
File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/opt/elastalert/elastalert/test_rule.py", line 458, in
elastalert-test-rule rule_email.yaml is ok in shell mode
Does this problem still occur?
yes still.I use your new image "bitsensor/elastalert:3.0.0-beta.0".When I test a rule.it shows 14:44:43.738Z ERROR elastalert-server: TestController: Traceback (most recent call last): File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
"__main__", fname, loader, pkg_name)
File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/opt/elastalert/elastalert/test_rule.py", line 445, in <module>
main()
File "/opt/elastalert/elastalert/test_rule.py", line 441, in main
test_instance.run_rule_test()
File "/opt/elastalert/elastalert/test_rule.py", line 408, in run_rule_test
conf = load_conf(args, defaults, overwrites)
File "elastalert/config.py", line 47, in load_conf
configure_logging(args, conf)
File "elastalert/config.py", line 106, in configure_logging
if args.verbose and args.debug:
AttributeError: 'Namespace' object has no attribute 'verbose'
14:44:44.806Z ERROR elastalert-server: ProcessController: ERROR:apscheduler.executors.default:Job "ElastAlerter.handle_config_change (trigger: interval[0:00:05], next run at: 2019-06-26 14:44:49 UTC)" raised an exception Traceback (most recent call last): File "/usr/lib/python2.7/site-packages/APScheduler-3.6.0-py2.7.egg/apscheduler/executors/base.py", line 125, in run_job retval = job.func(*job.args, **job.kwargs) File "/opt/elastalert/elastalert/elastalert.py", line 1211, in handle_config_change self.load_rule_changes() File "/opt/elastalert/elastalert/elastalert.py", line 1094, in load_rule_changes new_rule = self.init_rule(new_rule, False) File "/opt/elastalert/elastalert/elastalert.py", line 957, in init_rule self.scheduler.remove_job(job_id=new_rule['name']) File "/usr/lib/python2.7/site-packages/APScheduler-3.6.0-py2.7.egg/apscheduler/schedulers/base.py", line 621, in remove_job raise JobLookupError(job_id) JobLookupError: u'No job by the id of test was found'
when I use cli to test,it show errors opt/elastalert/rules $ elastalert-test-rule test1.yaml
Traceback (most recent call last):
File "/usr/bin/elastalert-test-rule", line 11, in
update: elasticsearch:6.6.0 kibana:6.6.0 logstash:6.6.0(not used,I use fluentd to collect logs,and keep data on es) fluentd:td-agent 1.4.2 bitsensor/elastalert:3.0.0-beta.0 elastalert-plugin: ./kibana-plugin install file:///tmp/elastalert-kibana-plugin-1.0.2-6.6.0.zip