Collecting data from Linux
Native Linux commands provide useful data about the current system status and health. However, each one of those Linux commands and utilities are focused on getting data from only one aspect of the system. We need to leverage Python modules to get those details back to the administrator and generate useful system reports.
We will divide the reports into two parts. The first one is getting general information about the system by using the platform module, while the second part is exploring the hardware resources in terms of the CPU and memory.
We will start by leveraging the platform module, which is a built-in library inside of Python. The platform module contains many methods that can be used to get details about ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access