Disk cleanup utility is the utility which is used for cleaning up the machines. The utmost use of disk cleanup utility is that we can remove unwanted files and folders which can optimize the performance of the machine and as a result, we can get the free space in the respective drive.
If you are using the same machine for some time you will notice that there is a need to uninstall the unwanted files and folders so this can be done by disk cleanup utility.
I will use windows server 2012 R2 as an example and in windows server, disk cleanup utility is not enabled by default.
Disk Cleanup utility can be enabled/installed in windows server using “Add Roles and Features” options. Open the dashboard of your windows server and click on manage to select the “Add Roles and Features”.
Add Roles and Features wizard will be opened click “Next” on before you begin Windows.
Select the first option of “Role-based or feature-based installation” in installation type window and press “Next”.
If there are multiple servers installed then select the required server in “Server Selection” window but in this case, I have installed only one windows server so I will select it and press “Next”.
In server roles windows click “Next”.
In features, windows scroll down and expand the “User Interfaces and infrastructure”.
Select the “Desk experience” and it will open up a new pop up window.
Click on add features and popped up window will be closed so it will bring us back to the add roles and features wizard, click “Next”.
In the confirmation window press the “Install” button and installation will be started.
It will take some time to install it and after its installation click on close in “Results” window.
Now notification will be showing that restart is required for the newly added role to get functional.
Restart your windows server and go to the properties of the drive. Disk cleanup utility can be seen there.