none
Public Folders - Setting permission gives System.OutOfMemoryException

    Question

  • Hi,

    when trying to set root access permissions with inheritance on public folder on Exchange 2013 it stops after a while with: Exception of type 'System.OutOfMemoryException' was thrown.

    Public folders size is about 4,5GB and the server have 16 GB RAM with about 20 users, so that should be plenty. 

    What i have noticed is that ISS Worker process frequently grows to about 6-7 GB in memory use under this operation.

    When I check public folders now it has changed permissions on the first 20-25 folders before it stopped.

    Any solution for this?

    Thursday, April 04, 2013 8:59 AM

Answers

All replies

  • Hi ,

    Please check the Memory Usage and ensure if the memory is not enough.

    How to Monitor Memory Usage on an Exchange Server:

    http://technet.microsoft.com/en-us/library/bb123596(v=exchg.65).aspx


    Wendy Liu
    TechNet Community Support

    Monday, April 08, 2013 6:28 AM
  • Added twice as much memory (total of 32 GB) and still the same problem when trying to add root permission on public folders.

    Here is the full error message from the event log:

    Current User: 'S-1-5-21-2704746085-4026986393-3337618981-500'
    Exchange Control Panel detected a failure in the Async web request which hosted in the thread 13.
    The error is System.OutOfMemoryException: Exception of type 'System.OutOfMemoryException' was thrown.
       at System.Linq.Buffer`1..ctor(IEnumerable`1 source)
       at System.Linq.Enumerable.ToArray[TSource](IEnumerable`1 source)
       at Microsoft.Exchange.Management.DDIService.Foreach.Run(DataRow input, DataTable dataTable, DataObjectStore store, Type codeBehind, UpdateTableDelegate updateTableDelegate)
       at Microsoft.Exchange.Management.DDIService.Sequence.Run(DataRow input, DataTable dataTable, DataObjectStore store, Type codeBehind, UpdateTableDelegate updateTableDelegate)
       at Microsoft.Exchange.Management.DDIService.Workflow.Run(DataRow input, DataTable dataTable, DataObjectStore store, Type codeBehind, UpdateTableDelegate updateTableDelegate)
       at Microsoft.Exchange.Management.DDIService.WSSingleObjectDataHandler.ExecuteCore(Workflow workflow)
       at Microsoft.Exchange.Management.DDIService.WSDataHandler.<Execute>b__2()
       at Microsoft.Exchange.Management.ControlPanel.AsyncServiceManager.<>c__DisplayClass4.<InvokeAsyncCore>b__3(Object state)
       at System.Linq.Buffer`1..ctor(IEnumerable`1 source)
       at System.Linq.Enumerable.ToArray[TSource](IEnumerable`1 source)
       at Microsoft.Exchange.Management.DDIService.Foreach.Run(DataRow input, DataTable dataTable, DataObjectStore store, Type codeBehind, UpdateTableDelegate updateTableDelegate)
       at Microsoft.Exchange.Management.DDIService.Sequence.Run(DataRow input, DataTable dataTable, DataObjectStore store, Type codeBehind, UpdateTableDelegate updateTableDelegate)
       at Microsoft.Exchange.Management.DDIService.Workflow.Run(DataRow input, DataTable dataTable, DataObjectStore store, Type codeBehind, UpdateTableDelegate updateTableDelegate)
       at Microsoft.Exchange.Management.DDIService.WSSingleObjectDataHandler.ExecuteCore(Workflow workflow)
       at Microsoft.Exchange.Management.DDIService.WSDataHandler.<Execute>b__2()
       at Microsoft.Exchange.Management.ControlPanel.AsyncServiceManager.<>c__DisplayClass4.<InvokeAsyncCore>b__3(Object state)
    .
    Command: 'SetObject'

    Monday, April 15, 2013 4:38 PM
  • Ended up with taking backup of the public folders, then deleted and recreated the folder. Then adjusted the root permissions with inheritansce and restored the data, everything looks fine now.
    Thursday, April 18, 2013 12:21 PM
  • To fix my issue with setting permissions on Public Folders recursively in Exchange 2013 I used

    "AddUsersToPFRecursive.ps1 -TopPublicFolder "\Sales" -User "David" -Permission Reviewer"

    I found this from a technet article http://technet.microsoft.com/en-us/library/aa998834(v=exchg.141).aspx

    The "AddUsersToPFRecursive.ps1" is a pre written script that comes with Exchange 2013 you can find it in the scripts folder where ever you install Exchange 2013.

    For example "C:\Program Files\Microsoft\Exchange Server\V15\Scripts"

    Wednesday, May 08, 2013 2:21 PM