The transition to NetApp MS Azure AD B2C is complete. If you missed the pre-registration, you will be invited to reigister at next log in.
Please note that access to your NetApp data may take up to 1 hour.
To learn more, read the FAQ and watch the video.
Need assistance? Complete this form and select “Registration Issue” as the Feedback Category.

ONTAP Discussions

no vserver option in New-NcSnapshotPolicy cmdlet?

djwarner2929

I'm trying to automate creating snapshot policies with Powershell.  It looks like the New-NcSnapshotPolicy cmdlet doesn't have a vserver option.  So when I run it, all policies are created under the cluster vserver.  The cli command of snapshot policy create has the vserver option.  Any ideas why I can't do the same with Powershell?  I have toolkit 4.1 with CDOT of 8.3.1.  Thanks.

 

Dave

2 REPLIES 2

Jeff_Yao

hi, 

 

try the help command to check the syntax... 

masson

Hello,

 

I'm agree with

 

This options is not available event with the last PSTK 4.0.0.231

Here the help of the cmdlet:

NAME
    New-NcSnapshotPolicy

SYNOPSIS
    Create a new snapshot scheduling policy.


SYNTAX
    New-NcSnapshotPolicy [-Name] <String> [-Schedule] <String> [-Count] <Int32> [-Prefix <String>] [-Enabled [<Boolean>]] [-Comment <String>]
    [-SnapmirrorLabel <String>] [-Controller <NcController[]>] [-PipelineVariable <String>] [-ZapiRetryCount <Int32>] [<CommonParameters>]


DESCRIPTION
    Create a new snapshot scheduling policy.


PARAMETERS
    -Name <String>
        The name of the snapshot scheduling policy which has to be created.  This cmdlet creates a snapshot policy and adds a schedule to it.
        The maximum length of this string is 256 characters.

    -Schedule <String>
        First schedule to be added inside the policy.  At least one schedule has to be added to create a policy.

    -Count <Int32>
        Retention count for the snapshots created by the first schedule.  The count of all the snapshots to be retained for this policy cannot
        be more than 255.

    -Prefix <String>
        Snapshot name prefix for the first schedule.  Prefix name should be unique within the policy.

    -Enabled [<Boolean>]
        Status of the snapshot policy indicating whether the policy will be enabled or disabled.  If set to true, the policy will be enabled.

    -Comment <String>
        A human readable description associated with the snapshot policy.  The maximum length of this field can be 255 characters.

    -SnapmirrorLabel <String>
        Label for SnapMirror Operations. Maximum length of this field is 31 characters.

    -Controller <NcController[]>
        A clustered Data ONTAP controller to receive this cmdlet, as embodied by an NcController object.  This parameter is returned by the
        Connect-NcController cmdlet.  If not specified, the value in the global variable CurrentNcController is used.  In the latter case, if
        CurrentNcController contains a collection of NcController objects, this cmdlet is invoked on each controller in succession.

    -PipelineVariable <String>


    -ZapiRetryCount <Int32>


    <CommonParameters>
        This cmdlet supports the common parameters: Verbose, Debug,
        ErrorAction, ErrorVariable, WarningAction, WarningVariable,
        OutBuffer, PipelineVariable, and OutVariable. For more information, see
        about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).

 

Is there any chance to see this option in the futur?

 

TIA

 

Regards

Announcements
NetApp on Discord Image

We're on Discord, are you?

Live Chat, Watch Parties, and More!

Explore Banner

Meet Explore, NetApp’s digital sales platform

Engage digitally throughout the sales process, from product discovery to configuration, and handle all your post-purchase needs.

NetApp Insights to Action
I2A Banner
Public