Linux Check Disk Space Command To View System Disk Usage

Originally published at:

I recently switched from a Windows server to a Linux server operating system and need Linux check disk space command. I am using Ubuntu 16.04/18.04/20.04 and CentOS 7.x/8.x server. How do I find out disk space utilization information using Linux command line option?

I created a storage_monitor script based on the code and suggestions for improvement to it posted at

See my version at
Hope it helps someone like the original conversation helped me.