Tuesday, March 19, 2024

Configure / Finetune the Microsoft Exchange search / indexing feature

Abstract: Sometimes there is a urgent need to fine tune a server feature. For example if you are dealing with a low CPU/RAM issue on MS Exchange and need to solve that as soon as possible. So to solve these kind of resource issues you wish to Configure the Microsoft Exchange search / indexing feature so that it didn´t need so much CPU/RAM.

At first you might try to disable the content indexing as written here, however this caused the following issue:

Attempt to move active database 'EXCHMB1-EG-3GB' from exch02.int.contoso.com to exch01.int.contoso.com failed. Move comment: None specified.(Preference)

Error: An Active Manager operation failed. Error: The database action failed. Error: An error occurred while trying to validate the specified database copy for possible activation. Error:

        exch01:
        Database copy 'EXCHMB1-EG-3GB' on server 'exch01' has content index catalog files in the following state: 'Disabled'. If you need to activate this database copy, you can use the Move-ActiveMailboxDatabase cmdlet with the -SkipClientExperienceChecks parameter to forcibly activate the database.       

 So your next attempt is to “fine tune” that, but there is only less information available what can be done. So I decided to write this small howto, which explains some possible options.

 

1.) Disable some File formats indexed by Exchange Search

Per default the Microsoft Exchange Search (FAST search) index a wide range of file formats (as seen here) which can be checked via:

Get-SearchDocumentFormat

If you for example wish to disable the indexing from JPG and GIF files (as every email might contain such elements in a signature) you can run the following (you need to run the Exchange Powershell via “run as admin”):

Set-SearchDocumentFormat -Identity “GIF” -Enabled $false
Set-SearchDocumentFormat -Identity “JPEG” -Enabled $false

Some companies might also wish to disable the indexing from ZIP files, to avoid performance issues in there environment due to large ZIP attachments or to close a possible vulnerability (with malware in compressed ZIP files) via

Set-SearchDocumentFormat -Identity “ZIP” -Enabled $false

This is a per server configuration. You need to login into the server and need to perform the change directly on the server where you wish to disable the file format.

After the change restart the Exchange Search Host Controller service and Microsoft Exchange Search service on the server where you implemented the changes or better reboot the whole server.

 

2.) Change the maximum size file that can be indexed by Exchange Server

By default, the maximum size file that can be indexed by Exchange Server 2013 on-premises is 32 MB. To increase this size limit, you must add the following registry key on all CAS and multi-role servers in your organization (as written here). To change the maximal attachment size which will be indexed to 40 MB change the key to 40. Example

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\ExchangeServer\v15\Search\SystemParameters]
"MaxAttachmentSize"=dword:00000040

After the change restart the Exchange Search Host Controller service and Microsoft Exchange Search service on the server where you implemented the changes or better reboot the whole server.

 

3.) Other Registry options:

The TechEd Session EXL332 “Exchange Server 2013 Tips and Tricks” here and “Search in Exchange 2013” here lists the following additional and possible options:

HKLM\Software\Microsoft\ExchangeServer\v15\Search\SystemParameters
MaxAttachmentCount (default is 10)
MaxAttachmentDepth (default is 2)
ProcessImages (default is 0)
MarkSkippedImagesAsPartiallyProcessed (default is 0)

After the change restart the Exchange Search Host Controller service and Microsoft Exchange Search service on the server where you implemented the changes or better reboot the whole server.

 

4.) Adjust the Processor Affinity Percentage

The Microsoft technet forum mentioned the CtsProcessorAffinityPercentage registry key here, which can be used.

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\ExchangeServer\v15\Search\SystemParameters]
"CtsProcessorAffinityPercentage"=dword:00000040

CTS seamed to stand for “Content Transformation Services”

After the change restart the Exchange Search Host Controller service and Microsoft Exchange Search service on the server where you implemented the changes or better reboot the whole server.

 

5.) Adjust the allocated memory

The KB 3094698 list a method how the allocated memory could be controlled. To do that you need to change the Noderunner.exe.config file.

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

b.) Edit the Noderunner.exe.config file, and then locate the following key:

<nodeRunnerSettings memoryLimitMegabytes=”<value>” />

c.) Change it to the memory limit you need. But keep noted that this might cause issues on Exchange as explained in KB 3094698 if you do not enter a propper value which fits your needs.

d.) Restart the Microsoft Exchange Host Controller Service.

 

6.) Disable the content indexing for a special DB:

Note: doing that inside an MS Exchange DAG might cause issues with the automatically load balancing from the DBs!

Set-MailboxDatabase “DEXCHMB1” -IndexEnabled $false

If you wish to re-enable it you can use the following:

Set-MailboxDatabase “DEXCHMB1” -IndexEnabled $true

 

Monitoring:

Note: You can monitor the Search indexer via:

\MSExchange Search Indexer\Number of Databases Being Crawled
\MSExchange Search Indexer\Number of Databases Being Indexed
\MSExchange Search Indices(*)\Document Indexing Rate
\MSExchange Search Indices(*)\Full Crawl Mode Status
\MSExchange Search Indices(*)\Number of Mailboxes Left to Crawl
\MSExchange Search Indices(*)\Number of Outstanding Batches

 

Related Articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Stay Connected

35FollowersFollow
- Advertisement -

Latest Articles