I want to create a Perl script that performs a health check on my PostgreSQL database. For now I have these categories to check, and the next step is to look into them to look how to perform the checks in Perl.
I want to complete the checks I can perform. Could someone add categories/system checks to my list?
The ultimate goal is to run a script that will execute (probably SQL) code and this will export it in a nice txt file so that I can have a health check of my database.
My categories are
- OS check (up time, version (check for update) )
- Log files:
- Where are they located, copy them all to a back up folder
- Is a back up performed recently (was it run successfully?)
- Table size , disk size , ...
- Check the vacuum
- Show the config files (
postgres.conf) to show the configuration settings
- Show current connections and other connections information
- Get the slowest queries and a report of all the previous slowest queries
Do you find anything else missing in the list that is crucial for a health check on progress?