ubuntu 编译安装 zabbix 4.0.10

1.安装mariadb 数据库

apt-get  install  mariadb-server mariadb-client

2.安装依赖包

apt-get  install   apache2 apache2-bin apache2-data apache2-utils fontconfig-config fonts-dejavu-core fping libapache2-mod-php   libapache2-mod-php7.2 libapr1 libaprutil1 libaprutil1-dbd-sqlite3 libaprutil1-ldap libfontconfig1 libgd3 libiksemel3   libjbig0 libjpeg-turbo8 libjpeg8 liblua5.2-0 libodbc1 libopenipmi0 libsensors4 libsnmp-base libsnmp30 libsodium23 libssh2-1  libtiff5 libwebp6 libxpm4 php-bcmath php-common php-gd php-ldap php-mbstring php-mysql php-xml php7.2-bcmath php7.2-cli  php7.2-common php7.2-gd php7.2-json php7.2-ldap php7.2-mbstring php7.2-mysql php7.2-opcache php7.2-readline   php7.2-xml snmpd  ssl-cert ttf-dejavu-core      libmysqlclient-dev  libxml2-dev  libxml2 snmp  libsnmp-dev   libevent-dev  openjdk-8-jdk curl libcurl4-openssl-dev 

3.编译及安装zabbix 4.0.10

./configure --prefix=/apps/zabbix_server  --enable-server --enable-agent --with-mysql  --with-net-snmp --with-libcurl --with-libxml2  --enable-java
make
make install

4.数据库初始化:

mysql -uzabbix -p123456 -h192.168.7.108 zabbix_server  < schema.sql
mysql -uzabbix -p123456 -h192.168.7.108 zabbix_server  <  images.sql
mysql -uzabbix -p123456 -h192.168.7.108 zabbix_server  <  data.sql 

5.启动apache2:

6.解决php依赖:

apt-get   install php-gettext   php-xml php-net-socket php-gd php-mysql

你可能感兴趣的:(ubuntu 编译安装 zabbix 4.0.10)