Help with large Windows.edb file

Matthew D. Jones 26 Reputation points
2021-02-05T21:29:43.547+00:00

I've been running into a few users who have very large (over 30gb) EDB files in Windows 10. While going in and deleting them is providing temporary relief of their issues it's just not a viable long term solution. These users don't have another drive to copy the file to. I need to get to the bottom of what they have on their systems that is causing this to balloon.

I've noticed the GatherLogs Crwl and gthr files. Can anyone tell me what the data in these files represent and if there is anything I can analyze within that would help me make a better curtailed indexing criteria to keep these files down? I'm fairly convinced that these problems are potentially coming from a handful of applications that may be causing an indexing issue.

Thank you!

Windows 10
Windows 10
A Microsoft operating system that runs on personal computers and tablets.
11,857 questions
0 comments No comments
{count} vote

Accepted answer
  1. MotoX80 34,761 Reputation points
    2021-02-08T13:42:45.237+00:00

    I need to create a better indexing criteria to keep the size of the file manageable.

    Open the indexing options and see how many items are indexed and their locations.

    65423-capture.jpg

    Here is a Powershell script that I hacked together from various examples. It lists the file names that are indexed. Save this as a .ps1 file.

    # use this query to see all items.   
    $query = "SELECT System.ItemName, system.ItemPathDisplay, System.ItemTypeText,  System.Size FROM SystemIndex"   
    # use this query to search on a word  
    #$query = "SELECT System.ItemName, system.ItemPathDisplay, System.ItemTypeText,  System.Size FROM SystemIndex  where contains('kawasaki')"  
      
    $objConnection = New-Object -ComObject adodb.connection  
    $objrecordset = New-Object -ComObject adodb.recordset  
    $objConnection.commandtimeout = 30000  
    $objconnection.open( "Provider=Search.CollatorDSO;Extended Properties='Application=Windows';")  
    $objrecordset.open($query, $objConnection)  
    $i = 0  
    Try { $objrecordset.MoveFirst() }  
    Catch [system.exception] { "no records returned";return }  
    do   
    {  
        $i = $i + 1  
        $typ = ($objrecordset.Fields.Item("System.ITemTypeText")).value   
     $fn = ($objrecordset.Fields.Item("System.ItemPathDisplay")).value  
        "$i -  $typ - $fn"  
        $size = ($objrecordset.Fields.Item("System.Size")).value   
     $in = ($objrecordset.Fields.Item("System.ItemName")).value  
        "       $size - $in"  
      
        if(-not($objrecordset.EOF))   
        {  
            $objrecordset.MoveNext()     
        }  
    } Until ($objrecordset.EOF)  
      
    "Record count $i"  
      
    $objrecordset.Close()  
    $objConnection.Close()  
    $objrecordset = $null  
    $objConnection = $null  
      
    

    Set the Powershell window to this height and width and run the script. It will start outputting file names.

    As it's scrolling, if you see something interesting, like the same folder name over and over, you can click inside the window to pause the scrolling. Then hit escape to restart the scrolling.

    65424-capture1.jpg

    Click on the Modify button and remove folders from indexing that you do need to be indexed.

    1 person found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. S.Sengupta 20,641 Reputation points MVP
    2021-02-06T03:09:49.393+00:00

    You can check the current size of the Windows.edb file with the following PowerShell command:

    ((Get-Item $env:programdata'\Microsoft\Search\Data\Applications\Windows\Windows.edb').length/1GB)

    You can move to another location:

    Control Panel -> Indexing Options -> Advanced -> Index location-> New Location, specify the path to the new location of Windows.edb file and click Ok.

    Also Run the built-in Windows 10 Search and Indexing Troubleshooter


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.