ubuntu14.04 Zabbix安装
apt-get update
apt-get install apache2 mysql-server libapache2-mod-php5 php5-gd php5-mysql php5-common zabbix-server-mysql zabbix-frontend-php
vim /etc/zabbix/zabbix_server.conf
DBName=zabbix
DBUser=zabbix
DBPassword=zabbix#非必需,但推荐
StartDiscoverers=5
创建mysql账号
mysql -u root -p
mysql> create user 'zabbix'@'localhost' identified by 'zabbix';
mysql> create database zabbix;
mysql> grant all privileges on zabbix.* to 'zabbix'@'localhost';
mysql> flush privileges;
mysql> exit;
导入初始化数据
cd /usr/share/zabbix-server-mysql/
gunzip *.gz
mysql -u zabbix -p zabbix < schema.sql
mysql -u zabbix -p zabbix < images.sql
mysql -u zabbix -p zabbix < data.sql
修改PHP参数
vim /etc/php5/apache2/php.ini
post_max_size = 32M
max_execution_time = 600
max_input_time = 600
date.timezone = "Asia/Shanghai"
配置网页
cp /usr/share/doc/zabbix-frontend-php/examples/zabbix.conf.php.example /etc/zabbix/zabbix.conf.phpsudo
vim /etc/zabbix/zabbix.conf.php
$DB['DATABASE'] = 'zabbix';
$DB['USER'] = 'zabbix';
$DB['PASSWORD'] = 'zabbix'
配置apache
cp /usr/share/doc/zabbix-frontend-php/examples/apache.conf /etc/apache2/conf-available/zabbix.conf
a2enconf zabbix.conf
a2enmod alias
service apache2 restart
配置Zabbix Server 服务启动
vim /etc/default/zabbix-server
START=yes
service zabbix-server start
访问http://IP地址/zabbix 缺省账户密码是 admin zabbix