so recently I tried to monitor a machine which had mongoDB installed and want to monitor my db via zabbix. and I believe I've done it correctly and all. but for some reason it doesn't seem to be working. ill send zabbix logs and configurations for you maybe that helps with finding out the problem and solving it
these are my agent logs when I restart my agent
```
2023/09/20 10:15:19.119330 Starting Zabbix Agent 2 (6.4.3)
2023/09/20 10:15:19.119966 OpenSSL library (OpenSSL 1.1.1 11 Sep 2018) initialized
2023/09/20 10:15:19.120083 using configuration file: /etc/zabbix/zabbix_agent2.conf
2023/09/20 10:15:19.120261 using plugin 'Agent' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120286 using plugin 'Ceph' (built-in) providing following interfaces: exporter, runner, configurator
2023/09/20 10:15:19.120303 using plugin 'Cpu' (built-in) providing following interfaces: exporter, collector, runner
2023/09/20 10:15:19.120327 using plugin 'DNS' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120342 using plugin 'Docker' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120358 using plugin 'File' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120387 using plugin 'Hw' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120403 using plugin 'Kernel' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120418 using plugin 'Log' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120431 using plugin 'MQTT' (built-in) providing following interfaces: watcher, configurator
2023/09/20 10:15:19.120446 using plugin 'Memcached' (built-in) providing following interfaces: exporter, runner, configurator
2023/09/20 10:15:19.120461 using plugin 'Memory' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120482 using plugin 'Modbus' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120508 using plugin 'Mysql' (built-in) providing following interfaces: exporter, runner, configurator
2023/09/20 10:15:19.120539 using plugin 'NetIf' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120554 using plugin 'Oracle' (built-in) providing following interfaces: exporter, runner, configurator
2023/09/20 10:15:19.120571 using plugin 'Proc' (built-in) providing following interfaces: exporter, collector
2023/09/20 10:15:19.120585 using plugin 'ProcExporter' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120600 using plugin 'Redis' (built-in) providing following interfaces: exporter, runner, configurator
2023/09/20 10:15:19.120615 using plugin 'Smart' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120643 using plugin 'Sw' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120680 using plugin 'Swap' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120722 using plugin 'SystemRun' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120735 using plugin 'Systemd' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120774 using plugin 'TCP' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120791 using plugin 'UDP' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120806 using plugin 'Uname' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120827 using plugin 'Uptime' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120841 using plugin 'UserParameter' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120853 using plugin 'Users' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120866 using plugin 'VFSDev' (built-in) providing following interfaces: exporter, collector
2023/09/20 10:15:19.120954 using plugin 'VFSDir' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120972 using plugin 'VfsFs' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120985 using plugin 'WebCertificate' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120998 using plugin 'WebPage' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.121010 using plugin 'ZabbixAsync' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.121024 using plugin 'ZabbixStats' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.121036 lowering the plugin ZabbixSync capacity to 1 as the configured capacity 100 exceeds limits
2023/09/20 10:15:19.121048 using plugin 'ZabbixSync' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.121199 Plugin communication protocol version is 6.4.0
2023/09/20 10:15:19.121255 Zabbix Agent2 hostname: [Karaj_Kateb_Mongo3]
```
as you can see it doesn't seem to be starting the mongodb plugin. though i installed it via apt using sudo apt install zabbix-agent2-plugin-mongodb command
then i went to /etc/zabbix/zabbix_agent2.d/plugins.d/mongodb.conf to edit the config files accordingly here are the lines I included(ive tried quite some variations to get it to work. didn't help with any of them)
```
### Option:Plugins.MongoDB.System.Path
# Path to external plugin executable.
#
# Mandatory: yes
# Default:
# Plugins.MongoDB.System.Path=
#Plugins.MongoDB.System.Path=/usr/sbin/zabbix-agent2-plugin/zabbix-agent2-plugin-mongodb*
#Plugins.MongoDB.System.Path=/usr/bin/mongod
Plugins.MongoDB.System.Path=/opt/mongo/defaults/bin/mongo
#Include=/opt/mongoDB/mongodb.conf
Include=/etc/zabbix/zabbix_agent2.d/plugins.d/mongodb.conf
```
these seem to be fine I've double checked all the locations and files exist
on zabbix web im using MongoDB node by Zabbix agent 2
also here are the zabbix web configs
but still it doesnt send data when i go to the latest data section, there are error on all mongodb items the error is Unknown metric mongodb.server.status without giving any data I can use to troubleshoot
so is can anyone help me with this please? I've searched for a solution online and read the docs on the plugin. couldn't find anything to help with this. also if you need other logs or info that could help you with this please let me know.
btw this is a repost, I originally posted it on the Zabbix Suggestions and Feedback forum but didn't get any answers(and as weird as it sounds I can not delete that post there is literally no option to do so) so here I am. and
these are my agent logs when I restart my agent
```
2023/09/20 10:15:19.119330 Starting Zabbix Agent 2 (6.4.3)
2023/09/20 10:15:19.119966 OpenSSL library (OpenSSL 1.1.1 11 Sep 2018) initialized
2023/09/20 10:15:19.120083 using configuration file: /etc/zabbix/zabbix_agent2.conf
2023/09/20 10:15:19.120261 using plugin 'Agent' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120286 using plugin 'Ceph' (built-in) providing following interfaces: exporter, runner, configurator
2023/09/20 10:15:19.120303 using plugin 'Cpu' (built-in) providing following interfaces: exporter, collector, runner
2023/09/20 10:15:19.120327 using plugin 'DNS' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120342 using plugin 'Docker' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120358 using plugin 'File' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120387 using plugin 'Hw' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120403 using plugin 'Kernel' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120418 using plugin 'Log' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120431 using plugin 'MQTT' (built-in) providing following interfaces: watcher, configurator
2023/09/20 10:15:19.120446 using plugin 'Memcached' (built-in) providing following interfaces: exporter, runner, configurator
2023/09/20 10:15:19.120461 using plugin 'Memory' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120482 using plugin 'Modbus' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120508 using plugin 'Mysql' (built-in) providing following interfaces: exporter, runner, configurator
2023/09/20 10:15:19.120539 using plugin 'NetIf' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120554 using plugin 'Oracle' (built-in) providing following interfaces: exporter, runner, configurator
2023/09/20 10:15:19.120571 using plugin 'Proc' (built-in) providing following interfaces: exporter, collector
2023/09/20 10:15:19.120585 using plugin 'ProcExporter' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120600 using plugin 'Redis' (built-in) providing following interfaces: exporter, runner, configurator
2023/09/20 10:15:19.120615 using plugin 'Smart' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120643 using plugin 'Sw' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120680 using plugin 'Swap' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120722 using plugin 'SystemRun' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120735 using plugin 'Systemd' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120774 using plugin 'TCP' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120791 using plugin 'UDP' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120806 using plugin 'Uname' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120827 using plugin 'Uptime' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120841 using plugin 'UserParameter' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120853 using plugin 'Users' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120866 using plugin 'VFSDev' (built-in) providing following interfaces: exporter, collector
2023/09/20 10:15:19.120954 using plugin 'VFSDir' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120972 using plugin 'VfsFs' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.120985 using plugin 'WebCertificate' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.120998 using plugin 'WebPage' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.121010 using plugin 'ZabbixAsync' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.121024 using plugin 'ZabbixStats' (built-in) providing following interfaces: exporter, configurator
2023/09/20 10:15:19.121036 lowering the plugin ZabbixSync capacity to 1 as the configured capacity 100 exceeds limits
2023/09/20 10:15:19.121048 using plugin 'ZabbixSync' (built-in) providing following interfaces: exporter
2023/09/20 10:15:19.121199 Plugin communication protocol version is 6.4.0
2023/09/20 10:15:19.121255 Zabbix Agent2 hostname: [Karaj_Kateb_Mongo3]
```
as you can see it doesn't seem to be starting the mongodb plugin. though i installed it via apt using sudo apt install zabbix-agent2-plugin-mongodb command
then i went to /etc/zabbix/zabbix_agent2.d/plugins.d/mongodb.conf to edit the config files accordingly here are the lines I included(ive tried quite some variations to get it to work. didn't help with any of them)
```
### Option:Plugins.MongoDB.System.Path
# Path to external plugin executable.
#
# Mandatory: yes
# Default:
# Plugins.MongoDB.System.Path=
#Plugins.MongoDB.System.Path=/usr/sbin/zabbix-agent2-plugin/zabbix-agent2-plugin-mongodb*
#Plugins.MongoDB.System.Path=/usr/bin/mongod
Plugins.MongoDB.System.Path=/opt/mongo/defaults/bin/mongo
#Include=/opt/mongoDB/mongodb.conf
Include=/etc/zabbix/zabbix_agent2.d/plugins.d/mongodb.conf
```
these seem to be fine I've double checked all the locations and files exist
on zabbix web im using MongoDB node by Zabbix agent 2
also here are the zabbix web configs
but still it doesnt send data when i go to the latest data section, there are error on all mongodb items the error is Unknown metric mongodb.server.status without giving any data I can use to troubleshoot
so is can anyone help me with this please? I've searched for a solution online and read the docs on the plugin. couldn't find anything to help with this. also if you need other logs or info that could help you with this please let me know.
btw this is a repost, I originally posted it on the Zabbix Suggestions and Feedback forum but didn't get any answers(and as weird as it sounds I can not delete that post there is literally no option to do so) so here I am. and