Windows Search EDB file very large on Server 2012 R2 RDS


  • Hello experts. 

    We have hundreds of users on 2012 R2 RDS session host servers and have a non-stop problem with the Windows Search .edb file growing extremely large and filling up all disk space. 

    This looks to be a major problem for IT departments everywhere, based on a few seconds of searching around. 

    The main items we have in place to try and combat this problem:

    1.) We have enabled the "DisableSearchBackoff" and added the Corecount registry key found in this post:

    2.) We have a batch file that runs the commands found below on a nightly basis, which defragments the search index database.

    3.) We have moved the index from C volume to dedicated drives. 

    The problem is, no matter how much space we add, the files just keep growing. Is the only resolution to add a massive volume to each session host for this file to grow as large as it wants? I have seen many threads on various forums where people have reached out to Microsoft support on multiple occasions for this issue and the work around is to rebuild or defrag the database. I know there are lots of these threads out there but I'm curious if anyone has found a solution yet. Thanks in advance. 

    Rabu, 06 April 2016 13.32


Semua Balasan

  • Hi,

    1. Have you opened a case with Microsoft CSS to let them know you are experiencing this issue, and to ask about a hotfix for 2012 R2?  This is key to let them know that the fix needs to be made for 2012 R2.

    2. What is you primary reason or reason(s) for using Windows Search?  For example, is it for search features within Outlook, or searching within files, both, something else?

    3. How do you have things configured right now in terms of Outlook version, ost setting (# of months), profile configuration, etc.?

    As an aside, I don't think there is any benefit in your case to defragging the index each night.


    Rabu, 06 April 2016 15.09
  • Hi TP

    1.) I have not opened a case with Microsoft, but will do so today. 

    2.) We started out with no search service, but we had many complaints from users in regards to searching their emails in Outlook, and when searching for documents in Windows Explorer. So, we added Windows Search to all RDS session hosts. So, both within Outlook and files in explorer. To add to this, all users have Folder Redirection configured and their Documents all reside on a file server. The file server does not have the .EDB issues that the session hosts do. I also have most file extensions disabled accept for anything associated with Outlook or Office, so I assume the massive file is mainly due to .OST files.  

    3.) All users have Outlook (Office 2013 x86) configured in Cached Exchange mode with a 1 month limit. 

    Rabu, 06 April 2016 15.16
  • Hi,

    Kindly post into the forum if there are any progresses made with Microsoft CSS.

    Thank you in advance!

    Best Regards,


    Please remember to mark the replies as answers if they help and un-mark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact

    Jumat, 08 April 2016 06.30
  • Microsoft support said there is no fix for this. They say Windows Search is not supported or recommended on enterprise servers. They recommend implementing Windows Search Server 2010. Obviously that is not a valid solution, so for now we will just have to tell people "sorry". 

    Sabtu, 23 April 2016 11.53
  • Hi,

    Sorry about inconvenience caused by the issue, and thank you for updating this thread with Microsoft statement!

    Best Regards,


    Please remember to mark the replies as answers if they help and un-mark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact

    Senin, 25 April 2016 01.03
  • Wow?!

    It seems that for Windows 2012 there is a patch KB2836988. But if I understand, there isn't any for Windows 2012 R2.

    If so, really not happy.

    Selasa, 09 Januari 2018 15.37
  • Agreed that if there's a fix in WS2012 for this, it's a disappointing discovery to find that there's no fix for WS2012R2. 

    Another interesting item to add to this thread - one of my team raised a support case under our Premier Support agreement on this and pointed to statements found online about Search Indexing and RDS not being supported roles to have coexisting and was told unequivocally that it is a supported scenario.  I quote:

    Win 2012 R2 OS version with RDS role installed does support windows index search, the article you found is not Microsoft official document and we didn’t find any official document stating windows index is not supported on RDS server. Besides we should have the expectation that the size of the index DB on a terminal server is bigger than the one on a normal server; the normal situation is the size of this DB should be increased gradually day by day instead of increased suddenly and finally it will stay on a fixed size then increase gradually and stably.

    Premier case ID = 118020717608246 for anyone @ Microsoft who may be watching this thread, or if anyone dealing with Microsoft via CSS case wants to point their tech at our case for comparison. 

    As well as sharing that nugget, I wanted to seek further information from other users experiencing this issue.  Our customer that is dealing with this seems to run fine all week with the EDB creeping up in size to ~10 GB and then on Wednesday something happens to trigger explosive growth and all the (70GB) available space on the volume gets consumed by the ever-growing EDB file.  I'm starting to question them about once-per-week activity like payroll runs or similar that could be a trigger with a view to perhaps excluding enough filetypes from indexing to prevent this coming back every Wednesday.  Has anyone had success with that general approach? 

    One other possible direction we may end up taking is to bring forward plans for this customer to move in the direction of  WS 2016 RDS host.  I dislike the "maybe you should try upgrading to the latest version and see if the problem goes away" troubleshooting approach, but I also dislike having this recurring problem in an important part of one of my customer's infrastructure.  Is there anyone out there that has already been down this path?  If there are any "We did it and it is definitely better" or "We did it and there's still a problem" stories to be shared, I'll appreciate hearing about them. 


    Selasa, 20 Maret 2018 22.51
  • I am having the exact same issue with the database growing. i never noticed it before but on one server it is currently 28GB. i monitor to see if it grows in a week. i am wondering if having folder redirection is a cause. i only enable it on the RDS because it was on the network with older hardware. i enabled search for Outlook and file sharing. its unfortunate that we as techs have to go through all this aggravation while the heads at MS continue to rake in the millions. 
    Selasa, 24 April 2018 19.12
  • The same situation here. I have Server 2012 with RDS users and Outlook 2016... Windows search can't run normally more than approx. 50 days. My EDB file can be greater than 200GB!!! AND I MUST SAY: KB2836988 DOESN'T SOLVE THIS BEHAVIOUR! Another symptom: indexing FREEZES from time to time. But when you reboot the server, it can run normally more than 30 days and the situation repeats. Indexing freezes or EDB file consume whole free space on the disk.

    SAD SAD SAD...

    Kamis, 12 Juli 2018 13.19
  • We have succumbed to implementing a workaround for this due to a lack of assistance from Microsoft Support. To get around this we implemented a regular check to ensure the size of the EDB file hasn't exceeded a specific value. If the specified value is exceeded it stops the Windows Search service, deletes the file and starts the service again. 

    Powershell as below. Just edit the first line to how large you want to allow the file to grow to:

    $MaxSizeInGB = '50'
    $getservice = Get-service "wsearch" -ErrorAction SilentlyContinue
    if($getservice.Status -eq "running"){
    $CurrentLoc = Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows Search\" -name DataDirectory
    $File =  Get-item -path "$($CurrentLoc.DataDirectory)\Applications\Windows\windows.edb"
    $FileSize =   [math]::truncate($file.length / 1GB)
    if($FileSize -gt $MaxSizeInGB){
    $result = 1
    $searchHealth = "SearchDB is $($filesize)GB - An automated Search Index rebuild is being run."
    Stop-Service Wsearch
    remove-item $CurrentLoc.DataDirectory -force -Recurse
    Start-Service Wsearch
    if (!$searchHealth) {$searchHealth = "Healthy"}
    if (!$result){$result = 0}
    write-output $result
    This can be run from a scheduled task. In our case we are running hourly and remotely from our managed services tool. 

    Kamis, 06 September 2018 22.57