https://github.com/smejdil/pgsql-mon-zbx-fbsd
Easy script for setup Zabbix and PostgreSQL monitoring on FreeBSD
https://github.com/smejdil/pgsql-mon-zbx-fbsd
ansible-playbook freebsd postgresql zabbix zabbix-agent
Last synced: 10 months ago
JSON representation
Easy script for setup Zabbix and PostgreSQL monitoring on FreeBSD
- Host: GitHub
- URL: https://github.com/smejdil/pgsql-mon-zbx-fbsd
- Owner: smejdil
- License: gpl-3.0
- Created: 2021-05-12T07:12:24.000Z (about 5 years ago)
- Default Branch: main
- Last Pushed: 2021-05-12T09:54:14.000Z (about 5 years ago)
- Last Synced: 2025-01-07T18:42:33.088Z (over 1 year ago)
- Topics: ansible-playbook, freebsd, postgresql, zabbix, zabbix-agent
- Language: PLpgSQL
- Homepage:
- Size: 30.3 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# pgsql mon zbx fbsd
Easy script for setup Zabbix and PostgreSQL monitoring on FreeBSD
Tested: FreeBSD 13.0, Zabbix 5.0.11, PostgreSQL 12.6 + TimescaleDB 2.2.1
### Packages FreeBSD
- Package - py38-pip-20.3.4 Tool for installing and managing Python packages
- Package - py38-ansible-2.9.21_1 Radically simple IT automation
### How it works
Configure zabbix agent for PostgreSQL monitoring. https://git.zabbix.com/projects/ZBX/repos/zabbix/browse/templates/db/postgresql?at=refs%2Ftags%2F5.0.11 And ansible use collections
https://galaxy.ansible.com/community/zabbix and by Zabbix API import PosgreSQL Template and
update Zabbix server host.
- Python package - zabbix-api 0.5.4
### Install FreeBSD
```console
cd /usr/ports/devel/py-pip && make install clean
cd /usr/ports/sysutils/ansible && make install clean
pip install zabbix-api
```
### Install ansible collection zabbix
```console
ansible-galaxy collection install -r requirements.yml
Process install dependency map
Starting collection install process
Installing 'community.zabbix:1.3.0' to '/root/.ansible/collections/ansible_collections/community/zabbix'
```
### Run playbook
```console
export ZABBIX_USER=ansible
export ZABBIX_PASSWORD=*******************
setup-pgsql-monitoring.sh
```
### To do
- Configure zabbix agent by ansible