Have Zabbix v5.0 w/ OEC v1.1.4 ... the config.json only allows for a single api_Key, yet we need Zabbix to notify multiple different application teams. I know that we can specify a responder in the call to send2opsgenie, but the issue is all other teams are stuck with the integration settings the primary integration uses, which in my case suppresses alerts. Thus, all other teams have their alerts suppressed.
I attempted to setup a 2nd OEC agent, with a separate config.json. When I start it, I get an error stating it is unable to bind to a tcp port (as the primary oec process has it bound). I'm finding no documentation or way to specify a secondary port for it to listen on. Nor am I sure it would even work bound to a different port.
Hi @DMC
Yes, you can run multiple OEC services on a single host
When it comes to setting up your secondary OEC to run on another port here are some steps on how you can do this:
Edit /etc/systemd/system/oec_custom.service change the line ExecStart=/usr/local/bin/OpsgenieEdgeConnector
add the parameter --oec-metrics with a unique port value (the default value is 7070) for exampleExecStart=/usr/local/bin/OpsgenieEdgeConnector --oec-metrics 7071
Edit /etc/systemd/system/oec_custom.service change the line Environment="OEC_CONF_LOCAL_FILEPATH=/home/opsgenie/oec/conf/config.json"
edit it to reflect the new path of config.json Environment="OEC_CONF_LOCAL_FILEPATH=/home/opsgenie/oec/conf/config.json"
(See the paths highlighted green in the screenshots below)
systemctl enable oec_custom
Edit oecService64.json
update the service name (highlighted pink), oec-metrics port (highlighted green) and update the file paths to reflect the new folder’s path (highlighted blue).
cd "c:\opsgenie\oec_custom"
.\oecService64.exe install
.\oecService64.exe start
Thanks Connor. Appreciate the timely response.
Here's what I've learned, while testing this. I'm not sure you need multiple OEC agents running. I found that the OEC agent is only used during INBOUND communications. I was under the impression that the send2opsgenie command was using it for outbound.
Seems the OpsGenie integration can be selected by specifying the '-apiKey=xxxxx' flag to my 'send2opsgenie' command.
The other observation, was than while running two OEC agents, there was no difference. Both agents seem to be pulling from the same OpsGenie cloud queue. Such that when an event/alert is acknowledged both of them would attempt to action it.
At this point, I don't believe I see a need to have more than a single OEC agent. However, I certainly appreciate the response Connor.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @dmc
You are correct, OEC is used for inbound communication. Glad to hear you got this one working regardless!
The above steps are how you can run multiple OEC agents on different ports
Thanks,
Connor
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.