Reader small image

You're reading from  Mastering Proxmox. - Second Edition

Product typeBook
Published inMay 2016
PublisherPackt
ISBN-139781785888243
Edition2nd Edition
Tools
Right arrow
Author (1)
Wasim Ahmed
Wasim Ahmed
author image
Wasim Ahmed

Wasim Ahmed, born in Bangladesh and now a citizen of Canada, is a veteran of the IT world. He first came into close contact with computers in 1992 and never looked back. Wasim has a deep understanding of networks, virtualization, big data storage, and network security. By profession, Wasim is the CEO of a global IT support and cloud service provider based in Calgary, Alberta. He serves many companies and organizations through his company on a daily basis. Wasim's strength comes from his experience, which comes from learning and serving continually. Wasim strives to find the most effective solution at the most competitive price. He has built over 20 enterprise production virtual infrastructures using Proxmox and the Ceph storage system. Wasim and his team are notorious for not simply accepting a technology based on its description alone, but putting it through rigorous testing to check its validity. Any new technology that his company provides goes through months of continuous testing before it is accepted. Proxmox made the cut superbly.
Read more about Wasim Ahmed

Right arrow

Chapter 12. Monitoring a Proxmox Cluster

Monitoring a network environment of any size is mandatory to ensure a healthy operation and timely response to any issues. In this chapter, we will see how to monitor and configure notifications, so that when something goes wrong in the cluster, we can know about it right away and take the necessary action. We will cover the following topics in this chapter:

  • An introduction to monitoring

  • Zabbix as a monitoring solution

  • Proxmox built-in monitoring

  • Configuring the Disk Health notification

  • Configuring SNMP in Proxmox

  • Monitoring the Proxmox cluster with Zabbix

  • Monitoring the Ceph cluster with the Ceph dashboard

An introduction to monitoring


In a network of any size, it is only a matter of time before an issue arises owing to intentional or unintentional circumstances. The root cause for an issue can be owing to hardware failures, software issues, human errors, or just about any other environmental factor, which causes loss of network or data. Network monitoring is a practice in which an administrator can check a pulse of the network components in a network environment.

There is no system to monitor everything. A good monitoring system is usually put together with various tools and some types of notification options to send alerts automatically. The Proxmox cluster is a sum of switches, network cables, physical nodes acting as hosts, and virtual machines. A monitoring system should be able to monitor all of these components and automatically send notifications via a medium, such as an e-mail or SMS to responsible parties. There are wide ranges of network monitoring tools available today, such as...

Proxmox built-in monitoring


Proxmox has limited monitoring capabilities built into the GUI; however, it does lack the extensive and robust monitoring usually found in a complete monitoring solution. Proxmox comes with built-in RRD-based graphs to show the historical resource usage and performance data up to 1 year. Using this tool, we can analyze the performance trend of a resource over a period of time. All consumption and performance data are under the Summary tab menu for both Proxmox nodes and virtual machines. We can view data on a per hour, day, week, and yearly basis.

The following screenshot shows the Summary page of the Node pm4-1 with the drop-down list to select a period of data:

There are also ways to display a list of all the nodes and virtual machines in the cluster and sort them by consumption to get quick information on the highest or lowest resource consuming entity. We can see the list by navigating to Datacenter | Search. The following screenshot shows the list of Proxmox...

Zabbix as a monitoring solution


Zabbix, released in 2004, is a robust web-based network monitoring tool capable of monitoring many hundreds of hosts and running thousands of checks per host at any set time. Zabbix is completely open source and does not have enterprise or paid versions. Zabbix takes just a few minutes to install, even by a beginner, and it can be fully configured through a web-based interface. The following screenshot shows the Zabbix 3.0 dashboard after logging in through the web GUI:

Zabbix has a very active community and many downloadable templates used to monitor a variety of devices or equipment. It is also comparatively easy to create our own custom Zabbix template for nonstandard devices. More details on Zabbix can be found on the official Zabbix site at: http://www.zabbix.com/.

It can easily be argued to give preference to Zabbix over main stream monitoring systems, such as Nagios, or Icinga, or any other solution currently available. The reason is simplicity without...

Installing Zabbix


In this section, we will see how to install Zabbix and configure it to monitor the Proxmox cluster and network devices. We are going to install the Zabbix version 3.0 on CentOS 7. Zabbix can be installed very easily on other major distributions, such as Debian or Ubuntu.

Tip

For stability and performance when monitoring a large production environment, using CentOS as the base operating system is highly recommended.

Always make sure that you set up a separate node or a virtual machine to offer maximum performance. A fully configured Zabbix with thousands of items will run frequent checks, which is resource heavy. Using Zabbix in a node or VM, which serves other roles, will greatly affect the performance.

Zabbix also provides preinstalled and preconfigured downloadable appliances for evaluation purposes. It is useful for learning and testing purposes but not recommended for production use. Zabbix appliances can be downloaded from http://www.zabbix.com/download.php.

Zabbix will...

Configuring Zabbix


