asked on
Want to move a paging file from a depleted system drive on Windows Server 2012 r2
I have an active 2012 Standard r2 server that has lost it's system drive capacity (0 % KB). There is no data/or application available for me to safety remove from the drive. With further investigation I discovered that the WinSxS folder (holds files during Windows updates) is housing 19.4 GB, yet I can't safety remove unless I use the Disc Clean up tool, which isn't installed by default on 2012 Standard.
I also discovered that the paging file is residing on the C:\ system drive as well. I could free up about 3-4 GB of drive space by just moving it to another alternate internal drive (used for storage).
So, my plan is to move the paging file to another partition, free up 3-4 GB of space on the C:\ drive, install the Disc Clean up tool, and then execute to free up additional space.
The above requires me to reboot the server. Being that the C:\ System Drive currently has 0% capacity, will the server have a problem restarting?
I plan, in my configuration to remove the paging file from the C:\ drive, and set up space to the alternate drive in one action, then reboot. Does anyone see any potential problems in my solution?
Will the server just make the swap without attempting to boot to a drive with no space? Obviously you can understand my concern. Yes, I performed a full backup of all important business data.
BTW, WinSxS is not related to updates. It keeps different versions of assemblies (.NET aso.), and tends to not get cleaned up and so grow unreasonably over time.
You said "There is no data/or application available for me to safety remove", but:
C:\Windows\SoftwareDistribution\Download is something you can delete content - that one is where pending updates are located (and sometimes updates performed still stay there).
C:\Windows\Temp is another one you can delete content without issues.
Maybe you can remove unused user profiles (created by accidentally logging in with a non-admin account).
If you really cannot get any more space, there is nothing you can do other than reboot. As said by Rodney, you might get errors you should be able to ignore. Make sure to reboot after you got more space on C:.
How much space does the c:\users use?
What does the server do?
C:\inetpub\logs?
C:\windows\system32\LogFil
%TMP% %TEMP%
IIS, iis smtp, ftp log files
Check whether you have windows manage the paging file size
Properties of computer.advanced, performance advanced, cache
if you want to recover some megabytes that allow you to do your recovery actions, you can simply use the NTFS option of "compression" of some directories as "c:\program files", and all folders that could contain txt logs, as IIS.
You can also remove some files as MEMORY.DMP, or mini memory dump from the folder C:\Windows\Minidump.
ASKER
I also recognize what was happening in the WinSxS folder - just mixed the two up. Is there a safe way to delete from the WinSxS folder?
Common opinion on deleting files from WinSxS is "don't mess with it".
The C:\Windows\SoftwareDistribution\Download folder can be cleaned up manually.
The cleanup tool just helps with collecting deletable files, it hasn't any special access to them. Using it is much easier than doing everything manually.
dism /online /cleanup-image /startcomponentcleanup
Delete files from
C:\Windows\Temp
%TEMP% (C:\Users\username\AppData\Local\Temp\
If you actually purchased enough RAM, it makes sense to just turn off pagefiles. Pagefiles were created during a time when RAM was expensive. Turning off pagefiles also arrests any runaway process that will explode your memory usage and fill up your disk.
They should not be turned off, but not letting windows manage it.
If you have a lot of memory, you can keep the pagefile to a symbolic value (A few GB). It should not be used, or very rarely.
Even if you remove it totally, it will not be a big problem. If you have a reproductible error, you will be able to reenable it, in case you have a support to analyze it.
If your system isn't crashing all the time, you don't need to keep a page file for dumps. Besides, even without a page file, minidumps will still get created.
If your system is a VM, it's a waste of disk access. It doesn't make sense to overload your disks with all that access. If my system starts crashing a lot, then I'd enable the pagefile again to get full dumps, if the minidump doesn't provide enough information.
ASKER
I performed a reboot. It was successful.
A reboot is mandatory, so if you clean up before reboot you'll have a better chance at a clean startup.
Cheers