MSSQL 2016: DB ファイルの空き領域の合計

Microsoft.SQLServer.2016.DBFileSizeMonitorType (UnitMonitorType)

Element properties:

RunAsDefault
AccessibilityInternal
Support Monitor RecalculateFalse

Member Modules:

ID Module Type TypeId RunAs 
DS DataSource Microsoft.SQLServer.2016.DBFileSizeRawProvider Default
CDOverThreshold1UnderThreshold2 ConditionDetection System.ExpressionFilter Default
CDOverThreshold2 ConditionDetection System.ExpressionFilter Default
CDUnderThreshold1 ConditionDetection System.ExpressionFilter Default

Overrideable Parameters:

IDParameterTypeSelectorDisplay NameDescription
IntervalSecondsint$Config/IntervalSeconds$間隔 (秒)ワークフローを実行する定期的な実行間隔 (秒)。
SyncTimestring$Config/SyncTime$同期時刻24 時間形式で指定した同期時刻。省略可能です。
Threshold1double$Config/Threshold1$重大のしきい値モニターは、値がこのしきい値を下回ると状態を重大に変更します。このしきい値と警告しきい値 (両方のしきい値を含む) の間にあると、モニターは警告状態になります。
Threshold2double$Config/Threshold2$警告しきい値モニターは、値がこのしきい値を下回ると状態を警告に変更します。
TimeoutSecondsint$Config/TimeoutSeconds$タイムアウト (秒)ワークフローが終了して失敗とマークされるまでの、ワークフローの許容実行時間を指定します。
AzureMaxFileSizeMBint$Config/AzureMaxFileSizeMB$Azure 最大ファイル サイズ (MB)Azure BLOB Storage に保存されているデータ ファイルの最大サイズ。ワークフローはこの値をファイルごとの最大記憶域容量と見なします。

Source Code:

<UnitMonitorType ID="Microsoft.SQLServer.2016.DBFileSizeMonitorType" Accessibility="Internal">
<MonitorTypeStates>
<MonitorTypeState ID="UnderThreshold1"/>
<MonitorTypeState ID="OverThreshold1UnderThreshold2"/>
<MonitorTypeState ID="OverThreshold2"/>
</MonitorTypeStates>
<Configuration>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="IntervalSeconds" type="xsd:integer"/>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="SyncTime" type="xsd:string"/>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="ConnectionString" type="xsd:string"/>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="ServerName" type="xsd:string"/>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="SqlInstanceName" type="xsd:string"/>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="DatabaseName" type="xsd:string"/>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="DBFileId" type="xsd:string"/>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="Threshold1" type="xsd:double"/>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="Threshold2" type="xsd:double"/>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="TimeoutSeconds" type="xsd:int"/>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="AzureMaxFileSizeMB" type="xsd:int"/>
</Configuration>
<OverrideableParameters>
<OverrideableParameter ID="IntervalSeconds" ParameterType="int" Selector="$Config/IntervalSeconds$"/>
<OverrideableParameter ID="SyncTime" ParameterType="string" Selector="$Config/SyncTime$"/>
<OverrideableParameter ID="Threshold1" ParameterType="double" Selector="$Config/Threshold1$"/>
<OverrideableParameter ID="Threshold2" ParameterType="double" Selector="$Config/Threshold2$"/>
<OverrideableParameter ID="TimeoutSeconds" ParameterType="int" Selector="$Config/TimeoutSeconds$"/>
<OverrideableParameter ID="AzureMaxFileSizeMB" ParameterType="int" Selector="$Config/AzureMaxFileSizeMB$"/>
</OverrideableParameters>
<MonitorImplementation>
<MemberModules>
<DataSource ID="DS" TypeID="Microsoft.SQLServer.2016.DBFileSizeRawProvider">
<IntervalSeconds>$Config/IntervalSeconds$</IntervalSeconds>
<SyncTime>$Config/SyncTime$</SyncTime>
<ConnectionString>$Config/ConnectionString$</ConnectionString>
<ServerName>$Config/ServerName$</ServerName>
<SqlInstanceName>$Config/SqlInstanceName$</SqlInstanceName>
<DatabaseName>$Config/DatabaseName$</DatabaseName>
<DBFileId>$Config/DBFileId$</DBFileId>
<TimeoutSeconds>$Config/TimeoutSeconds$</TimeoutSeconds>
<AzureMaxFileSizeMB>$Config/AzureMaxFileSizeMB$</AzureMaxFileSizeMB>
</DataSource>
<ConditionDetection ID="CDUnderThreshold1" TypeID="System!System.ExpressionFilter">
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Double">Property[@Name='FreeSpacePercent']</XPathQuery>
</ValueExpression>
<Operator>Less</Operator>
<ValueExpression>
<Value Type="Double">$Config/Threshold1$</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</ConditionDetection>
<ConditionDetection ID="CDOverThreshold1UnderThreshold2" TypeID="System!System.ExpressionFilter">
<Expression>
<And>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Double">Property[@Name='FreeSpacePercent']</XPathQuery>
</ValueExpression>
<Operator>GreaterEqual</Operator>
<ValueExpression>
<Value Type="Double">$Config/Threshold1$</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Double">Property[@Name='FreeSpacePercent']</XPathQuery>
</ValueExpression>
<Operator>LessEqual</Operator>
<ValueExpression>
<Value Type="Double">$Config/Threshold2$</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</And>
</Expression>
</ConditionDetection>
<ConditionDetection ID="CDOverThreshold2" TypeID="System!System.ExpressionFilter">
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Double">Property[@Name='FreeSpacePercent']</XPathQuery>
</ValueExpression>
<Operator>Greater</Operator>
<ValueExpression>
<Value Type="Double">$Config/Threshold2$</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</ConditionDetection>
</MemberModules>
<RegularDetections>
<RegularDetection MonitorTypeStateID="UnderThreshold1">
<Node ID="CDUnderThreshold1">
<Node ID="DS"/>
</Node>
</RegularDetection>
<RegularDetection MonitorTypeStateID="OverThreshold1UnderThreshold2">
<Node ID="CDOverThreshold1UnderThreshold2">
<Node ID="DS"/>
</Node>
</RegularDetection>
<RegularDetection MonitorTypeStateID="OverThreshold2">
<Node ID="CDOverThreshold2">
<Node ID="DS"/>
</Node>
</RegularDetection>
</RegularDetections>
</MonitorImplementation>
</UnitMonitorType>