Zabbix 5.2 Postgresql 13 Centos 8 Apache 2.4 Install Memo

Zabbix 5.2 Postgresql 13 Centos8 Apache Install 
1.  PostgreSQL13 Installとsetup
--postgresのバスワードを設定変更するのを忘れないように注意
su postgres
alter role postgres with password 'Passwd643';
Screenshot from 2021-03-14 14-02-13.png
----
pg_hba.confとpostgres.confを設定して、外部のPgAdminなとから、接続できるか確認する
で、postgres.confのチューニングも可能

2. ファイアーウォールとSELinuxの無効化をして、システム再起動
firewall-cmd --add-port=5432/tcp --zone=public --permanent
firewall-cmd --add-port=10051/tcp --zone=public --permanent
firewall-cmd --add-service=http --zone=public --permanent
firewall-cmd --add-port=5432/tcp --zone=public --permanent
sed -i -e "s/^SELINUX=enforcing$/SELINUX=disabled/g" /etc/selinux/config 
systemctl reboot
Screenshot from 2021-03-14 14-02-38.png

3. システム再起動後、SELinuxの無効化の確認
getenforce
Screenshot from 2021-03-14 14-05-00.png

4.
dnf -y module install httpd
Screenshot from 2021-03-14 14-06-29.png

5.
dnf -y module install php
Screenshot from 2021-03-14 14-07-12.png

6. Install and configure Zabbix server for your platformのコマンドを実行
001.png
002.png
---------------------------
a. Install Zabbix repository
---------------------------
b. Install Zabbix server, frontend, agent
# dnf install zabbix-server-pgsql zabbix-web-pgsql zabbix-apache-conf zabbix-agent
Screenshot from 2021-03-14 14-17-58.png
yで進む
Screenshot from 2021-03-14 14-18-12.png
Screenshot from 2021-03-14 14-18-33.png
---------------------------
c. Create initial database / Make sure you have database server up and running. /Run the following on your database host.
# sudo -u postgres createuser --pwprompt zabbix
# sudo -u postgres createdb -O zabbix zabbix
Screenshot from 2021-03-14 14-19-32.png
On Zabbix server host import initial schema and data. You will be prompted to enter your newly created password.
# zcat /usr/share/doc/zabbix-server-pgsql*/create.sql.gz | sudo -u zabbix psql zabbix
Screenshot from 2021-03-14 14-20-25.png
---------------------------
d. Configure the database for Zabbix server
Edit file /etc/zabbix/zabbix_server.conf
Screenshot from 2021-03-14 14-21-35.png
DBPassword=Passwd643
---------------------------
e. Start Zabbix server and agent processes
Start Zabbix server and agent processes and make it start at system boot.
# systemctl restart zabbix-server zabbix-agent httpd php-fpm
# systemctl enable zabbix-server zabbix-agent httpd php-fpm
Screenshot from 2021-03-14 14-22-14.png
---------------------------
f. Zabbixフロントエンドの設定
Connect to your newly installed Zabbix frontend: http://server_ip_or_name/zabbix
Follow steps described in Zabbix documentation: Installing frontend
127.0.0.1/zabbix
初期ログイン
Admin (Aが大文字です)
zabbix
---------------------------
127.0.0.1 で、 apacheの初期画面が表示
Screenshot from 2021-03-14 14-38-56.png
---------------------------
127.0.0.1 /zabbix で、 zabbixの初期画面が表示
Screenshot from 2021-03-14 14-39-02.png

01
01.png
02
02.png
03
03.png
04 PostgreSQL の パスワードを入力
04.png
05
05.png
06
06.png
07
07.png
08
08.png
09
09.png
10
10.png
11
11.png
12
12.png

pgAdmin4からアクセス
pgadmin.png