Summary
As soon as a Moodle instance is live, it is susceptible to attack from threat actors. It isn’t a question of whether our site will be attacked but when. Rather than having to constantly monitor the Mathaholics platform 24/7, we can use infrastructure monitoring tools to keep an eye on the platform and alert us if there is any unexpected behavior happening. We started this chapter by learning the key concepts of infrastructure monitoring before moving on to setting up Grafana, a popular open source infrastructure monitoring and alerting tool.
Using Grafana as an example, we saw how all infrastructure monitoring tools are configured in similar ways – agents are installed to gather data on critical components (using the PoLP to ensure security), data from agents is consumed and stored in a data store, we build queries to extract data and transform it into information to give it meaning, and we visualize the information in a dashboard.
We also saw how anomalies...