Clean Up C Drive in Windows Server 2008 R2 with Disk Cleanup

by John, Updated on: September 22, 2022

When system C: drive is running out of space, you may clean up C drive to delete the unnecessary and junk files. From Microsoft Windows 98, there's already a native disk cleanup utility to help accomplish this task. But different with other versions, many people find Disk Cleanup is missing in Windows Server 2008 (R2). Because Disk Cleanup is not enabled in Windows Server 2008 by default, so before running Disk Cleanup in Server 2008 (R2), you should install or enable it by yourself. This article introduces how to add/enable Disk Cleanup in Windows Server 2008 (R2) and how to free up disk space with this native tool.

1. How to install/enable Disk Cleanup in Windows Server 2008

There are two ways to enable Disk Cleanup in Windows Server 2008 (R2):

  1. Copy files from WinSxS
  2. Install with Desktop Experience
The first option is easy and fast, but Disk Cleanup doesn't work in some environment. The second option make sure Disk Cleanup working in all conditions, but it requires reboot to complete installing with Desktop Experience component. Furthermore, together with Desktop Experience, many other unnecessary components are installed on the server, such as Windows Media Player, Desktop themes, Audio Recording.

Option 1: Add/Enable Disk Cleanup in Server 2008 R2 without reboot

The files to copy from WinSxS are different on Windows Server 2008 and R2, so firstly you'd better check the Server version. Press Windows + R on your keyboard to start Run, type winver and press Enter.

winver

Copy WinSxS files in Windows Server 2008 x64:

1. Click Start menu, right click Command Prompt on the top and select Run as Administrator.

2. Paste the command below and press Enter:

copy C:\Windows\winsxs\amd64_microsoft-windows-cleanmgr_31bf3856ad364e35_6.0.6001.18000_none_c962d1e515e94269\cleanmgr.exe C:\Windows\System32\

3. Paste the command:

copy C:\Windows\winsxs\amd64_microsoft-windows-cleanmgr.resources_31bf3856ad364e35_6.0.6001.18000_en-us_b9f50b71510436f2\cleanmgr.exe.mui C:\Windows\System32\en-US\

Copy WinSxS files in Windows Server 2008 x64 R2:

1. Run Command Prompt as Administrator.

2. Paste the command:

copy C:\Windows\winsxs\amd64_microsoft-windows-cleanmgr_31bf3856ad364e35_6.1.7600.16385_none_c9392808773cd7da\cleanmgr.exe C:\Windows\System32\

3. Paste the command:

copy C:\Windows\winsxs\amd64_microsoft-windows-cleanmgr.resources_31bf3856ad364e35_6.1.7600.16385_en-us_b9cb6194b257cc63\cleanmgr.exe.mui C:\Windows\System32\en-US\

Option 2: Install Disk Cleanup in Windows Server 2008 (r2) with other components

Step 1: Click Server Manager on bottom left next to Start menu.

Server manager

Step 2: Click Features on top left and then Add Features on the right.

Add Features

Step 3: Click the check-box in front of Desktop Experience. Add Features Wizard will ask you to install Ink and Handwritting Services if you have not previously installed, click Add Required Features.

Add required features

Step 4: Click the check-box of Desktop Experience again, and then click Next.

Desktop Experience

Step 5: Click Install to confirm and start installing.

Install

Once the features have been installed, the Wizard will need a reboot in order for the changes to take effect.

Disk Cleanup installed

2. How to clean up C drive in Server 2008 (R2) with Disk Cleanup

There are 3 ways to run Disk Cleanup in Windows Server 2008 (R2):

Press Windows + R together on your keyboard, type cleanmgr and press Enter, then C: drive is selected by default, click OK to continue.

Cleanmgr

Click Start > All Programs > Accessories > System Tools > Disk Cleanup

From Start

Open File Explorer, right click C drive and select Properties > Disk Cleanup.

From explorer

The 2nd and 3rd way is only valid after you installing Disk Cleanup in Windows Server 2008 with Desktop Experience.

Server 2008 Disk Cleanup tool will calculate how much space will be able to free on C drive (or other one you selected), then list the junk files in next window.

All these files can be selected and removed safely, click any type of files, you'll see its description on the bottom.

Click OK to start cleaning up. After it finish, repeat to Clean up system files.

Clean up disk

3. Additional step after cleaning up disk in Server 2008

Windows Server 2008 Disk Cleanup utility is easy to use, fast and able to clear up most common types of unnecessary/junk files safely. To the servers that never free up disk, it may help you regain several gigabyte of space.

However, free space will be eaten up quickly by new generated junk files, so you'd better add more space to C drive and expand it as large as possible. Otherwise, C drive will be getting full again in a short time. This step is very important but many people don't know.

If there is free space in other partition on the same disk, follow the steps in the video to shrink this partition and expand C drive:

Video guide

If your system disk is small and there is not plenty of free space, you may clone disk to a larger one and expand C drive with extra disk space:

Video guide

Besides shrinking, moving, extending and copying disk partition, NIUBI Partition Editor helps merge, convert, defrag, wipe, hide, scan partition, optimize file system and much more.

Download