Introduction
1. SNMP and MIBs - Installation and Configuration
To implement the monitoring system, the first step is to install SNMP and MIBs in all the systems to be monitored.
Below is described each system used by each resource in a common island setup:
Resource | O.S. | Sugested hostname |
---|---|---|
Dom0 | Debian 7 | vms |
LDAP | Debian 7 | ldap |
Flowvisor | Debian 7 | flowvisor |
OCF | Debian 8 | ocf |
OMF | Ubuntu 12.04 | omf |
NetFPGA1 | CentOS 5 | netfpga1 |
NetFPGA2 | CentOS 5 | netfpga2 |
NetFPGA3 | CentOS 5 | netfpga3 |
VPN Client | Debian 7 | vpn |
If you have a different setup you have to change this in order to correctly describe your own environment
Download and install the SNMP and MIBs for each one of the systems:
(For Debian systems, is necessary to add the non-free repositories before installation)
nano /etc/apt/sources.list #or vim /etc/apt/sources.list
... deb .... main non-free deb-src .... main non-free ...
apt-get install snmpd -y apt-get install snmp-mibs-downloader -y
yum install net-snmp -y yum install net-snmp-utils -y
cd /etc/snmp cp snmpd.conf snmpd.conf.ori cat /dev/null > snmpd.conf
And apply the following default configuration:
rocommunity FIBRE-BR syslocation [Institution, City, UF] syscontact [E-mail] agentaddress [SERVER_IP]:161
- rocommunity- This field must be filled with FIBRE's default community, which is FIBRE-BR.
- syslocation - This field should be filled with the server's location. Like the instituion, the state and the city where the infrastructure is located.
- syscontact - This field should be filled with the sysadmin's e-mail.
- agentaddress - This field should be completed with the ip address of the FIBRE control network inthe system (10.x.0.y), and port 161.
Example for RNP Dom0:
rocommunity FIBRE-BR syslocation RNP, Brasília, DF syscontact fibre-rnp@rt.rnp.br agentaddress 10.128.0.30:161
service snmpd restart
2. Monitoring Agents - Installation and Configuration
To deploy an advanced monitoring of some essencial island resources, a monitoring agent must be installed on them.
Additionally, the current version of the Pronto SW firmware don't support the monitoring agent.
In short, the agent don't need to be installed on the DNS, Perfsonar, and on the Pronto SW.
For each other system, download and install the agent as follows:
wget http://repo.zabbix.com/zabbix/3.0/debian/pool/main/z/zabbix-release/zabbix-release_3.0-1+wheezy_all.deb dpkg -i zabbix-release_3.0-1+wheezy_all.deb apt-get update apt-get install -y zabbix-agent
wget http://repo.zabbix.com/zabbix/3.0/debian/pool/main/z/zabbix-release/zabbix-release_3.0-1+jessie_all.deb dpkg -i zabbix-release_3.0-1+jessie_all.deb apt-get update apt-get install -y zabbix-agent
wget http://repo.zabbix.com/zabbix/2.2/ubuntu/pool/main/z/zabbix-release/zabbix-release_2.2-1+precise_all.deb sudo dpkg -i zabbix-release_2.2-1+precise_all.deb sudo apt-get update sudo apt-get install zabbix-agent
wget http://repo.zabbix.com/zabbix/3.0/rhel/5/i386/zabbix-agent-3.0.4-1.el5.i386.rpm rpm -ivh zabbix-agent-3.0.4-1.el5.i386.rpm
Edit the agent configuration file for each resource system:
vim /etc/zabbix/zabbix_agentd.conf # or: nano /etc/zabbix/zabbix_agentd.conf
And change the according to your environment. The Proxy IP address follow the pattern: 10.[id].0.160:
... Server=10.128.0.150,10.128.0.151,[VMServer IP address],[Proxy IP address] ... ServerActive=10.128.0.150,10.128.0.151,[VMServer IP address],[Proxy IP address] ... Hostname=zabbix.noc.fibre.org.br ...
Example:
Server=10.128.0.150,10.128.0.151,10.136.0.30,10.136.0.160
ServerActive=10.128.0.150,10.128.0.151,10.136.0.30,10.136.0.160
Hostname=zabbix.noc.fibre.org.br
Save the changes and exit the editor;
Delete a config file that will be substituted:
rm -f /etc/zabbix/zabbix_agentd.d/userparameter_mysql.conf
Download the "etc-zabbix.tar.gz " file from the ftp://repo.fibre.org.br/Monitoring/ to the /etc/zabbix/ folder on the agent host and extract it:
cd /etc/zabbix/ wget ftp://repo.fibre.org.br/Monitoring/etc-zabbix.tar.gz tar -zxvf etc-zabbix.tar.gz
For the OCF VM only, is necessary to create a read-only user in the MySQL database:
mysql -u root -p [mysql pasword] create database zabbix character set utf8 collate utf8_bin; grant SELECT on zabbix.* to zabbix@localhost identified by 'zabbixpw'; SELECT User,Host FROM mysql.user; quit;
Finally, and for all nodes, restart the monitoring agent service and enable startup on system initialization:
/etc/init.d/zabbix-agent restart # or: service zabbix-agent restart # For CentOS systems: chkconfig zabbix-agent on # For Debian systems: systemctl enable zabbix-agent systemctl start zabbix-agent
3. Local Proxy - Installation and Configuration
For this installation, use the template zproxy-template.tar.gz available at this address: ftp://repo.fibre.org.br/
Download it where Xen creates its VMs.
Where does the hypervisor creates its VMs?
To verify where the hypervisor is creating its VMs, verify this file: /etc/xen-tools/xen-tools.conf.
The value of the variable dir is the destiny where the VMs are being created.
cd (directory)/domains wget ftp://repo.fibre.org.br/ServiceTemplates/zproxy-template170124.tar.gz
Due to the Island's firewall constraints, it might be necessary to use the internal address to download. In case of need use this address:
And extract it´s contents:
tar zxf zproxy-template170124.tar.gz
And access the directory.
cd zproxy.template
Changing directory name
It might be interesting to change the directory name for this pattern: zprozy.institution.fibre.org.br
Example: zproxy.cpqd.fibre.org.br
After that it's necessary to rename and edit and rename this file: zproxy.template
vim zproxy.template.fibre.org.br.cfg
It's necessary to edit the following lines:
The variable disk refers where the VM's disk is located. Below is an example of configuration:
disk = [ 'file:/data/vm_storage/domains/zproxy.rnp.fibre.org.br/disk.img,xvda2,w', 'file:/data/vm_storage/domains/zproxy.rnp.fibre.org.br/swap.img,xvda1,w', ]
Also it's necessary to configure the network, the vif variable is responsible for this task.
Control Bridge name
Pay attention to the name of your control bridge, also it's necessary to change the mac address.
Example of configuration:
vif = [ 'ip=10.136.0.160,mac=00:00:0a:00:00:33,bridge=br_control' ]
It's a good practice to use this pattern for MAC address generation:
MAC address:
00:00:XX:00:00.YY
Where XX stands for the Island's ID and YY stands for the service IP, both in hexadecimal form
The next step of editing the file it's to change the name of the VM.
Edit this line:
name = 'zproxy.template.fibre.org.br'
This edition consists in just replace template to the name of the institution.
Example:
name = 'zproxy.rnp.fibre.org.br'
After editing, move and rename it to /etc/xen:
mv zproxy.template.fibre.org.br.cfg /etc/xen/zproxy.rnp.fibre.org.br.cfg
And create a symbolic link at the directory called auto:
cd /etc/xen/auto ln -s ../zproxy.rnp.fibre.org.br.cfg
The next step is to access the console of the VM:
xm create -c (name of the vm)
To start using the VM use the following credentials:
VM credentials
Login: root
Password: zproxy
4. Related Documents
Below are the documents related to the monitoring solution choosed for the FIBRE NOC Monitoring:
FIBRE 2016-05 - Avaliação Ferramentas de Gerência v1.0.pdf
FIBRE 2016-06 - Novo Monitoramento v1.0.pdf
FIBRE 2017-02 - FIBRE Monitoramento v1.0.pdf