Using Metricbeat to monitor system and application metrics
Logs make up one aspect of data collection and visibility of a workload you need to monitor. Metrics are a great way to monitor and observe a workload as they represent the internal state of the component at any given point in time.
By correlating logs and metrics, an engineer or developer can quickly understand what a component is doing and how the internal state of the component is changing based on its activities in a given scenario. This is often a useful tool when troubleshooting and resolving issues related to the component in question.
In this section, we will look at collecting some metrics from the nginx
web server as well as the host that the server runs on.
Follow the instructions to start collecting system and application metrics using Metricbeat:
- Ensure
nginx
is configured to expose an internal API to collect server metrics. - Edit the
/etc/nginx/sites-enabled/default
file and add the following...