Tuesday 17 January 2012

Server Core–How to Properly Move the Swap File

We have posted on this subject before though the pieces of the puzzle were a bit incoherent due to the comments providing the proper methodology and eventually a link to Sander Berkouwer’s blog post with up to date information.

As is indicated in the second blog post’s comments we find the following methodology:

  1. Create the dedicated partition after the OS partition using DiskPart.
    • We install Server Core to a 50GB partition and FULL to a 75GB partition.
    • We use RAM * 2.5 as a rule.
    • For larger GB where only the Hyper-V Role is running then RAM * 1.
    • We assign the letter S:
  2. wmic computersystem where name=”MyCoreServer” set AutomaticManagedPagefile=False
  3. wmic.exe pagefileset create name="S:\pagefile.sys"
  4. wmic.exe pagefileset where name="S:\\pagefile.sys" set InitialSize=12288,MaximumSize=32768
    • Note the double slash in the file path.
  5. wmic.exe pagefileset where name="C:\\pagefile.sys" delete
  6. shutdown –r –t 0 –f

As per Sander we can check the registry for the settings as well:

  • HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management

Some additional reading:

Philip Elder
Microsoft Small Business Specialists
Co-Author: SBS 2008 Blueprint Book

*Our original iMac was stolen (previous blog post). We now have a new MacBook Pro courtesy of Vlad Mazek, owner of OWN.

1 comment:

Anonymous said...

Worked perfectly, thanks!