Zabbix Agent

AIX 
 Download: https://www.zabbix.com/download 
 
 必須新增一個帳號名 zabbix。 
 
 AIX 7.2 
 # Using smitty users to add a user zabbix and the home directory is /usr/local/zabbix

# Untar the zabbix source
su - zabbix
gunzip -c zabbix_agent-4.0.7-aix-7.2-powerpc.tar.gz | tar -xf -

# Edit the config file
vi /usr/local/zabbix/conf/zabbix_agentd.conf

Server=<Zabbix-Server-IP>
ServerActive=<Zabbix-Server-IP>
Hostname=<agent-hostname>

# Startup the agent
/usr/local/zabbix/sbin/zabbix_agentd -c /usr/local/zabbix/conf/zabbix_agentd.conf 
 start.sh 
 #!/usr/bin/env bash

zabbix_home="/usr/local/zabbix"
cd $zabbix_home
pid=$(ps -ef | grep "zabbix_agentd.conf" | grep -v grep | awk '{print $2}')
[ -n "$pid" ] && echo "The Zabbix is already running!" && exit
$zabbix_home/sbin/zabbix_agentd -c $zabbix_home/conf/zabbix_agentd.conf
[ $? -eq 0 ] && echo "Started the zabbix" 
 stop.sh 
 #!/usr/bin/env bash

zabbix_home="/usr/local/zabbix"
pid=$(ps -ef | grep "zabbix_agentd.conf" | grep -v grep | awk '{print $2}')
[ -n "$pid" ] && kill $pid && echo "Killed the zabbix" 
  