Solution to the problem of "Out of memory" on Windows

Every now and then, when you open many programs on Windows 7 or Vista, an error message appears that says " Not enough memory ", with the suggestion to close some programs.
If you do not close anything and ignore the message, you can continue working, but you risk that one of the programs crashes and closes suddenly without saving your work.
The problem of insufficient memory on Windows is rather annoying because it can appear even if only the web browser is open, with many tabs open.
First of all, this problem relates to memory and has nothing to do with disk space.
Windows runs programs in physical memory, called RAM (Random Access Memory) and virtual memory .
If the RAM runs out, Windows, with a clever trick, uses virtual memory by exploiting a file on the hard disk called a paging file or pagefile.sys.
Since the hard disk is much slower than RAM, when a program uses the paging file, the loading will be less fast, but without any block.
However, if the maximum amount of the paging file is also exhausted, then Windows goes " Out of memory " and the message of insufficient memory appears.
1) The most obvious solution would be to install additional RAM even if, as already seen, you can use more than 4 GB of RAM only in certain conditions.
In most cases the problem is not that the memory is exhausted but that it is insufficient to perform a certain process that wants to store large volume data (for example a video), and does not find contiguous space.
Practically, even having a lot of RAM, if a process requires a higher amount of memory to be allocated together in a single sector.
Windows also has a 2 GB limit on memory usage for a single user-mode application.
To understand, just think of a wall where you want to put a sofa and a bookcase.
If the bookcase is longer than the space available after placing the sofa, it will not enter even if there is room for something smaller.
With some tools like Minimem or Rizone Memory booster you can optimize the management of RAM automatically, trying to allocate it as best as possible.
2) You can increase the amount of Windows virtual memory .
To do this you need to go to: Control panel -> System -> Advanced system settings -> under Performance, press Settings -> Advanced -> Press the Change button -> Press the custom size dot and set a minimum value or different maximum -> Press the Set key and then OK and Apply.
This value refers to the size of the paging file.
In another article we have tried to give indications about the optimal values ​​for the virtual memory and paging file of Windows indicating a rule for which we must have a maximum size that is 1.5 times the RAM.
However, this rule shows its limitations if there is a problem of insufficient memory so it must be increased.
In a PC with 4 GB of RAM I would say that you can have a virtual memory with dimensions
minimum 2500 and maximum 6000.
You should not set too low values, otherwise nothing will turn, nor too high otherwise it slows down the computer and becomes unstable.
To defragment the paging file you can use PageDefrag and avoid the problem indicated in point 1.
3) If this does not solve the problem of insufficient memory, the causes could depend on other factors.
First of all it is worth investigating the programs that run in the background .
Then open the task manager (or Task Manager ) and sort the processes by Working Set by clicking on the column header.
For each process you can see the responsible program or the service.
In another article we saw which services can be disabled on Windows to speed up the PC.
The goal is to close unnecessary active Windows processes and eliminate memory wastes.
4) On a Microsoft support article there is another solution, that of changing the heap size of the desktop .
Beyond what this means, this size is specified in a registry key that needs to be changed manually.
Click on the start menu and write, in the search bar or in Run, the regedit command and press enter.
By expanding the branches of the key directory on the left, navigate to the following path: HKEY_LOCAL_MACHINE \ SYSTEM \ CurrentControlSet \ Control \ Session Manager \ SubSystems .
Look in the center of the window and right click on the Windows key to change it.
You will find a value like: % SystemRoot% \ system32 \ csrss.exe ObjectDirectory = \ Windows SharedSection = xxxx, yyyy, zzzz ......
Then change the value of yyyy by writing the number 12288 for windows Vista or Windows 7 32bit and 20480 for 64bit systems.
Also change zzzz to the number 1024.
Close, restart the PC and check if the insufficient memory error continues to appear or if it becomes less frequent.

Leave Your Comment

Please enter your comment!
Please enter your name here