zas_agent
Zabbix Agent Simulator
Please look at the PDF documentation in the ./doc directory
Zabbix Agent Simulator
License: GNU General Public License v2.0
Zabbix Agent Simulator
Please look at the PDF documentation in the ./doc directory
When I started several zas agent instances on one host with scenarios it uses the same redis instance, right? And data generated by agents are very similar (because it use the same data from redis). Can I use different redis stores for each agent?
I started daemon by this commnad:
zas_agent.py --start --daemonize --listen 127.0.0.1 --port 10060 --redis_host 127.0.0.1 --redis_port 6379 --log '/var/log/zabbix/zas_agent.log'
and then trying to get value from agent:
zabbix_get -s 127.0.0.1 -p 10060 -k agent.ping
but can't get anymore. There is error in log:
INFO:root:Listening 127.0.0.1:10060
DEBUG:zas_server:listening
DEBUG:zas_server:Got connection
DEBUG:zas_server:Started process <Process(Process-1, started daemon)>
DEBUG:process-('127.0.0.1', 41173):Connected <socket._socketobject object at 0x27bf130> at ('127.0.0.1', 41173)
ERROR:process-('127.0.0.1', 41173):Problem handling request
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/zas_agent-0.1.1-py2.7.egg/EGG-INFO/scripts/zas_agent.py", line 268, in handle
File "/usr/lib/python2.7/site-packages/zas_agent-0.1.1-py2.7.egg/EGG-INFO/scripts/zas_agent.py", line 190, in protocol_v1
TypeError: 'NoneType' object is not iterable
DEBUG:process-('127.0.0.1', 41173):Closing socket
When I'm started zas_agent without `--daemonize' it's returns values but I'm get this error in console:
DEBUG:zas_server:Started process <Process(Process-3, started daemon)>
DEBUG:process-('127.0.0.1', 40620):Connected <socket._socketobject object at 0x20eb1a0> at ('127.0.0.1', 40620)
ERROR:process-('127.0.0.1', 40620):Problem handling request
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/zas_agent-0.1.1-py2.7.egg/EGG-INFO/scripts/zas_agent.py", line 271, in handle
File "/usr/lib/python2.7/site-packages/zas_agent-0.1.1-py2.7.egg/EGG-INFO/scripts/zas_agent.py", line 190, in protocol_v1
TypeError: 'NoneType' object is not iterable
DEBUG:process-('127.0.0.1', 40620):Closing socket
I'm trying to put zas_agent into docker container and faced an issue. There's an error during installation, related to numpy
(latest version required python 3.x). So a possible solution is restricting numpy
version in setup.py
.
When zas_agent is started normally all works fine. But if I try to start with --daemonize
agent can't bind address. But procees is running:
[root@myhost zas_agent]# zas_agent.py --start --port 10060 --scenario '/etc/zas_scenario.cfg' --daemonize --pid '/tmp/zas_agent.pid'
[root@myhost zas_agent]# netstat -lnt4
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State
tcp 0 0 0.0.0.0:10050 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:10051 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:6379 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN
[root@myhost zas_agent]# ps -ely | grep zas
S 996 25866 1 0 80 0 10172 54132 skb_re ? 00:00:00 zas_agent.py
Hi!
I'm trying to run zas-agent in docker container, but get error:
root@6a6bc2d2dd98:/zas/zas_agent# zas_agent.py --start
No handlers could be found for logger "zas_agent"
Seems, it's problem with logging
module, but I really don't understand why it causes only in docker.
Hi, Vladimir! Thanks for this great tool! I get error while installing zas_agent:
error: can't copy 'doc/zas-agent.0.1.1.pdf': doesn't exist or not a regular file
It's due in setup.py:
data_files=[
("/etc/zas", ['etc/network.scenario'],),
("/etc", ["etc/zas_scenario.cfg"]),
("/usr/share/zas_agent", ["doc/zas-agent.0.1.1.pdf",]),
...
, but real file name is doc/zas-agent-0.1.1.pdf
.
Is this able to receive output from snmpsim (https://github.com/etingof/snmpsim) and pass that on to zabbix? Would it be better to just use snmpsim directly with zabbix for that?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.