Release the hard drive space on server

Recently, I have seen a situation that my Drive C shows almost full — but the total size of the folders inside Drive C is less than a half of the hard drive size.

Hard Drive C Usage

Total Size of All Folders in Drive C

There is a suggestion to use Windows Disk Cleanup tool to free some space in hard drive: https://www.howtogeek.com/256594/how-to-enable-hidden-options-in-windows-disk-cleanup-tool/

You can enable the hidden options for Disk Cleanup Tool by running cleanmgr /sageset:65535 /sagerun:65535 as administrator in CMD. Here is an article to explain how to use the command: https://docs.microsoft.com/en-US/troubleshoot/windows-server/backup-and-storage/automating-disk-cleanup-tool

I tried the above suggestion — which did NOT resolve the issue.

Then I used a tool WinDirStat to analyze the drive usage — and found that log files in the folder inetpub takes the most space. The hard drive space was finally freed after those log files were moved to another hard drive location.