I added the tags windows-server-2008-r2 and windows-server-2008 because I didn't see a tag for Windows Server Enterprise SP2. That's because there is no such thing. It's either Windows Server 2008 Enterprise Edition or it's Windows Server 2008 R2 Enterprise Edition. It isn't just Windows Server Enterprise Edition.
Aug 13, 2015
How to Squeeze More Space on Your Windows C drive
As a system administrator you are always fighting the battle to keep the C: drive as clean as possible, which at times can be a job in itself. In this post we will discuss a few places where you can get a few more MB or GB from the drive. These tricks apply on Windows 2003, 2008, 2008 R2, 2012 and 2012 R2.
Compress c:windowsinstaller directory
You can gain about half the space used by this folder by compressing it. First we need to unhide the folder then compress it.
Un-Hide the folder
Now let’s compress the folder.
Note: After done make sure to go back and re-check Hide Protected operating system files (Recommended).
Remove Recycle Bin
This cleanup has been covered in a previous post found here.
Reduce System Volume drive
This is another topic that has been discussed in a previous post also referred to as disappearing space. This is usually caused by Volume Shadow Storage space and is easily rectified by defining how much space can be used by a drive for Shadow Storage.
IIS Logs
The IIS logs are notorious for silently filling up the C: drive on systems. You can delete them manually or from a command line.
Watch The NeverEnding Story Online on Putlocker. Put locker is the way to watch The NeverEnding Story movie in HD. Watch The NeverEnding Story in HD. Watch neverending story 123. Watching The NeverEnding Story online free on Putlocker; titans season 2 2019, fast & furious presents hobbs & shaw 2019, spider man far from home 2019, crawl 2019, power season 6 2019, toy story 4 2019, american horror story 1984 season 9 2019, it chapter two 2019, x men dark phoenix 2019, aladdin 2019, avengers endgame 2019, rambo last blood. Watch The NeverEnding Story on 123movies: Bastian is a young boy who lives a dreary life being tormented by school bullies. On one such occasion he escapes into a book shop where the old proprieter reveals an ancient story-book to him, which he is warned can be dangerous. Shortly after, he 'borrows' the book and begins to read it in the school attic where he is drawn into the mythical land of. Apr 05, 1984 Watch online The NeverEnding Story (1984) on 123movies full movie free. Stream full movie The NeverEnding Story online without downloading or registration - rank movie after you watched it online. Watch The NeverEnding Story 4K FOR FREE. The NeverEnding Story. Bastian is a young boy who lives a dreary life being tormented by school bullies. On one such occasion he escapes into a book shop where the old proprieter reveals an ancient story-book to him, which he is warned can be dangerous. Shortly after, he 'borrows' the book and begins to.
Windows 2003
The IIS Logs are located in c:windowssystem32LogFiles directory. There will be directories starting with W3SVC in the name and for FTP will have MSFTPSVC in the name. Delete the log files in the directories with the exception of the current date logfile if you are so inclined. Another way is to use command line and a utility called forfiles. The nice thing about command line is that you create a cmd file and schedule it to run nightly. At the bottom of this post there will be an example cmd file and the syntax to add it as a scheduled task running as system
This command line example shows how to delete files ending in .log that are older than 14 days and the /s switch allows it to handle sub-directories.
Windows 2008 R2 / 2012 R2
As with Windows 2003 example the same goes for Windows 2008 R2 and 2012 R2, only difference is the log file location is changed to C:inetpublogs . You can delete them manually or use the command line.
C:WindowsTemp directory Cleanup
Clean Installer Folder Windows 2008 R2
There are several places where you can reclaim some space in c:windowstemp directory. The following list is some of the files that can be deleted safely, there are always more. You can also ad many to a script and run as a scheduled task.
Want to do it from the command line, Here you go. this example shows 0 days and no sub-directories.
forfiles /p C:WindowsTemp /m psscript_output*.txt /d -1 /c “cmd /c del @file”
forfiles /p C:WindowsTemp /m *.tmp /d -1 /c “cmd /c del @file” forfiles /p C:WindowsTemp /m KB*.txt /d -0 /c “cmd /c del @file” forfiles /p C:WindowsTemp /m KB*.html /d -0 /c “cmd /c del @file” forfiles /p C:WindowsTemp /m Microsoft*.txt /d -0 /c “cmd /c del @file” forfiles /p C:WindowsTemp /m Microsoft*.html /d -0 /c “cmd /c del @file” forfiles /p C:WindowsTemp /m *.sqm /d -0 /c “cmd /c del @file”
The C:windowswinsxs directory
This is the directory that gets the most questions which also leads to the most disappointment. You can recover space from this directory by using Disk Cleanup tool. To use it you must have the Windows Desktop Experience installed. Refer to this post on how to enable and use Disk Cleanup.
User Profiles
Another place to look for space is in old user profiles from long gone admins or users. These are easy to remove.
Sample Script
So let’s take this a bit farther and create a command script and run it as a scheduled task for some of the files and log it to the Application log so there is a record.
REM ****************************************************************************
REM FILE: Cleanup.cmd REM PURPOSE: To delete old logs and files after XX days REM USAGE: Cleanup.cmd REM REQUIREMENTS: Windows 2003/2008/2012 REM HISTORY: v1.0 REM *****************************************************************************
REM ** put Starting message in Application Log
%SYSTEMROOT%system32eventcreate.exe /T INFORMATION /L APPLICATION /SO Cleanup /ID 101 /D Starting-Scheduled-Task-to-maintain-Drive-files
REM ************************************
REM * Clean up logs older than 14 days REM ************************************ forfiles /p %SYSTEMROOT%system32LogFiles /s /m *.log /d -14 /c “cmd /c del @file” forfiles /p C:inetpublogs /s /m *.log /d -14 /c “cmd /c del @file”
REM Clear out files out of c:windowstemp
forfiles /p C:WindowsTemp /m psscript_output*.txt /d -1 /c “cmd /c del @file” forfiles /p C:WindowsTemp /m *.tmp /d -1 /c “cmd /c del @file” forfiles /p C:WindowsTemp /m KB*.txt /d -0 /c “cmd /c del @file” forfiles /p C:WindowsTemp /m KB*.html /d -0 /c “cmd /c del @file” forfiles /p C:WindowsTemp /m Microsoft*.txt /d -0 /c “cmd /c del @file” forfiles /p C:WindowsTemp /m Microsoft*.html /d -0 /c “cmd /c del @file” forfiles /p C:WindowsTemp /m *.sqm /d -0 /c “cmd /c del @file”
REM ** put Completion message in Application Log
%SYSTEMROOT%system32eventcreate.exe /T INFORMATION /L APPLICATION /SO Cleanup /ID 201 /D Completed-Scheduled-Task-to-maintain-Drive-files
Save the script as Cleanup.cmd or what name you desire. and now to add it to run nightly. In this example we will run the script from the c:scripts directory as SYSTEM at 4:15 am.
schtasks /Create /SC DAILY /RU “SYSTEM” /TN Cleanup /ST 04:15 /TR c:scriptsCleanup.cmd
As you can see there are several places and ways to get more space available on your C drive in Windows.
Related Posts
Leave a Reply
This site uses Akismet to reduce spam. Learn how your comment data is processed.
Comments are closed.
|
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |