en-US/about_FSRMQuotaAction.help.txt

.NAME
    FSRMQuotaAction
 
# Description
    
    This resource is used to configure Quota Actions for Quotas in File
    Server Resource Manager.
     
.PARAMETER Path
    Key - string
    The path of the FSRM Quota the action applies to.
 
.PARAMETER Percentage
    Key - uint32
    This is the threshold percentage the action is attached to.
 
.PARAMETER Type
    Key - string
    Allowed values: Email, Event, Command, Report
    The type of FSRM Action.
 
.PARAMETER Ensure
    Write - String
    Allowed values: Present, Absent
    Specifies whether the FSRM Action should exist.
 
.PARAMETER Subject
    Write - string
    The subject of the e-mail sent. Required when Type is Email.
 
.PARAMETER Body
    Write - string
    The body text of the e-mail or event. Required when Type is Email or Event.
 
.PARAMETER MailTo
    Write - string
    The mail to of the e-mail sent. Required when Type is Email.
 
.PARAMETER MailCC
    Write - string
    The mail CC of the e-mail sent. Required when Type is Email.
 
.PARAMETER MailBCC
    Write - string
    The mail BCC of the e-mail sent. Required when Type is Email.
 
.PARAMETER EventType
    Write - string
    Allowed values: None, Information, Warning, Error
    The type of event created. Required when Type is Event.
 
.PARAMETER Command
    Write - string
    The Command to execute. Required when Type is Command.
 
.PARAMETER CommandParameters
    Write - string
    The Command Parameters. Required when Type is Command.
 
.PARAMETER KillTimeOut
    Write - sint32
    Int containing kill timeout of the command. Required when Type is Command.
 
.PARAMETER RunLimitInterval
    Write - sint32
    Int containing the run limit interval of the command. Required when Type is Command.
 
.PARAMETER SecurityLevel
    Write - string
    Allowed values: None, LocalService, NetworkService, LocalSystem
    The security level the command runs under. Required when Type is Command.
 
.PARAMETER ShouldLogError
    Write - boolean
    Boolean specifying if command errors should be logged. Required when Type is Command.
 
.PARAMETER WorkingDirectory
    Write - string
    The working directory of the command. Required when Type is Command.
 
.PARAMETER ReportTypes
    Write - string
    Array of Reports to create. Required when Type is Report.
 

    .EXAMPLE
        This configuration will assign an FSRM Quota to the path 'D:\Users', with a Hard Limit
        of 5GB and threshold percentages of 85 and 100. An e-mail action is bound to each threshold.
        An event action is also bound to the 85 percent threshold.

Configuration Example
{
    param
    (
        [Parameter()]
        [System.String[]]
        $NodeName = 'localhost'
    )

    Import-DscResource -Module FSRMDsc

    Node $NodeName
    {
        FSRMQuota DUsers
        {
            Path = 'd:\Users'
            Description = '5 GB Hard Limit'
            Ensure = 'Present'
            Size = 5GB
            SoftLimit = $false
            ThresholdPercentages = @( 85, 100 )
        } # End of FSRMQuota Resource

        FSRMQuotaAction DUsersEmail85
        {
            Path = 'd:\Users'
            Percentage = 85
            Ensure = 'Present'
            Type = 'Email'
            Subject = '[Quota Threshold]% quota threshold exceeded'
            Body = 'User [Source Io Owner] has exceed the [Quota Threshold]% quota threshold for quota on [Quota Path] on server [Server]. The quota limit is [Quota Limit MB] MB and the current usage is [Quota Used MB] MB ([Quota Used Percent]% of limit).'
            MailBCC = ''
            MailCC = 'fileserveradmins@contoso.com'
            MailTo = '[Source Io Owner Email]'
            DependsOn = "[FSRMQuota]DUsers"
        } # End of FSRMQuotaAction Resource

        FSRMQuotaAction DUsersEvent85
        {
            Path = 'd:\Users'
            Percentage = 85
            Ensure = 'Present'
            Type = 'Event'
            Body = 'User [Source Io Owner] has exceed the [Quota Threshold]% quota threshold for quota on [Quota Path] on server [Server]. The quota limit is [Quota Limit MB] MB and the current usage is [Quota Used MB] MB ([Quota Used Percent]% of limit).'
            EventType = 'Warning'
            DependsOn = "[FSRMQuota]DUsers"
        } # End of FSRMQuotaAction Resource

        FSRMQuotaAction DUsersEmail100
        {
            Path = 'd:\Users'
            Percentage = 100
            Ensure = 'Present'
            Type = 'Email'
            Subject = '[Quota Threshold]% quota threshold exceeded'
            Body = 'User [Source Io Owner] has exceed the [Quota Threshold]% quota threshold for quota on [Quota Path] on server [Server]. The quota limit is [Quota Limit MB] MB and the current usage is [Quota Used MB] MB ([Quota Used Percent]% of limit).'
            MailBCC = ''
            MailCC = 'fileserveradmins@contoso.com'
            MailTo = '[Source Io Owner Email]'
            DependsOn = "[FSRMQuota]DUsers"
        } # End of FSRMQuotaAction Resource
    } # End of Node
} # End of Configuration
 

    .EXAMPLE
        This configuration will assign the '100 MB Limit' template to the path 'D:\Users'.
        It will also force the quota assigned to this path to exactly match the '100 MB Limit'
        template. Any changes to the thresholds or actions on the quota assigned to this path
        will cause the template to be removed and reapplied.

Configuration Example
{
    param
    (
        [Parameter()]
        [System.String[]]
        $NodeName = 'localhost'
    )

    Import-DscResource -Module FSRMDsc

    Node $NodeName
    {
        FSRMQuota DUsers
        {
            Path = 'd:\Users'
            Description = '100 MB Limit'
            Ensure = 'Present'
            Template = '100 MB Limit'
            MatchesTemplate = $true
        } # End of FSRMQuota Resource
    } # End of Node
} # End of Configuration