After the Zabbix server is installed and functioning, we have to set up e-mails so that we get automated e-mails whenever there is an issue. Zabbix 3.0 is able to send e-mails through SMTP. We can figure it out by navigating to the Administation | Media types menu and changing the SMTP information under Email. After the e-mail is configured, it is time to add some hosts or devices to start monitoring.

Configuring a host to monitor

In this section, we will see how to add a host, whether it is a Proxmox node or a virtual machine, to the Zabbix monitoring server. This procedure is the same for adding any host with a Zabbix agent installed. By default, the Zabbix server is added to the monitoring host. We are now going to add our example Proxmox node pm4-2 in Zabbix in order to be monitored. The following steps show how to add the host to Zabbix:

  1. Go to Configuration | Hosts and click on Create Host.

  2. Type in the Hostname and Visible name. The hostname must match with the hostname...

Configuring SNMP in Proxmox


Simple Network Management Protocol (SNMP) is a network management protocol used to monitor a wide variety of network devices. It is especially useful when a full network monitoring agent installation is not possible, such as switches, routers, printers, IP-based devices, and so on. Almost all network monitoring programs support some level of SNMP.

If the choice of monitoring a package does not have any agents, SNMP is the best option to monitor those devices. SNMP is fully configurable in Linux distributions, and since Proxmox is based on Debian, it inherits all the benefits of SNMP. To learn more about SNMP, refer to: https://en.wikipedia.org/wiki/Simple_Network_Management_Protocol.

There are a few components of SNMP worth mentioning here since we will be using them to configure SNMP. They are as follows:

  • OID; Object Identifier

  • MIB; Management Information Base

OIDs

OIDs or Object Identifiers are objects that the SNMP queries to gather information from a device....

Adding an SNMP device in Zabbix


Adding an SNMP device in Zabbix is a similar process to adding a host except that we have to select SNMP interfaces instead of agent interfaces, as shown in the following screenshot:

By default, SNMP devices listen on port 161. Zabbix comes with prebuilt SNMP templates, which can gather a vast amount of data for devices where the agent installation is not possible or desired. A common example of an SNMP device is a network switch. Zabbix has excellent support for switch monitoring through the SNMP template.

In this example, we will add a Netgear 48 port switch using the SNMP interface. Go to Configuration | Hosts, and click on the Create host button to open a new host creation page. Besides using the SNMP interface in the host creation page, we need to select the SNMP Device template and type in SNMP v2 Community string under Macros, as shown in the following screenshot:

The {$SNMP_COMMUNITY} macro is used to pass a community secret string, which is used by the...

Monitoring the Ceph cluster with the Ceph dashboard


As with Proxmox VE 4.1, we can monitor and manage the Ceph storage cluster through the Proxmox GUI. Under the Ceph tabbed menu of each node, you will see a great amount of data such as the health status of the Ceph cluster, the number of OSDs, the MONs, pools, the Ceph configurations, and so on. Refer to Chapter 4, Storage Systems, for the information on Ceph management through the Proxmox GUI. In this section, we will see how to implement a third-party solution to monitor the Ceph cluster. There are several options used to monitor a Ceph cluster graphically, which are as follows:

All the three options are viable options used to monitor the Ceph cluster. But owing to the simplicity and effectiveness of this chapter, we are going to see how to install the Ceph dashboard. This is the...

Summary


In this chapter, we saw how we can monitor a Proxmox cluster network using powerful monitoring systems, such as Zabbix. By no means is Zabbix the only monitoring option available in the main stream choice. But it does have many advantages over other solutions. The out-of-box features, such as graphing, template, SNMP, auto notification, and so on, are just the tip of the iceberg of what Zabbix has to offer. Whether it is a small environment or a large cloud service provider spanned over multiple regions, Zabbix can monitor them all. A good network administrator will try a few solutions and find the one that suits their environment best.

In the next chapter, we will see some complex production level virtual network environments leveraging Proxmox as a hypervisor. We will take a look at a scenario-based network diagram to gain knowledge on what Proxmox can do.

lock icon
The rest of the chapter is locked
You have been reading a chapter from
Mastering Proxmox. - Second Edition
Published in: May 2016Publisher: PacktISBN-13: 9781785888243
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
undefined
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime

Author (1)

author image
Wasim Ahmed

Wasim Ahmed, born in Bangladesh and now a citizen of Canada, is a veteran of the IT world. He first came into close contact with computers in 1992 and never looked back. Wasim has a deep understanding of networks, virtualization, big data storage, and network security. By profession, Wasim is the CEO of a global IT support and cloud service provider based in Calgary, Alberta. He serves many companies and organizations through his company on a daily basis. Wasim's strength comes from his experience, which comes from learning and serving continually. Wasim strives to find the most effective solution at the most competitive price. He has built over 20 enterprise production virtual infrastructures using Proxmox and the Ceph storage system. Wasim and his team are notorious for not simply accepting a technology based on its description alone, but putting it through rigorous testing to check its validity. Any new technology that his company provides goes through months of continuous testing before it is accepted. Proxmox made the cut superbly.
Read more about Wasim Ahmed