Difference between revisions of "Zabbix server setup - requirements"

 
(28 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
[[Category:Linux]]
 
[[Category:Linux]]
  
 +
This page describe the server requirements to install Zabbix monitoring.
  
=System installation=
+
You can skip that part if you already have a running server.
  
==Requirements==
 
  
You should already have:
+
 
 +
=Requirements=
 +
 
 +
 
 +
You '''network''' must contain | provide:
 
* [[DNS server]]
 
* [[DNS server]]
 
* [[DHCP server]]
 
* [[DHCP server]]
Line 12: Line 16:
  
  
==O.S installation==
 
  
On dedicated hardware you need to install '''Ubuntu Server 14.04 LTS''' using an USB key.
+
The '''server''' must have:
 +
* [[Apache 2]] web server
 +
* [[MySQL server]]
 +
* [[Firewall]] with allowance for INPUT TCP 10051
 +
* [[SNMP client]]
  
  
  
  
=Basic setup=
+
=O.S installation=
 +
 
 +
On dedicated hardware you need to install '''Ubuntu Server 14.04 LTS''' using an USB key.
  
  
==Update sources.list and install key packages==
 
  
Your client need to have some key packages in order to work. Without these package even the NetBoot will fail !!
+
=System configuration=
  
  
First of all: edit your sources.list
+
==Update sources.list and install key packages==
 +
 
 +
Edit your sources.list
  
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
apt-get install vim nano
+
apt-get install vim
 
vim /etc/apt/sources.list
 
vim /etc/apt/sources.list
 
</syntaxhighlight>
 
</syntaxhighlight>
Line 113: Line 123:
 
vim /root/.bashrc
 
vim /root/.bashrc
 
</syntaxhighlight>
 
</syntaxhighlight>
 
 
 
==Firewall script==
 
 
Download, adjust and copy the following FW script to your clients: http://www.daxiongmao.eu/wiki_upload_files/firewall/firewall-nfs-client.sh
 
 
See [[Firewall]] to get more details.
 
 
  
  
Line 150: Line 151:
 
iface em1 inet dhcp
 
iface em1 inet dhcp
 
</syntaxhighlight>
 
</syntaxhighlight>
 
 
Even though you're using a NetBoot configuration you need to tell the client to use DHCP and retrieve its network settings (DNS, IP, GW, ...) dynamically. That's why you have to enable your ethernet interface.
 
 
 
 
 
 
=Zabbix server installation=
 
 
 
 
==Add Zabbix repository==
 
 
 
Source: https://www.zabbix.com/documentation/2.2/manual/installation/install_from_packages
 
 
 
Installation:
 
 
<syntaxhighlight lang="bash">
 
wget http://repo.zabbix.com/zabbix/2.2/ubuntu/pool/main/z/zabbix-release/zabbix-release_2.2-1+trusty_all.deb
 
dpkg -i zabbix-release_2.2-1+trusty_all.deb
 
apt-get update
 
</syntaxhighlight>
 
 
 
 
 
 
 
 
=References=
 
 
Zabbix official documentation (very good): https://www.zabbix.com/documentation/
 
 
 
Digitial Ocean community - Zabbix tutorial: https://www.digitalocean.com/community/tutorials/how-to-install-and-configure-openldap-and-phpldapadmin-on-an-ubuntu-14-04-server
 
 
 
Tecadmin tutorial: http://tecadmin.net/install-zabbix-on-ubuntu/#
 

Latest revision as of 15:17, 27 October 2014


This page describe the server requirements to install Zabbix monitoring.

You can skip that part if you already have a running server.


Requirements

You network must contain | provide:


The server must have:



O.S installation

On dedicated hardware you need to install Ubuntu Server 14.04 LTS using an USB key.


System configuration

Update sources.list and install key packages

Edit your sources.list

apt-get install vim
vim /etc/apt/sources.list


Put the following:

### Custom repositories list
#
# May 2014 - Guillaume Diaz
# This is an ajdustement of the default "debootstrap" sources.list
# This is required to provided update, security and advanced tools to all our clients
#

#########################
# Ubuntu 14.04 LTS [Trusty]
#########################
# Official repositories
deb http://se.archive.ubuntu.com/ubuntu/ trusty main restricted universe multiverse
deb http://se.archive.ubuntu.com/ubuntu/ trusty-updates main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu trusty-security main restricted universe multiverse

# Official updates 
deb http://se.archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse

# Canonical partners
#deb http://archive.canonical.com/ubuntu trusty partner

# Community partners
#deb http://extras.ubuntu.com/ubuntu trusty main


Update your package list:

apt-get update && apt-get upgrade


Linux utilities

Now, you can install the basic programs:

# NFS is a bit low, and if you're using many client it might result in time faults. 
# You must install NTP to overcome this !!
apt-get install ntp ntpdate

# Basic set of utilities
apt-get install unzip zip htop python3 sysv-rc-conf mc

# Network tools
apt-get install curl

# Advanced APT manager (require to add repository from command line)
apt-get install software-properties-common python-software-properties

# SSH server
apt-get install openssh-server openssh-client


Adjust bash and vim configuration

Edit your VIM configuration:

vim /etc/vim/vimrc

Enable dark background + set nu + set ruler


Edit your bash configuration files to adjust the alias and enable auto-completion:

vim /etc/bash.bashrc
vim /home/<username>/.bashrc
vim /root/.bashrc


Setup network interfaces

Even though you're using the NetBoot process you still have to register some interfaces! More important, the NetBoot disable the loopback "lo" - so you should better add that one back!

# Adjust "xxxx" by your distribution name
vim /etc/network/interfaces


Add:

auto lo
iface lo inet loopback

# Ethernet default interface
auto eth0
iface eth0 inet dhcp

# Intel NUC ethernet interface is named em1
auto em1
iface em1 inet dhcp