New-FsrmAutoQuota

Creates an auto apply quota.

Syntax

New-FsrmAutoQuota
   [-Path] <String>
   [-AsJob]
   [-CimSession <CimSession[]>]
   [-Disabled]
   [-Template <String>]
   [-ThrottleLimit <Int32>]
   [-Confirm]
   [-WhatIf]

Description

The New-FsrmAutoQuota cmdlet creates an auto apply quota. By using auto apply quotas, you can assign a quota template to a parent volume or folder. File Server Resource Manager (FSRM) automatically generates quotas that are based on that template. The server generates quotas for each of the existing subfolders and for subfolders that you create in the future.

You can verify all automatically generated quotas by using the Get-FsrmAutoQuota cmdlet. Get-FsrmAutoQuota returns an individual quota for each subfolder and the auto apply quota profile in the parent volume or folder.

Examples

Example 1: Create an auto apply quota on a folder

PS C:\>New-FsrmAutoQuota -Path "C:\Shares\CtrShare03" -Template "250 MB Extended Limit"

This command creates an auto apply quota on the folder named C:\Shares\CtrShare03. The server generates quotas based on the "250 MB Extended Limit" template for each of the existing subfolders in C:\Shares\CtrShare03 and for subfolders that you create in C:\Shares\CtrShare03.

Example 2: Create an inactive auto apply quota

PS C:\>New-FsrmAutoQuota -Path "C:\Shares\CtrShare03" -Template "100 MB Limit" -Disabled

This command creates an auto apply quota on the folder C:\Shares\CtrShare03 and applies the "100 MB Limit" template to the quota. The command disables the auto apply quota, which means that the server does not generate quotas for subfolders in C:\Shares\CtrShare03.

Parameters

-AsJob

ps_cimcommon_asjob

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-CimSession

Runs the cmdlet in a remote session or on a remote computer. Enter a computer name or a session object, such as the output of a New-CimSessionhttp://go.microsoft.com/fwlink/p/?LinkId=227967 or Get-CimSessionhttp://go.microsoft.com/fwlink/p/?LinkId=227966 cmdlet. The default is the current session on the local computer.

Type:CimSession[]
Aliases:Session
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Position:Named
Default value:False
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Disabled

Indicates that the server does not track quota data for the quota and does not run any action associated with quota thresholds.

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-Path

Specifies a valid local path to a folder. The server applies the auto apply quota to each of the subfolders (current and future) in this folder.

Type:String
Position:2
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:True

-Template

Specifies a name of a quota template on the server.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-ThrottleLimit

Specifies the maximum number of concurrent operations that can be established to run the cmdlet. If this parameter is omitted or a value of 0 is entered, then Windows PowerShell® calculates an optimum throttle limit for the cmdlet based on the number of CIM cmdlets that are running on the computer. The throttle limit applies only to the current cmdlet, not to the session or to the computer.

Type:Int32
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type:SwitchParameter
Position:Named
Default value:False
Required:False
Accept pipeline input:False
Accept wildcard characters:False