1

My 32-bit Windows 10 machine has a reasonable processor, but limited hardware resources (only 4GB RAM and 28GB local HDD). Windows itself takes up nearly half the disk so I'm using an external 1TB USB HDD. This has been mapped to Z:. I would like to move the system virtual memory page/swap file to the external drive.

In System Properties > Advanced > Perfomance > Settings > Advanced > Virtual Memory > Change, the option Automatically manage paging file for all drives has been switched off. Then for all listed drives (C: and Z:) No paging file has been selected, followed by Set.

The PC was then rebooted, and Folder Options > View > Hide protected operating system files was switched off. In Windows Explorer I deleted pagefile.sys, rebooted again and confirmed the pagefile.sys did not return. All good so far!

Now I return to the page/swap file settings and this time select System managed size for Z: (keeping C: with No paging file selected). However, whenever I reboot, a popup appears informing me that a temporary pagefile was created on C: due to some unspecified problem creating the pagefile on the external drive.

True enough, on C: there is a pagefile.sys but nothing is ever created on Z:!

My suspicion is that the external USB HDD is only registered and recognised by Windows later in the boot cycle and only after the page/swap file is created. Can anyone confirm this?

  • Is it possible to use an external USB drive to host the (only) pagefile on a system?
  • If not, can Windows boot be tweaked so that Z: is definitely registered and recognised early allowing the pagefile to be created there?

Thanks in advance!

2
  • 1
    Your attempt at a solution for more storage space is misdirected. The page file is essential to the OS. But is everything else that you do have stored on the internal HDD always essential, i.e. accessed every day? Back in the day when "mass storage" had limited capacity, removable storage (both hard and flexible disks as well as tape) had to be organized to accommodate specific application programs and/or data sets. IOW clean up the HDD, and move large and/or infrequently-used apps to an external drive.
    – sawdust
    Commented Apr 1, 2020 at 21:59
  • Perhaps the solution sought is misguided, but its still a valid question. Moving as much as possible to the external disk is good advice. Since the page file can be completely switched off, I'd describe the page/swap file as "useful" rather than "essential".
    – AlainD
    Commented Apr 2, 2020 at 7:41

1 Answer 1

2

You cannot create the page file on an external disk.

The page file, also known as the swap file, pagefile, or paging file, is the backing storage for virtual memory and so must be on an internal always-on disk, the faster the better. If missing, it will be created (which is what you observed).

The page file is strongly coupled with the interrupts mechanism and will not use slow external disks.

You may disable it completely (not recommended!), or reduce its size (but not too much), if disk space is a problem.

For more info see What Is the Windows Page File, and Should You Disable It?

5
  • It won't solve your problem, which is lack of free space on your system drive, but there's this very good sort-of-freeware (most functionalities are free) called Tweak-SSD (here: totalidea.com/products/tweak-ssd) that will let you optimize your SSD configuration, mostly by enabling or disabling actions that would result in a lot of wear for your SSD. I've installed it on two PCs running Windows 10 1909 and on another running Windows Server 2019, and all three run more efficiently ever since, with no BSODs, they're more responsive, less prone to overheating and thermal throtling.
    – user1019780
    Commented Apr 1, 2020 at 17:22
  • ... AND I'm not trying to sell you anything. EDIT: regarding your pagefile, mine has been, if not deleted or disabled, but bypassed by Tweak-SSD, which set Windows to load a lot of programs and services in RAM. The pagefile on my Server hasn't been used in over three weeks, since I installed the software, and it's running smooth as butter.
    – user1019780
    Commented Apr 1, 2020 at 17:23
  • @Didier: I don't think his problem is that the pagefile is used too much, but just disk space.
    – harrymc
    Commented Apr 1, 2020 at 18:13
  • I know, that's why I took the precaution to say it wouldn't solve the OP's issue, ALTOUGH, when you think about it, setting a pagefile at the lowest possible threshold (I believe 16MB is the minimum), with an upper limit at, say 128MB, can save a big chunk of disk space compared to the default 2GB or so on a PC like his/hers. I'm really not trying to push this software to anyone, but I really like what it does to my PCs, and if the OP decided to shrink his/her pagefile in size and switch to Tweak-SSD, he/she notice one heck of a difference in his/her daily use. My two (euro)cents...
    – user1019780
    Commented Apr 1, 2020 at 18:50
  • Since using an external disk for the page/swap file is not possible or recommended, as per the comments from @harrymc and my own experiments, using a smaller swap file is an option which makes sense in my circumstances...thanks!
    – AlainD
    Commented Apr 2, 2020 at 7:48

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .