Running the 'ReadFragmentationResults' stored procedure

book

Article ID: 100013897

calendar_today

Updated On:

Description

Notes

Resolution

Use the following command in the SQL query window to get the fragmentation details:
USE [EnterpriseVaultDirectory]
GO
 
DECLARE @AvgFragFilter AS smallint
 
SELECT @AvgFragFilter = [Threshold]
FROM [dbo].[Monitoring]
WHERE [MonitoringItemType] = 34
                AND [SiteEntryId] = ''
 
USE
 
EXEC [dbo].[ReadFragmentationResults] @AvgFragFilter
GO
where,
is the name of the Directory, Vault Store or Fingerprint database for which to get the fragmentation results.
is the Entry ID of the Enterprise Vault Site to read current fragmentation threshold.
 
Examples:
o    To run the stored procedure on ‘EnterpriseVaultDirectory’ database using the default average fragmentation % filter value:
 
USE [EnterpriseVaultDirectory]
 
EXEC [dbo].[ReadFragmentationResults]
GO
 
o    To run the stored procedure of Vault Store database named ‘EVVSExpressVaultStore_1’ associated with the Enterprise Vault Site having SiteEntryId as '1529582D4F8AEA04496E4208654CE90A11d10000MW-2K8R2-x64-2-A', and by using the already configured average fragmentation % filter value for that Site:
 
USE [EnterpriseVaultDirectory]
GO
 
DECLARE @AvgFragFilter AS smallint
 
SELECT @AvgFragFilter = [Threshold]
FROM [dbo].[Monitoring]
WHERE [MonitoringItemType] = 34
        AND [SiteEntryId] = '1529582D4F8AEA04496E4208654CE90A11d10000MW-2K8R2-x64-2-A'
 
USE [EVVSExpressVaultStore_1]
 
EXEC [dbo].[ReadFragmentationResults] @AvgFragFilter
GO

 

 

 

Issue/Introduction

The 'ReadFragmentationResults' stored procedure enables you to determine which tables and indexes are fragmented. This stored procedure is present in the Directory, Vault Store, and Fingerprint databases. It accepts an optional 'smallint' parameter (which is an average fragmentation % filter). The fragmentation results returned by the stored procedure are filtered out based on this value. When you do not pass any filter value the stored procedure uses a default value of 30 for filtering the results.