Stop NodeRunner RAM Drain in SharePoint: 5-Min Fix

C
Collab365 TeamAuthorPublished May 12, 2016
2

At a Glance

Target Audience
SharePoint Administrators
Problem Solved
NodeRunner.exe unlimited RAM consumption leading to server performance degradation in SharePoint 2013.
Use Case
Tuning SharePoint 2013 search components on memory-constrained servers.

Most sysadmins treat server memory leaks like a pest control problem. They open Task Manager, find the process eating 90% of the RAM, and kill it.

It never works. You cannot just terminate core services and expect your environment to stay stable.

If you are running SharePoint 2013, you have probably stared at NodeRunner.exe dominating your resource monitor. Your server is crawling. Your users are complaining. But before you force-quit those processes, you need to understand what they actually do.

NodeRunner is not a rogue application. It is the core Microsoft SharePoint Search Component managed by the SharePoint Search Host Controller Service.

When you look at your task manager, you will see multiple instances of it. That is by design. Each independent process hosts one of six critical search components:

  • Crawl
  • Content Processing
  • Index
  • Analytics
  • Query Processing
  • Search Administration

The problem is not the service itself. The problem is the default configuration.

Out of the box, Microsoft gave this executable a blank check. If you open the configuration file, you will find this exact line: <nodeRunnerSettings memoryLimitMegabytes="0" />. That zero means the process has unlimited access to your RAM. It will consume everything you give it until the server chokes.

You do not need a massive hardware upgrade to fix this. You just need to set boundaries.

Here is the exact process to stop the memory leak and cap the resource drain. It takes five minutes.

1. Throttle the Performance Level
Open your SharePoint PowerShell window. You need to tell the search service to stop running at maximum capacity. Run this command:
Set-SPEnterpriseSearchService -PerformanceLevel Reduced

2. Cap the Memory Limit
Navigate to the search runtime directory at C:\Program Files\Microsoft Office Servers\15.0\Search\Runtime\1.0.
Open noderunner.exe.config in a text editor.
Find the memory limit node and change the value from 0 to a hard cap like 250.
It should look like this: <nodeRunnerSettings memoryLimitMegabytes="250" />

3. Restart the Service
Open your services console and restart the "SharePoint Search Host Controller" service.

That is it. No magic tricks. It is just a simple configuration change that forces your tools to respect your infrastructure.

You can read more about the original context here.