标签:
yum -y install gcc gcc-c++ autoconf httpd php mysql mysql-server php-mysql httpd-manual mod_ssl mod_perl mod_auth_mysql php-gd php-xml php-mbstring php-ldap php-pear php-xmlrpc php-bcmath mysql-connector-odbc mysql-devel libdbi-dbd-mysql net-snmp-devel curl-devel unixODBC-devel OpenPMI-devel java-devel libxml2-devel
create database zabbix character set utf8; grant all privileges on zabbix.* to zabbix@localhost identified by ‘zabbix‘;
tar xf zabbix-2.2.0.tar.gz cd zabbix-2.2.0 ./configure --prefix=/usr/local/zabbix --enable-server --enable-agent --with-mysql --with-net-snmp --with-libcurl make install
mysql zabbix < database/mysql/schema.sql mysql zabbix < database/mysql/images.sql mysql zabbix < database/mysql/data.sql
cp misc/init.d/fedora/core/zabbix_server /etc/init.d/ cp misc/init.d/fedora/core/zabbix_agentd /etc/init.d/ cp -R frontends/php /var/www/html/zabbix sed -i ‘s/^DBUser=.*$/DBUser=zabbix/g‘ /usr/local/zabbix/etc/zabbix_server.conf sed -i ‘s/^.*DBPassword=.*$/DBPassword=zabbix/g‘ /usr/local/zabbix/etc/zabbix_server.conf sed -i ‘s/BASEDIR=\/usr\/local/BASEDIR=\/usr\/local\/zabbix/g‘ /etc/init.d/zabbix_server sed -i ‘s/BASEDIR=\/usr\/local/BASEDIR=\/usr\/local\/zabbix/g‘ /etc/init.d/zabbix_agentd
cat >>/etc/services <<EOF zabbix-agent 10050/tcp Zabbix Agent zabbix-agent 10050/udp Zabbix Agent zabbix-trapper 10051/tcp Zabbix Trapper zabbix-trapper 10051/udp Zabbix Trapper EOF
/etc/init.d/zabbix_server start /etc/init.d/zabbix_agentd start /etc/init.d/httpd start echo "/etc/init.d/zabbix_server start" >> /etc/rc.local echo "/etc/init.d/zabbix_agentd start" >> /etc/rc.local
zabbix2.2部署安装(安装环境Centos 6.* X64)
标签:
原文地址:http://www.cnblogs.com/tiantiandas/p/5621879.html