You are on page 1of 5

19/9/2017 Install on openSUSE / SLES - Zabbix.

org

Install on openSUSE / SLES


From Zabbix.org

Contents
1 Adding required repositories
2 Server Install
2.1 Database
2.1.1 MySQL
2.1.2 PostgreSQL
2.2 Zabbix Server
3 Front-end Install
4 Java Gateway Install
5 Agent Install
5.1 Linux
5.2 Windows

Adding required repositories


At http://download.opensuse.org/repositories/server:/monitoring/ you can see different possible repository URLs, please select one which is
installed on your system For openSUSE Leap 42.1:

zypper addrepo http://download.opensuse.org/repositories/server:monitoring/openSUSE_Leap_42.1/server:monitoring.repo

For openSUSE 12.3 you should use command line below:

zypper addrepo http://download.opensuse.org/repositories/server:/monitoring/openSUSE_12.3 server_monitoring

or for SLES 11 SP3 would be:

zypper addrepo http://download.opensuse.org/repositories/server:/monitoring/SLE_11_SP3/ server_monitoring

and after adding repository run

zypper update

Server Install
Depending on your choice of database backend you should install corresponding zabbix package

for mysql

zypper install zabbix-server-mysql

for postgresql

zypper install zabbix-server-postgresql

or just for testing purposes sqlite backend is available as package too (not recommended)

zypper install zabbix-server-sqlite

https://www.zabbix.org/wiki/Install_on_openSUSE_/_SLES 1/5
19/9/2017 Install on openSUSE / SLES - Zabbix.org

Database
You can install the database on the same server, or on another server.

MySQL
Install mysql server and client (on recent openSUSE versions this installs MariaDB, but that should not pose any problems as it is an in-
place replacement of mysql)

zypper install mysql mysql-client

Start MySQL Database Server and secure

rcmysql start
mysql_secure_installation
mysql -u root -p

In the MySQL console


replace <zabbixserverhost.domain.name> by the FQDN of the zabbix server (you can use localhost if the DB is on the same server)
replace <zabbixserverip> by the IP address of the zabbix server (you can leave those 2 lines out if the DB is on the same server)
if you will run the zabbix frontend on a third server, you should also copy these 4 lines with the FQDN and IP of the frontend server
replace 'password' by the actual password you want for the zabbix database user

mysql> create database zabbix character set utf8;


mysql> grant all privileges on zabbix.* to zabbix@<zabbixserverhost.domain.name>;
mysql> grant usage on *.* to zabbix@<zabbixserverhost.domain.name> identified by 'zabbix';
mysql> grant all privileges on zabbix.* to zabbix@<zabbixserverip>;
mysql> grant usage on *.* to zabbix@<zabbixserverip> identified by 'zabbix';
mysql> set password for zabbix = password('password');
mysql> exit

Copy the DB schemes from /usr/share/doc/packages/zabbix-server/mysql/ to the database server if needed


and import the schemes:

mysql -uroot -p zabbix < schema.sql


mysql -uroot -p zabbix < images.sql
mysql -uroot -p zabbix < data.sql

Configure mysql to start up during server boot:

insserv mysql

PostgreSQL

Install PostgreSQL server

zypper install postgresql-server

Start PostgreSQL Database Server and secure

rcpostgresql start

or using systemd syntax (only on openSUSE >= 12.1)

systemctl start postgresql.service

Login as postgres superuser into PostgreSQL prompt

su - postgres
psql

https://www.zabbix.org/wiki/Install_on_openSUSE_/_SLES 2/5
19/9/2017 Install on openSUSE / SLES - Zabbix.org
In the PostgreSQL console
replace 'ohmybestpasswordevAr' by the actual password you want for the zabbix database user

postgres=# create user zabbix with password 'ohmybestpasswordevAr';


postgres=# create database zabbix with owner zabbix;
postgres=# -- next line should log you as just created zabbix user ;
postgres=# \c zabbix zabbix
You are now connected to database "zabbix" as user "zabbix".
zabbix=>

and import the schemes (still logged in as zabbix user):

