반응형
Zabbix 모니터링을 위한 client 설정이다.
zabbix repository 설치 및 설정
[root@client01 ~]# yum -y install http://repo.zabbix.com/zabbix/4.2/rhel/7/x86_64/zabbix-release-4.2-1.el7.noarch.rpm
Loaded plugins: fastestmirror
zabbix-release-4.2-1.el7.noarch.rpm | 13 kB 00:00:00
Examining /var/tmp/yum-root-2lwhMj/zabbix-release-4.2-1.el7.noarch.rpm: zabbix-release-4.2-1.el7.noarch
Marking /var/tmp/yum-root-2lwhMj/zabbix-release-4.2-1.el7.noarch.rpm to be installed
Resolving Dependencies
--> Running transaction check
---> Package zabbix-release.noarch 0:4.2-1.el7 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
==========================================================================================================================================================================================================================================================================================================================================================================================
Package Arch Version Repository Size
==========================================================================================================================================================================================================================================================================================================================================================================================
Installing:
zabbix-release noarch 4.2-1.el7 /zabbix-release-4.2-1.el7.noarch 21 k
Transaction Summary
==========================================================================================================================================================================================================================================================================================================================================================================================
Install 1 Package
Total size: 21 k
Installed size: 21 k
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing : zabbix-release-4.2-1.el7.noarch 1/1
Verifying : zabbix-release-4.2-1.el7.noarch 1/1
Installed:
zabbix-release.noarch 0:4.2-1.el7
Complete!
zabbix agent를 설치 한다.
[root@client01 ~]# yum -y install zabbix-agent
Zabbix agent config를 변경한다.
[root@client01 ~]# cd /etc/zabbix/
[root@client01 zabbix]# pwd
/etc/zabbix
[root@client01 zabbix]# cp -rpRf zabbix_agentd.conf zabbix_agentd.conf.orig
[root@client01 zabbix]# vi zabbix_agentd.conf
~(생략)
97
98 Server=172.10.2.111 ## Zabbix server IP 입력
~(생략)
139 ServerActive=172.10.2.111 ## Zabbix server IP 입력
~(생략)
150 Hostname=zabbix_client01 ## Local hostname 입력
zabbix agent 를 실행/설정한다.
[root@client01 zabbix]# systemctl start zabbix-agent
[root@client01 zabbix]# systemctl enable zabbix-agent
Created symlink from /etc/systemd/system/multi-user.target.wants/zabbix-agent.service to /usr/lib/systemd/system/zabbix-agent.service.
[root@client01 zabbix]# systemctl status zabbix-agent
● zabbix-agent.service - Zabbix Agent
Loaded: loaded (/usr/lib/systemd/system/zabbix-agent.service; enabled; vendor preset: disabled)
Active: active (running) since 월 2019-07-08 10:38:15 KST; 8s ago
Main PID: 4177 (zabbix_agentd)
CGroup: /system.slice/zabbix-agent.service
├─4177 /usr/sbin/zabbix_agentd -c /etc/zabbix/zabbix_agentd.conf
├─4178 /usr/sbin/zabbix_agentd: collector [idle 1 sec]
├─4179 /usr/sbin/zabbix_agentd: listener #1 [waiting for connection]
├─4180 /usr/sbin/zabbix_agentd: listener #2 [waiting for connection]
├─4181 /usr/sbin/zabbix_agentd: listener #3 [waiting for connection]
└─4182 /usr/sbin/zabbix_agentd: active checks #1 [idle 1 sec]
7월 08 10:38:15 client01 systemd[1]: Starting Zabbix Agent...
7월 08 10:38:15 client01 systemd[1]: PID file /run/zabbix/zabbix_agentd.pid not readable (yet?) after start.
7월 08 10:38:15 client01 systemd[1]: Started Zabbix Agent.
zabbix dashbord에 admin계정으로 접속한다.
client를 추가 하기 위해 configuration > Hosts > CreateHost를 선택한다.
추가하는 Client의 정보를 입력한다.
Template tab으로 이동하여 tamplate를 추가 한다.
"Link new templates"의 "Add" 를 클릭하여 해당 template가 "Linked templates"로 등록되는지 확인하고 하단의 "Add"를 클릭하여 설정한다.
Client가 추가 되면 하단에 추가된 client가 등록된것을 확인 할 수 있다.
모니터링 수집을 위해 5분정도 이후 monitoring > Graphs 로 가서 모니터링 상태를 확인 할 수 있다. CPU와 Memory는 약 1분 정도만 지나면 바로 확인 할 수 있으나 네트워크 인터페이스의 경우 다소 시간이 필요한다.
반응형
'운영체제 > Linux' 카테고리의 다른 글
[Linux] hostname 변경 (0) | 2019.10.17 |
---|---|
[Linux - 보안조치] 계정 잠금 임계값 설정 (0) | 2019.10.16 |
[Linux - UTIL ] Zabbix admin password 변경 (0) | 2019.07.08 |
[Linux - UTIL ] Zabbix 모니터링 tool - Initial Setup (0) | 2019.07.08 |
[Linux - UTIL ] Zabbix 모니터링 tool - Install (0) | 2019.07.05 |