Skip to content

Instantly share code, notes, and snippets.

@aortmannm
Last active May 5, 2020 01:38
Show Gist options
  • Save aortmannm/5262113 to your computer and use it in GitHub Desktop.
Save aortmannm/5262113 to your computer and use it in GitHub Desktop.
installing zabbix on smartOS
## download newest Version of zabbix
wget http://downloads.sourceforge.net/project/zabbix/ZABBIX%20Latest%20Stable/2.0.5/zabbix-2.0.5.tar.gz?r=http%3A%2F%2Fwww.zabbix.com%2Fdownload.php&ts=1364462224&use_mirror=freefr
## untar the package
tar -zxvf zabbix-2.0.5.tar.gz
## add user and group zabbix
groupadd zabbix
useradd -g zabbix zabbix
## Configuring the Database on another zone follow my zabbix-percona.txt
# Set DBUser etc..of the external database in the zabbix_server.conf
zabbix_server.conf> LogFile=/var/log/zabbix_server.log
zabbix_server.conf> LogFileSize=100
zabbix_server.conf> PidFile=/var/log/zabbix_server.pid
zabbix_server.conf> DBHost=IP
zabbix_server.conf> DBUser=zabbix
zabbix_server.conf> DBPassword=password
zabbix_server.conf> DBPort=3306
## Install necessary packages
pkgin in gcc47-4.7.0nb2
pkgin in mysql-client-5.5.25
pkgin in curl-7.28.1nb3
pkgin in net-snmp-5.6.1.1nb3
pkgin in cmake
pkgin in gmake
pkgin in apache-2.4.2nb2
pkgin in ap24-php54-5.4.5
pkgin in php54-bcmath-5.4.5
pkgin in php54-mbstring-5.4.5
pkgin in php54-sockets-5.4.5
pkgin in php54-gd-5.4.5
pkgin in php54-xmlrpc-5.4.5
pkgin in php54-gettext-5.4.5
pkgin in php54-mysql-5.4.5
## Edit httpd.conf
## if u you got a problem by starting apache server http://tgrove.com/2007/12/02/httpd-apr_sockaddr_info_get-failed-for-hostname/
## give user and group rights
chown -R zabbix:zabbix /var/log
chown -R zabbix:zabbix /var/run
crle -64 /usr/local/mysql/lib
crle -64 -u -l /usr/local/mysql/lib -l /usr/lib
crle -64 -u -l /usr/local/mysql/lib -l /usr/lib -l /opt/local/lib
## Configur the zabbix server
./configure --enable-server --enable-agent --with-net-snmp --with-libcurl --with-mysql --with-iconv=/opt/local/bin --with-iconv-include=/opt/local/include --with-iconv-lib=/opt/local/lib
./configure --enable-server --enable-agent --with-net-snmp --with-libcurl --enable-sysvsem --with-mysql --with-iconv=/opt/local/bin --with-iconv-include=/opt/local/include --with-iconv-lib=/opt/local/lib
./configure --enable-server --with-net-snmp --with-libcurl --with-mysql --with-iconv=/opt/local/bin --with-iconv-include=/opt/local/include --with-iconv-lib=/opt/local/lib
make install
cp -r /opt/zabbix-2.0.5/frontends/php/* c
crle -64 -u -l /upgrades/dbpatches/2.0/mysql -l /database/mysql -l /opt/local/lib
chmod 777 /var/log/
chmod 777 /opt/local/sbin/httpd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment