Fix Memory Leak in SharePoint 2013 Preview (Microsoft Office 2013 Component / NodeRunner.exe)

I’ve recently run into performance issues with my new SharePoint 2013 Preview development environment. A quick investigation in Task Manager highlight Memory usage as my issue. The culprit processes are Microsoft Office 2013 component. I see SharePoint 2013 is somehow behind my issue.

image

What are these Microsoft Office 2013 components and why are they consuming so much memory?

Switching to the details tab, these Microsoft Office 2013 components show up as noderunner.exe

image

Now having a bit more to search on I quickly uncovered the TechNet article SharePoint 2013 Preview – Hungry search service

This article attributes the issue to a memory leak in the SharePoint 2013 Preview Search Service.

To apply the fix from this article on the SharePoint 2013 server start the SharePoint 2013 Management Shell and and enter the following command:

Set-SPEnterpriseSearchService –PerformanceLevel Reduced

image

To ensure the setting has been changed enter the following command:

Get-SPEnterpriseSearchService

image

Then you need to edit the noderunner.exe.config file located at:

C:\Program Files\Microsoft Office Servers\15.0\Search\Runtime\1.0\noderunner.exe.config

image

Edit this file (I used Notepad), and locate the line <nodeRunnerSettings memoryLimitMegabytes=”0” />

image

Provide a memory limit for the noderunner process, I set the limit at 250 as shown below.

image

After making these changes I recommend you restart your server. Although I have had no problem with just killing the noderunner.exe processes in Task Manager; SharePoint creates them again almost immediately.

Keep in mind this fix is suggested for SharePoint 2013 Preview only, I’m hoping the bug will be fixed for RTM.

12 thoughts on “Fix Memory Leak in SharePoint 2013 Preview (Microsoft Office 2013 Component / NodeRunner.exe)

Add yours

  1. I did this on with Sharepoint 2013 Preview and search no longer works. I just get a “Nothing here matches your search” message each time now.

    Like

    1. Hi Daniel, thanks for the feedback. I can confirm I am seeing the same issue on a development box that I applied the changes to. Please also see Praveen’s comments. For my development purposes I can live without search working so the fix has allowed me to continue without my development box continually running out of memory. I’m not sure if setting the memory limit higher will resolve the search issue. Please let me know if you find a fix.

      Like

    1. This article regarding the Search Service memory leak and workaround was written for the SharePoint 2013 Preview (beta). Are you looking for a solution for SharePoint 2013 Preview or SharePoint 2013 RTM?

      Like

    1. Hi Avinesh. You observations are correct, if memory usage exceeds the threshold set then you start getting errors in the ULS logs and effectively a broken search. I only recommend making this change on a dev machine to stop it constantly running out of memory (and this recommendation was on SharePoint preview, it should be less of a problem now on a fully patched SharePoint 2013 server). An alternative (and safer way to try and limit the search memory usage is the following PowerShell command:

      Set-SPEnterpriseSearchService -PerformanceLevel Reduced

      For more information on this please see the link below:
      http://www.ashokraja.me/tips/Fixing-Performance-Issue-Caused-By-Node-Runner-In-SharePoint-2013-Preview

      I hope this helps.

      Like

  2. Hi there,

    Finally what’s doing the -PerformanceLevel Reduced command ? Because I barely see a difference of RAM usage. So maybe it’s only reducing the CPU consummation ?
    Thanks on advance for any hint

    Like

    1. Hi Alexandre,

      Performance level determines how many threads search uses. memoryLimitMegabytes setting determines how much memory each search thread can use. So by reducing the number of threads (reduced performance level) you should be reducing the maximum amount of memory available to search.

      Performance Level Explained:

      Reduced: Total number of threads = number of processors, Max Threads/host = number of processors
      PartlyReduced: Total number of threads = 4 times the number of processors , Max Threads/host = 16 times the number of processors
      Maximum: Total number of threads = 4 times the number of processors , Max Threads/host = 16 times the number of processors (threads are created at HIGH priority)

      Like

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Create a website or blog at WordPress.com

Up ↑