zabbix=> \i /usr/share/doc/packages/zabbix-server/postgresql/schema.sql
zabbix=> \i /usr/share/doc/packages/zabbix-server/postgresql/images.sql
zabbix=> \i /usr/share/doc/packages/zabbix-server/postgresql/data.sql
zabbix=> \q

Configure PostgreSQL to start up during server boot:

insserv postgresql

or using systemd syntax (only on openSUSE >= 12.1)

systemctl enable postgresql.service

Zabbix Server
Edit /etc/zabbix/zabbix-server.conf to set up zabbix database users' password
Start the zabbix-server process

rczabbix-server start

or using systemd syntax (only on openSUSE >= 12.1)

systemctl start zabbix-server.service

Configure zabbix-server to start up during server boot:

insserv zabbix-server

or using systemd syntax (only on openSUSE >= 12.1)

systemctl enable zabbix-server.service

Front-end Install
Install the zabbix-phpfrontend package:

zypper install zabbix-phpfrontend

Also install apache webserver with PHP5 support and a few additional PHP5 libraries required by Zabbix front-end:

zypper install apache2 apache2-mod_php5 php5-gettext php5-mbstring php5-gd

Edit /etc/apache2/conf.d/zabbix.conf and add (change the date.timezone to your own timezone)

php_value max_execution_time 300


php_value memory_limit 128M
php_value post_max_size 16M
php_value upload_max_filesize 2M

https://www.zabbix.org/wiki/Install_on_openSUSE_/_SLES 3/5
19/9/2017 Install on openSUSE / SLES - Zabbix.org
php_value max_input_time 300
php_value date.timezone Europe/Brussels

Enable the Apache PHP5 module:

a2enmod php5

Enable the Zabbix front-end website by setting the 'ZABBIX' flag in Apache:

a2enflag ZABBIX

Edit the front-end configuration file /usr/share/zabbix/conf/zabbix.conf.php to reflect you setup (database type, host, user, password and
zabbix server host) or follow steps of automated setup
Make sure apache is started on server startup:

insserv apache2

Start apache server manually for now

rcapache2 start

or systemd syntax (only on openSUSE >= 12.1)

systemctl enable apache2.service


systemctl start apache2.service

Now the front-end should be available at http://yourservername/zabbix

Java Gateway Install


The Java gateway service is used for JMX monitoring of servers like JBoss, Tomcat, Weblogic or Websphere.

The java gateway is contained in a separate package zabbix-java-gateway

to install it run:

zypper install zabbix-java-gateway

Specify the address of the gateway in the zabbix server config (/etc/zabbix/zabbix-server.conf or zabbix-proxy.conf):

JavaGateway=10.150.164.214
StartJavaPollers=5

Make it start during server startup

insserv zabbix-java-gateway
rczabbix-java-gateway start

or using systemd (only on openSUSE >= 12.1)

systemctl enable zabbix-java-gateway


systemctl start zabbix-java-gateway

Agent Install
Linux

https://www.zabbix.org/wiki/Install_on_openSUSE_/_SLES 4/5
19/9/2017 Install on openSUSE / SLES - Zabbix.org
For openSUSE/SLES Install the zabbix-agent from: http://software.opensuse.org/download/package?
project=server:monitoring&package=zabbix-agent

insserv zabbix-agent

For CentOS/RHEL/SL, see: https://www.zabbix.org/wiki/InstallOnCentOS_RHEL#Agent%20Install


For Ubuntu/Debian,
Install the correct repository (see:
https://www.zabbix.com/documentation/2.0/manual/installation/install_from_packages#installing_repository_configuration_package1
)
Install the agent package

apt-get install zabbix-agent

Edit /etc/zabbix/zabbix_agentd.conf and point the agent to the zabbix server by changing the Server and ServerActive settings.
Start the agent (service zabbix-agent start or for SUSE: rczabbix-agentd start)

Windows
See https://www.zabbix.com/documentation/2.0/manual/appendix/install/windows_agent

Retrieved from "https://www.zabbix.org/mw/index.php?title=Install_on_openSUSE_/_SLES&oldid=10782"

Categories: Installation SLES

This page was last modified on 11 August 2016, at 19:58.

https://www.zabbix.org/wiki/Install_on_openSUSE_/_SLES 5/5

You might also like