I have a server from dell that came pre-configured with windows server 2003 on a 12gb system partition. After 2 years of running the system partition is almost out of space (I assume from all the windows updates) is there any commands/procedures to clean up unnecessary files to save some space, Or is my only option to re-size the partition ?
- Run the Disk Cleanup Wizard to recover space from temp files, IE history, etc.
- Stop the Windows Updates/Automatic Updates service, delete the contents of C:\Windows\SoftwareDistribution\, then restart the service.
- Move the page file off to a seperate drive, or set it to a fixed size to conserve space
- Clear off lingering user profiles (Right-click My Computer -> Properties -> Advanced -> User Profiles
- Check for memory dumpp files at %SystemRoot%\Memory.dmp (from system crashes)
- Check for lingering files in %systemroot%\servicepackfiles\
- If there is additional space on the disk you could also use gParted LiveCD to resize the C: partition into additional space.
I like to use TreeSize Free It can quickly show you where the offending files/folders are.
(On a side note, I've always hated running into Dells with 12G partitions. SOOOOO annoying.)
Delete the "$NtUninstallKB*" folders from C:\Windows (you'll need to turn on show hidden files and folders to see these). Do not delete the $hf_mig$ folder. You might want to keep some of these with a datestamp within the last month in case you need to uninstall an update, deleting them will prevent you from doing this.
Move your swap file to another partition if you haven't already done so.
Check the size of user profiles on the server and delete anything that shouldn't be there. Redirect My Documents if required.
Some 3rd party software can generate a LOT of logging in Program Files so check out what's there and kill it too. While you're at that, see what else has been installed to C:\ and - where possible - uninstall it and reinstall elsewhere.
You should with servers aim to have nothing but the OS on C:\, and Windows Server 2003 is perfectly capable of living in less than 4GB if so.
Some of the usual suspects:
%systemroot%\memory.dmp (if you have ever had a blue screen, there sometimes are large dump files)
If you have ever downloaded large files while logged on, these files may be saved in the local profile under C:\Documents and Settings\
- Delete all those "$NtUninstallKB*" folders from the %windir%.
- If you use a web browser on that server delete whatever is in the cache and set the cache size to something really small.
- Empty any and all temp folders (Windows cleans up after itself about as well as a teenage boy does).
- Delete crash dumps, etc.
Repartitioning is by far the best option but obviously requires down-time.