How To Install Zabbix on Slackware

IT Consultant

How To Install Zabbix on Slackware

zabbix is monitoring that can monitor network, database, memory usage, and cpu usage

Prerequisites

  • Mysql
  • Http / apache

Installation

1.Create the zabbix user and group

bash-4.3# groupadd -g 228 zabbix
bash-4.3# useradd -d /dev/null -s /bin/false -u 228 -g 228 zabbix

2.Install dependencies via

3.Create the MySQL database

mysql> create database zabbix character set utf8;
mysql> use mysql;
mysql> grant all on zabbix.* to zabbix@localhost identified by
'<password>';
mysql> flush privileges;
mysql> quit

4. Import database

bash-4.3# cd /usr/share/zabbix_server/create
bash-4.3# mysql -u zabbix -p <zabbix_password>
mysql> use zabbix;
mysql> source schema/mysql.sql;
mysql> source data/data.sql;
mysql> source data/images_mysql.sql;
mysql> quit

5.Configurasi PHP

a) Zabbix requires some parameters in /etc/httpd/php.ini to be alter

post_max_size = 16M               (Default = 8M)
max_execution_time = 300          (Default = 30)
max_input_time = 300              (Default = 60)
date.timezone = America/Chicago   (Default = blank)
***NOTE*** the ";" in front of date.timezone MUST be removed

b) Enable PHP in bash-4.3# vi /etc/httpd/httpd.conf

  • ADD: index.php to the “DirectoryIndex index.html” line.
  • UNCOMMENT: “Include /etc/httpd/mod_php.conf” line.

c) Restart your apachebash-4.3# /etc/rc.d/rc.httpd restart

 

6. Edit the zabbix_server configuration => /etc/zabbix/zabbix_server.conf

DBUser=zabbix           (Default is "root" and it's not a good idea)
DBPassword=<zabbix_password>     (Change as defined above)

7. Make /etc/rc.d/rc.zabbix_server executable

bash-4.3# chmod +x /etc/rc.d/rc.zabbix_server

8. Start zabbix server

bash-4.3# /etc/rc.d/rc.zabbix_server star

9. Access zabbix via your browser http://localhost

   USER: Admin
   PASS: zabbix

Leave a Reply

Your email address will not be published. Required fields are marked *