Windows 11 running out of ram

I have a friend who has 16 gigs of ram. He’s running Windows 11. He deleted pagefile.sys and shut off pagefile because some thing online told him to. When he’s playing a game, windows tells him he’s run out of ram. Even though, we had task manager up and it said it was only using 8 gigs… out of the 16.

Why is it doing this? With 16 gigs, doesn’t it have enough memory while playing a game, even if it’s only using half of the installed memory? I’m confused. I don’t use a pagefile in Linux. Is Windows that dependent on a pagefile that it shits the bed if there isn’t one?

1 Like

There’s the problem. Windows is dependent on the page file for normal everyday operation and will quickly exhaust physical RAM. The fact your friend did something without actually knowing what they were doing is the problem. Set the page file back to system managed and things will be just fine.

1 Like

yeah thats typical if you delete the page file…
its actually needed as memory swap space for windows. and is essential to it working.
so tell him to reset the page file status to what ever it was before and the problem will go away.

setting to system managed if he has an ssd/nvme is fine and will dynamically change on need. if he’s running spinning rust then the page file recommended size is 1.5x your memory size.
yep another reason not to boot off spinning rust.

Some apps need a minimum page file size regardless of physical memory.

3 Likes

E-Wasted is correct on this one. Some programs, be games or else, require a page file. If they don’t find it report the system to be out of memory to prevent the system from crashing. It might not happen, but the game doesn’t know how much memory it can work with, it just asks and the OS answers.

Not Windows, but some programs might. Linux works differently and there can be softwares that require the system to have a SWAP partition. Haven’t find any yet, but it could be the case.

There is to say that Windows doesn’t show accurate memory usage as Linux can. So it might be true, but it’s just cache and buffers that need to be flushed. A fun test would be to have 32GB of RAM in it, keep the page file off and see what happens. If the system keeps reporting it’s out of RAM, it’s a software failsafe. If not the system is really out of RAM with “just” 16GB and no page file active.

the same thing would happen he would quickly get a message saying out of memory.
like i said earlier its part of how windows works and is needed.
as to how much you need will depend on the type of storage, with nvme/ssd’s needing way less space as windows will dynamically allocate it.
and hdd’s will need to pre allocate a much larger swap, because it doesnt have the low latency access of flash so is comparatively slow.

The issue is most likely nothing to do with anything “requiring a swap file,” your friend is simply out of committable virtual memory because he disabled his swap file.

Long, but actually very short summary of what’s going on:

The way Windows works is that when a process is started, it askes the operating system for the most memory it could potentially need. Basically a “hey, worst case I need X amount of memory.” Windows then looks at that request and if it has available virtual memory it will “commit” that memory to that process. Committed memory is a promise made by Windows to that process that it has virtual memory required IF it becomes needed. All of these commitments put together become what is known as the “Commit Charge” or simply “Committed” memory on the latest versions of task manager. This is the first half of the fraction that is the Committed field in Task Manager. The second half of that fraction is simply physical memory + page file. If a process asks for more virtual memory than Windows has left to commit, that process will not get to start and Windows will throw a low virtual memory error.

It’s important to understand that committed memory is not necessarily in use, and may never be used. The OS will only put things into RAM as the actual data is requested by the processes. The commit charge can be a lot larger than your actual physical memory and not be thrashing the disk swap. Windows will try it’s best to keep everything it’s using in RAM, only swapping things as a last resort.

Even more in depth summary of Windows Memory Management if anyone is curious.

2 Likes