What is a Memory Leak? How to Prevent it?
A Memory Leak happens when the resources did not return to the system of the app you were using. The usage of your memory is increased in the task manager and the performance of your PC is decreased. This usually happens when you do not have enough amount of RAM in your PC and the memory required is way above your RAM capacity.
This is similar to getting High CPU usage on your PC. This can be prevented in multiple ways, as the causes can be multiple too.
This can be fixed in multiple ways and this is not as severe as getting High CPU usage. This can be fixed by Restarting your PC, closing certain apps, disabling certain services.
Restart Your PC:
This is not a permanent solution or fix, but this can temporarily fix this issue while we look for a permanent fix. Restarting your pc is going to clear all the data that was making it use this much RAM. Restarting your PC solves the issue in most cases, at least temporarily.
To restart your PC:
- Click on the Windows logo on the bottom right of your screen, or click on the Windows button on your PC
- Click on the Power Button
- Click on restart
This should at least make your PC useable if it was not before.
Disable Services:
You can disable the service that is using most of your RAM from the task manager. Services perform a most automated task on PC or listen to data requests from other apps.
Then it makes sense to use memory but not to this extent. The task manager helps you in this scenario by telling you which service or application is using the most memory.
To disable the service that is using the most memory:
- Press Ctrl + Shift + Esc to open the task manager
- Here you can find the service that is using the most memory
Remember the name of the service - Press windows+R
- Type services.msc
- Now find the service that was using the most memory in the task manager
- Double click on the service
- Click on the Stop button
- Change the Startup type to Disabled
This is going to disable the service, preventing it from ever starting again and using your RAM causing your PC to lose performance.
Disable Common Leaking Services:
There are some of the more common services that cause memory leaks. These services are known for this problem, as these services were found amongst most people.
- Open services by typing services in the search bar
- Find the Service IP Helper, click on it and press the stop & disable button
This service might be one of the reasons that you’re getting a memory leak on a PC. This service is found in those PCs which have memory leaks and are struggling to perform
Note: If you’re worried that disabling this is going to harm your PC, this enables you to use IPV6 so disabling this is not harmful at all
3. Next service you have to delete is Superfetch
This service is known as one of the lethal when it comes to memory leaks. This service can cause Blue screens or it can even crash your PC. It’s better to stop it from interfering with your PC
Disable Services from Registry Editor:
Some services are not able to be stopped or disabled from services or anywhere else. This is one of the most delicate methods, one wrong step and you can mess up your PC. Make sure you make a Restore Point.
- Open your search bar, type Registry Editor
- Expand HEY_LOCAL_MACHINE
- Next, Under system Expand Controlset001
- Click on Services
- Now, Find NDU
- Click on Start
- Click on it and change the value to 4
Changing the value to 4 is going to disable it as 4 is an invalid value for this service. This service was known for crashing your PC.
Google Chrome using too much RAM:
Google Chrome is one the best browsers in history but everything has its downside. Google Chrome sometimes uses large amounts of RAM. People can use other browsers too like Opera GX, Microsoft Edge, Firefox, but once you have used Google Chrome you cannot get used to anything else. It’s like using an iPhone for months then switching to android.
There are multiple ways you can stop Google Chrome from using too much memory. For instance, you can disable extensions, turn off Hardware Acceleration, etc. For more info Click Here
How can I Prevent This?
There are multiple ways to prevent this. This problem is not caused by one specific reason, there can be multiple Hardware or Software reasons as to why this is happening.
These are the methods you can Follow:
Upgrade your RAM:
RAM is the main problem here, this might not be a software issue you probably just have to upgrade your RAM. PCs can even run on 1GB of RAM but this is not good for multi-tasking or productive work. Memory leaks are possible when you have less amount of RAM, then the usage increases too.
Nowadays 8GB of RAM is more than enough for this type of work. 16GB is the sweet spot for gaming if you want to game.
Anti-virus Scans:
Keep scanning your PC after 1-4 days to check if you have viruses or not. This will keep your PC safe from Memory Leaks and other stuff too. People install Anti-viruses and just forget about them, these are very important software and are made for a reason. Keep your PC safe.
Keep your Drivers Updated:
If you have any of your Drivers not updated, you should definitely update them. Not keeping your Drivers up to date can not only cause Memory Leaks but this can lead to lower fps in games, slow performing PC, PC blacking out, and various other problems.
The graphic card is not going to work at its full potential and you’re not going to have the gaming experience you want.
Disable Startup programs:
Make sure you don’t have any unnecessary programs in the startup menu. These programs can easily cause a Memory Leak without you knowing it.
To check what apps you have enabled at startup:
- Press Ctrl+Shift+Esc
- Click on startup
Here you can see all the apps that can launch when the PC is booted into windows.
- To disable an app just right click on it and press disable