O documento discute o uso do SNMP (Simple Network Management Protocol) com Zabbix e Net-SNMP. Ele explica como configurar o Net-SNMP para ler dados via SNMP, visualizar dados de diferentes formas e usar máscaras de filtro. Também mostra templates SNMP comuns no Zabbix e dicas para solucionar problemas de leitura de dados.
The wireless network monitoring data are abundant, as it seems relevant store information from devices and users connected, especially in an multicampus environment like Unesp. In this sense, the database tends to increase rapidly the number of records, being necessary to optimize the periodic cleaning routine of Zabbix data. Here are our way of improving the functioning of the "housekeeping" native application. Also will demonstrate the massive use of the data type "Zabbix Trapper" for flexible the list of informations of Wi-Fi infrastructure and techniques varied use of "low level discovery" for monitoring of wireless access points.
The aim of the lecture is the demonstration of the new Low Level Discovery Resources that emerged in Zabbix 3.0, as well as presentation, operation and demonstration LLD settings of Windows and ODBC Services.
The wireless network monitoring data are abundant, as it seems relevant store information from devices and users connected, especially in an multicampus environment like Unesp. In this sense, the database tends to increase rapidly the number of records, being necessary to optimize the periodic cleaning routine of Zabbix data. Here are our way of improving the functioning of the "housekeeping" native application. Also will demonstrate the massive use of the data type "Zabbix Trapper" for flexible the list of informations of Wi-Fi infrastructure and techniques varied use of "low level discovery" for monitoring of wireless access points.
The aim of the lecture is the demonstration of the new Low Level Discovery Resources that emerged in Zabbix 3.0, as well as presentation, operation and demonstration LLD settings of Windows and ODBC Services.
Slides da palestra apresentada no QCon 2019 sobre Kubernetes e um deepdive em seus componentes (apiserver, scheduler, ingress, etc) e os objetos do cluster
Apresentação de TCC. Conceitos de Escalabilidade Vertical/Horizontal, Clusterização e Balanço de Carga. Testes de desempenho na Aplicação, desenvolvida com Ruby On Rails, Ajax, MySQL.
Coisas que aprendi e quero passar adiante - RubyConf Brasil 2010lucashungaro
Palestra apresentada na RubyConf Brasil 2010 mostrando dicas de bibliotecas úteis para aplicações web escritas em Rails e maneiras para conseguir código flexível, fácil de testar e modificar utilizando SOLID, defensive programming e outras técnicas.
Gerenciamento de Servidores Linux utilizando SNMPAndré Déo
Material de aula da disciplina de Gerência de Redes.
Esse material foi originalmente criado pelo Conrado, e depois alterado por mim, hoje chamamos de nossa apresentação de SNMP.
Material Introdutório sobre o Gerenciamento de Servidores Linux utilizando o protocolo SNMP.
Slides da palestra apresentada no QCon 2019 sobre Kubernetes e um deepdive em seus componentes (apiserver, scheduler, ingress, etc) e os objetos do cluster
Apresentação de TCC. Conceitos de Escalabilidade Vertical/Horizontal, Clusterização e Balanço de Carga. Testes de desempenho na Aplicação, desenvolvida com Ruby On Rails, Ajax, MySQL.
Coisas que aprendi e quero passar adiante - RubyConf Brasil 2010lucashungaro
Palestra apresentada na RubyConf Brasil 2010 mostrando dicas de bibliotecas úteis para aplicações web escritas em Rails e maneiras para conseguir código flexível, fácil de testar e modificar utilizando SOLID, defensive programming e outras técnicas.
Gerenciamento de Servidores Linux utilizando SNMPAndré Déo
Material de aula da disciplina de Gerência de Redes.
Esse material foi originalmente criado pelo Conrado, e depois alterado por mim, hoje chamamos de nossa apresentação de SNMP.
Material Introdutório sobre o Gerenciamento de Servidores Linux utilizando o protocolo SNMP.
Zabbix Conference LatAm 2016 - Andre Deo - Zabbix Brazil CommunityZabbix
In 2008 Brazil hadn't any community about Zabbix, and the software was not known to most people. What changed in 8 years? How a community initiated by one single man (like in Japan) made the difference? Currently this community has more than 3.000 members, many lectures at local events, articles in magazines, books, many blogs and member involved in building additional functions for Zabbix and translation of official documentation!
Zabbix Conference LatAm 2016 - Rodrigo Mohr - Challenges on Large Env with Or...Zabbix
Scalability on a large environment can be a challenge on many different aspects involving customization of monitors, performance and reporting. The goal of this presentation is to share the experience we had at Dell, monitoring a big number of servers in an environment with constant changes, lots of custom monitors and new servers configured every week. We will present, from our 3 years of experience with Zabbix and Oracle, which positive/negative aspects we have taken from the configuration parameters we used, involving strong use of User Macros, optimization of Database Queries, Table Partitioning and Automation.
The Lojas Renner has always had a close proximity to the Open Source movement in Brazil. Still in the 90s, all the company's POS solutions have been migrated to Linux and in early 2000, migration started in all the company's systems, including the main components of critical infrastructure. Since then, much has changed. The world scene Open Source has become a worldwide standard for all products and companies, making its adoption not only an innovation but a necessity. Understand how since 2008 Zabbix helps us in monitoring the entire IT infrastructure, remote units and our business processes.
A Unirede atua desde 2008 com projetos de todos os portes envolvendo o Zabbix. Desde então surgem necessidades onde devemos garantir a interação do Zabbix com as mais variadas formas, métodos e ferramentas de mensageria para para notificar os eventos (E-mail, SMS, criação de tickets/chamados,arquivos de log, WhatsApp, VOIP, Telegram, etc). Nessa palestra irei tentar exemplificar como podemos interegir com o Telegram, recebendo e enviando mensagens para o Zabbix e dessa forma tornar mais dinâmica a comunicação de usuários remotos com seus servidores e equipamentos no datacenter.
Zabbix Conference LatAm 2016 - Filipe Paternot - Zbx@Globo Automation+Integra...Zabbix
Zabbix API offers us a lot of power and possibilities. We will talk about automation and integrations at scale, at Globo.com. Automating gives us power to clone instances of Zabbix, perform batch operations, manage MANY networks for discovery and more. We will present our layer of abstraction to API, democratizing API access, offering a nice UI and standards for every new service monitored and few cached responses. Also, we will show how we have integrated with CloudStack, to deliver automated private cloud monitoring into Zabbix.
Zabbix Conference LatAm 2016 - Douglas Esteves - Zabbix at UNICAMPZabbix
Present the Zabbix use case in the Computer Center of UNICAMP, excellent option for monitoring Datacenter Environments and the University Environment. Presentation of the use of the tool at UNICAMP with simple monitoring and case of IT Service Monitoring to measure Server Availability and Database.
Ryan Armstrong - Monitoring More Than 6000 Devices in Zabbix | ZabConf2016Zabbix
Ryan will describe a Skunkworks project executed by Kinetic IT at the Department of Education to deliver an autonomous infrastructure monitoring solution for over 6000 devices distributed across WA. The team were given opportunity to experiment with DevOps practices such as Scrum product development, Infrastructure As Code and Continuous Integration to determine where the value lay and which practices should be adopted at greater scale.
Rafael Martinez Guerrero - Zabbix at the University of Oslo | ZabConf2016Zabbix
A case study showing the problems we have resolved with Zabbix and the challenges we had when we implemented Zabbix as the main monitoring tool at the University of Oslo. The number of challenges is not low in an organization as heterogenous as ours, with many thousands of servers and clients, all kinds of devices connected to our infrastructure, different operating systems, multiple locations and hundreds of IT staff. Full automation and delegation of privileges are the key words in the work we have done during the past year and a half.
Wolfgang Alper - Zabbix Meets OPS Control / Rundeck | ZabConf2016Zabbix
Zabbix is an excellent tool to do network monitoring and to alert if something bad happens. But Zabbix can do more. An underestimated feature of Zabbix is its ability to perform actions in addition to simple notifications. However, this requires to precisly setup those actions within zabbix, which is not always an easy task and might duplicate existing work. So what if Zabbix actually worked in concert with an external taskrunner / jobscheduler that is build to do exactly this: run a task or action against a host and report its outcome? Zabbix would perform the same well defined steps that an ops member would perform in case of certain failures using this kind of tool. A well know example of this kind of software is "Rundeck" which is licensed under the Apache License Version 2.0.
Wolfgang Alper - Zabbix Meets OPS Control / Rundeck | ZabConf2016Zabbix
Zabbix is an excellent tool to do network monitoring and to alert if something bad happens. But Zabbix can do more. An underestimated feature of Zabbix is its ability to perform actions in addition to simple notifications. However, this requires to precisly setup those actions within zabbix, which is not always an easy task and might duplicate existing work. So what if Zabbix actually worked in concert with an external taskrunner / jobscheduler that is build to do exactly this: run a task or action against a host and report its outcome? Zabbix would perform the same well defined steps that an ops member would perform in case of certain failures using this kind of tool. A well know example of this kind of software is "Rundeck" which is licensed under the Apache License Version 2.0.
Sumit Goel - Monitoring Cloud Applications Using Zabbix | ZabConf2016Zabbix
With global shift towards flexibility of cloud there are different demands on monitoring availability and performance of applications provided in the cloud. There are obvious limitations in accessing components of app hosted by third party run outside of internal environment. Same time there are opportunities of using vendor API and status page. In Salesforce, one of the most innovative company in the world by Forbes and one of the biggest cloud service provider, we understand the need of customer to be able to see in real time availability and performance of cloud application. In the following presentation we're going to list and describe multiple ways of monitoring cloud apps. Some of the methods are: building in web monitoring using Curl, web browser automation tools like Selenium, external scripts (reading vendor status dashboard) and API calls to the app.
Rihards Olups - Zabbix at Nokia - Case StudyZabbix
We will explore a fairly complicated Zabbix environment at one division in Nokia. Having several different Zabbix versions in use and a lot of custom products monitored, it is a place one can get lost in easily. We'll discuss JMX monitoring, approaches to keep notification configuration simple and notifications useful, different usecases for the Zabbix API and a lot of other topics. The importance of the SSL compliance will be covered along with some of the many ways custom solutions are monitored.
Raymond Kuiper - Zen and The Art of Zabbix Template Design | ZabConf2016Zabbix
Zabbix monitoring solution can help bring balance to your organisation's IT landscape. However, the success greatly depends on the templates you use to setup your monitoring system. As any Zabbix veteran will tell you, the default templates don't really suffice for any setup other than a proof-of-concept. How then do you set about creating your own templates? Following practical examples, we'll discuss some of the design decisions that need to be made to achieve template perfection.
Dimitri Bellini and Pietro Antonacci - Manage Zabbix Proxies in Remote Networ...Zabbix
Monitoring multiple server farms spread all around the world is not an easy task, many small problems have to be addressed, but using Zabbix it is all a breeze.
We will talk about our experience on setup of Zabbix proxies in very remote networks, problems we encountered and how we worked on fixing them.
Erik Skytthe - Monitoring Mesos, Docker, Containers with Zabbix | ZabConf2016Zabbix
At DBC we are running docker and other container types in a mesos/marathon cluster environment. I will demonstrate how we collect statistics, logs etc. and monitor this environment, showing configuration examples, data flows and templates.
Some of the covered topics:
- Mesos master and agents
- Marathon Framework
- Docker engine
- Containers
- Zookeeper
- Elasticserach/ELK
Mikhail Serkov - Zabbix for HPC Cluster Support | ZabConf2016Zabbix
For the last two years I've been working in Cambridge (US) in Novartis Institute for Biomedical Research (NIBR) on a project related to a support of HPC cluster infrastructure and users. We're using Zabbix for HPC cluster monitoring (more than 1000 nodes, 10000+ cores, GPU cores, etc). In this presentation we will cover interesting use cases of Zabbix for HPC cluster, as it's not a regular infrastructure monitoring. We will talk about some challenges we have in HPC monitoring, how Zabbix helps us to work with scientists as well as present some solutions, which might be interesting for Zabbix community.
Lukáš Malý - Log management ELISA controlled by Zabbix | ZabConf2016Zabbix
Datasys ELISA log management is robust, powerful, yet inexpensive solution for collection, correlation and analysis of logs. Core system consists of the Elasticsearch “noSQL“ database and the web user interface Kibana, which provides high comfort for analysis of detected security incidents and relevant logs. It is common that the database ElasticSearch is distributed to multiple servers to achieve load balancing and high availability of indexed data. ELISA heavily utilizes ZABBIX for user authentication and role based access control, notifications and self-monitoring. Elasticsearch Indices can be managed right in ZABBIX Frontend. ZABBIX "trapper" items and monitoring templates are used to centrally manage configuration of distributed environment of NXlog agents. Agents are capable to securely auto-register as ZABBIX "hosts".
Konstantin Yakovlev - Event Analysis Toolset | ZabConf2016Zabbix
During outages on 10k+ hosts environment, NOC and Operations teams may face hundreds of alerts in order to perform root cause analysis, remediation or escalation, meanwhile logging resolution progress to Incident Management system for audit purposes.
This presentation will describe RingCentral approach to Incident and Problem Management in large Zabbix monitored cloud.
Co-authors of the presentation: Dmitry Shchemelinin, Ph.D., Sr. Director of Operations, RingCentral, USA.
3. Quem sou eu
André (Luis Boni) Déo
Fundador da Comunidade Zabbix Brasil
Co-Autor do Livro de A a Zabbix
Administrador deRedes, Professor Universitário, Membro da Comunidade
OpenSource.
@deoandre andredeo@gmail.com
http://andredeo.blogspot.com
4. Por que o Zabbix
não lê meus dados?
Início
Você
consegue
ler os
dados via
snmpget?
Revise a
configuração
do
equipamento
Revise a
configuração
do item no
Zabbix
Fim
NãoSim
5. Estrutura do Net-SNMP
/etc/snmpd.conf
Arquivo de configuração principal do Net-Snmp:
Se você especificar um objeto nesse arquivo, como por exemplo,
syslocation, syscontact, sysdescr, etc. Esse objeto se tornará ro (read only).
Man snmpd.conf
/etc/snmp.conf
Arquivo de configurações do ambiente:
Definições de acesso do cliente;
Definições de diretórios padrões;
Definições de mibs;
Definições de saídas padrões de comandos.
Man snmp.conf
6. Estrutura do Net-SNMP
~/.snmp/snmp.conf
Arquivos de configurações do ambiente:
Definições de acesso do cliente;
Definições de saídas padrões de comandos.
Man snmp.conf
/var/lib/net-snmp/snmpd.conf
No momento em que o serviço é iniciado, carrega a configuração do net-
snmpd.conf e as mibs disponíveis no sistema:
Usuários SNMP V3 são armazenados nesse arquivo de forma
criptografada;
Número de vezes que o serviço foi (re)inicializado;
Serial para controlar alterações no arquivo.
9. # snmpget -v2c -c public localhost sysContact.0
SNMPv2-MIB::sysContact.0 = STRING: root@localhost
# snmpget -On -v2c -c public localhost sysContact.0
.1.3.6.1.2.1.1.4.0 = STRING: root@localhost
Eu preciso ter a MIB
do equipamento para ler os dados!
10. # snmpget -v2c -c public localhost sysContact.0
MIB search path:
/root/.snmp/mibs:/usr/share/snmp/mibs
Cannot find module (SNMPv2-MIB): At line 12 in
/usr/share/snmp/mibs/IF-MIB.txt
.
.
.
sysContact.0: Unknown Object Identifier (Sub-id not
found: (top) -> sysContact)
Eu preciso ter a MIB
do equipamento para ler os dados!
11. # snmpget -v2c -c public localhost
.1.3.6.1.2.1.1.4.0
MIB search path:
/root/.snmp/mibs:/usr/share/snmp/mibs
Cannot find module (SNMPv2-MIB): At line 12 in
/usr/share/snmp/mibs/IF-MIB.txt
.
.
.
SNMPv2-SMI::mib-2.1.4.0 = STRING: "root@localhost"
Eu preciso ter a MIB
do equipamento para ler os dados!
12. Mensagem ao final do
snmpwalk. O que significa?
# snmpwalk -v2c -c public localhost
DISMAN-EVENT-MIB::sysUpTimeInstance = Timeticks:
(159) 0:00:01.59
IF-MIB::ifDescr.1 = STRING: lo
IF-MIB::ifDescr.2 = STRING: enp0s3
IF-MIB::ifDescr.3 = STRING: enp0s8
IF-MIB::ifAdminStatus.1 = INTEGER: up(1)
IF-MIB::ifAdminStatus.2 = INTEGER: up(1)
IF-MIB::ifAdminStatus.3 = INTEGER: up(1)
IF-MIB::ifOperStatus.1 = INTEGER: up(1)
IF-MIB::ifOperStatus.2 = INTEGER: up(1)
IF-MIB::ifOperStatus.3 = INTEGER: up(1)
IF-MIB::ifOperStatus.3 = No more variables left in
this MIB View (It is past the end of the MIB tree)
13. Existe algum tipo de filtro (Included/Exclued ou Máscara)bloqueando parte
das informações
Mensagem ao final do
snmpwalk. O que significa?
14. # snmpget -v 3 -u user1 -n "" -x DES -l authNoPriv -
a MD5 -A senhateste localhost sysContact.0
SNMPv2-MIB::sysContact.0 = STRING: root@localhost
Utilizo apenas SNMP v3
na minha rede, estou seguro!
28. Comandos SNMP Uteis
snmptranslate
# snmptranslate -On -Ib -Td sysUptime
.1.3.6.1.2.1.1.3
sysUpTime OBJECT-TYPE
-- FROM SNMPv2-MIB
SYNTAX TimeTicks
MAX-ACCESS read-only
STATUS current
DESCRIPTION "The time (in hundredths of a second)
since the
network management portion of the system was
last
re-initialized."
::= { iso(1) org(3) dod(6) internet(1) mgmt(2) mib-2(1)
system(1) 3 }
-On -Ib-Td: Exibe o OIDnumérico de um objetoe sua descrição
30. -Td: Exibea descrição deum OID
Comandos SNMP Uteis
snmptranslate
# snmptranslate -Td .1.3.6.1.2.1.1.3
SNMPv2-MIB::sysUpTime
sysUpTime OBJECT-TYPE
-- FROM SNMPv2-MIB
SYNTAX TimeTicks
MAX-ACCESS read-only
STATUS current
DESCRIPTION "The time (in hundredths of a second)
since the
network management portion of the system was
last
re-initialized."
::= { iso(1) org(3) dod(6) internet(1) mgmt(2) mib-2(1)
system(1) 3 }
34. Configurações Uteis
~./.snmp/snmp.conf
# cat snmp.conf
defversion 3
defsecurityname initial
defsecuritylevel authPriv
defauthtype MD5
defauthpassphrase setup_passphrase
defprivtype DES
defprivpassphrase setup_passkey
Permite definir todos os parâmetros de autenticação.
35. # snmpget localhost sysContact.0
# snmpget -v 3 -u initial -n "" -x DES -X
setup_passkey -l authPriv -a MD5 -A setup_passphrase
localhost sysContact.0
Sintaxe dos comandos sem o snmp.conf:
Sintaxe dos comandos com o snmp.conf:
Configurações Uteis
~/.snmp/snmp.conf
37. Configurações Uteis
extend
# cat /etc/snmp
# /etc/snmp/snmpd.conf v3 devidamente configurado -
Monitoramento utilizando um comando customizado com OID
personalizada
.
.
#extend OID Nome comando
Parametros
extend .1.1.1.1.1 Zabbix /bin/bash
/etc/snmp/zabbix.sh
extend – Permite executar um comando com passagem de parâmetros, assim
como o exec, porém me permite especificar em qual OID as informações serão
armazenadas.
39. Configurações Uteis
Máscaras
Máscaras devem ser informadas no formato Hexadecimal;
O caractereseparador da mascara pode ser “.” ou “:”;
A cada bit na máscara indica seos OIDs correspondentes devem coincidir(1)
ou não (0).
40. Configurações Uteis
Máscaras
Um exemplo visual:
.1.3.6.1.2.1.2.2.1.1.1 == interfaces.ifTable.ifEntry.ifIndex.1
1 1 1 1 1 1 1 1 1 0 1 (00000) == (ff.a0)
o índice (the index)
a coluna (the column)
ifEntry
ifTable
42. Visualizando os dados
de maneira variada
# snmpget -Of -v 3 -u initial -n "" -x DES -l
authNoPriv -a MD5 -A setup_passphrase localhost
ifDescr.2
.iso.org.dod.internet.mgmt.mib-
2.interfaces.ifTable.ifEntry.ifDescr.2 = STRING:
enp0s3
Exibição Padrão
-Of: Exibindoo OID CompletoNonimal
# snmpget -v 3 -u initial -n "" -x DES -l authNoPriv
-a MD5 -A setup_passphrase localhost ifDescr.2
IF-MIB::ifDescr.2 = STRING: enp0s3
43. Visualizando os dados
de maneira variada
# snmpget -Oq -v 3 -u initial -n "" -x DES -l
authNoPriv -a MD5 -A setup_passphrase localhost
ifDescr.2
IF-MIB::ifDescr.2 enp0s3
-On: Exibindo o OID Completo Numérico
-Oq: Exibeo OID abreviado;Apenaso finaldoOID
# snmpget -On -v 3 -u initial -n "" -x DES -l
authNoPriv -a MD5 -A setup_passphrase localhost
ifDescr.2
.1.3.6.1.2.1.2.2.1.2.2 = STRING: enp0s3
44. Visualizando os dados
de maneira variada
-Oqn: Exibeo OID abreviado;Apenaso final do OID na forma numérica
# snmpget -Oqn -v 3 -u initial -n "" -x DES -l
authNoPriv -a MD5 -A setup_passphrase localhost
ifDescr.2
.1.3.6.1.2.1.2.2.1.2.2 enp0s3
45. SNMP no Zabbix
Templates
TemplateSNMPGeneric– Itens
sysContact – SNMPv2-MIB
sysDescr –SNMPv2-MIB
sysLocation – SNMPv2-MIB
sysName– SNMPv2-MIB
sysUpTime – SNMPv2-MIB
TemplateSNMPGeneric– Discoveryrules
Não se aplica.
TemplateSNMPGeneric– Item prototypes
Não se aplica.
58. Arquivo
Zabbix SNMP
trapper
(Lê e
interpreta os
dados)
Existe
Interface
Compatível
?
NãoSim
Somente o “IP” ou o “DNS” da interface do host
será utilizado durante a pesquisa.
SNMP no Zabbix: Traps
21 1
59. Existi um
item de
“snmptrap.
fallback”
?
NãoSim
Log de traps
não
corresponden
tes
Existi um
item
compatível
com
snmptrap
[regexp]
NãoSim
O dado da
trap será
enviado para
todos os itens
compatíveis
o valor será
repassado
para ele
SNMP no Zabbix: Traps
21
Pode ser habilitado através da opção
“Registrar traps SNMP não correspondentes”
disponível em:
Administração → Geral → Outros.
Fim
60. Quero saber mais
Apostilado Treinamento Gerenciamento deRedescom SNMP - André Déo
Zabbixand SNMP on Linux– Andrew Nelson – ZabbixConference 2015
GoingDown! Using Low Level Discoveries in Practice –Raymond Kuiper –
Zabbix Conference 2013
Configuração SNMP Trap no Zabbix– ThayaneViana