Menu
Solution: This files are temporary files created by different Windows operations, like installing updates. Removes the cab files from c:windowslogsCBS. C:WindowsTemp is a folder commonly used by windows updates, logs or temporary files. During an installation, the application moves the caps files to a temporary folder, In this case C:WindowsTemp If you want to free some space, you can delete everything on this folder, My suggestion is delete just the old ones, but keep the most recently files (a month ago).
Every Windows version uses a special directory which stores temporary files. These files are created by various Windows services, installed apps and tools. Temporary files can be safely deleted after the process which has created them has quit. However, this does not happen often, so the temporary directory continues to store them and fills your disk drive with junk. Here is how to clean up the temp directory automatically in Windows 10.
RECOMMENDED: Click here to fix Windows errors and optimize system performance
There is a special environment variable in Windows 10, %temp%, which points directly to the directory with your temp files. You can test it in action by typing %temp% in the address bar of the File Explorer (%tmp% also works):
Using this information, you can quickly create a batch file that will remove all the temp folder's content. If you put this batch file in your Startup folder, you'll get your Temp folder cleaned every time your start your PC.
Before you proceed, I suggest you to apply the following tweak: Add Batch file (*.bat) to New menu of File Explorer. You can save a lot of time by having the ability to create a new batch file directly.
Clean up temp directory automatically in Windows 10
- Create a new batch file with the following content:This will remove the contents of the Temp directory in Windows 10.
- Press Win + R shortcut keys together on the keyboard to open the Run dialog. Type or paste the following in the Run box:The text above is a special shell command which makes File Explorer to open the Startup folder directly.
- Move your batch file to the Startup folder and you are done!
Note: We intentionally did not delete the %temp% folder itself using batch commands because deleting the folder and recreating it can cause various permissions issues with the hundreds of apps that write to it. It is safer to delete the files inside it first and then the empty folders.
After doing the steps above, you can reboot your PC and open your Temp folder. You will find lesser files there than before. This will save you disk space and your time, since you need not clean the folder manually.
Update: Starting with build 15014, a new option appeared in Settings. Open Settings and go to System -> Storage. There, you will find the option named 'Storage Sense'. Enable it and you are done. Windows will remove all the temp folder's content automatically.
The user can customize this behavior. To do this, click the link 'Change how we free up space' under the switch.
The related page will be opened:That's it.
RECOMMENDED: Click here to fix Windows errors and optimize system performance
I recently noticed at work that my Windows 7 virtual machine’s C: drive was down to its last couple of gigabytes of free space. What’s up with that? I wondered. After doing a bit of poking around, I discovered that the Windows Temp folder was clogged with multiple .cab files, nearly 32 GB of them in this case. Not cool!
It seems that all of these files are related to Windows updates not installing correctly, or something along those lines. The solution given by Microsoft forum user 5kyFx is this:
- Delete the .log files from %systemroot%LogsCBS (which prevents the .cab files from being regenerated)
- Delete the .cab files from %temp% (which clears space on the drive)
In my case, this appears to have solved the problem.