CLI cookbook: creating a policy
This will outline how to create a policy in the CLI, please note that you can also do this in the GUI.
Procedure
-
ssh into your Delphix Engine using admin credentials.
Copyssh admin@delphixengine
delphix > ls -
Go to
policies
andcreateAndApply
(please note that you cannot just create a policy, you mustcreateAndApply
, in the GUI you have the option to just create) and set your policy parameter.Copydelphix > policy
delphix policy > createAndApply
delphix policy createAndApply *> set policy.type=< choose from QuotaPolicy, RefreshPolicy, RetentionPolicy, SnapshotPolicy or SyncPolicy)
delphix policy createAndApply *> set policy.name=< name your policy>delphix policy createAndApply *> set policy.customized=true
delphix policy createAndApply *> set policy.
delphix policy createAndApply *> set policy.provisionSource=(LATEST_SNAPSHOT or LATEST_TIME_FLOW_LOG)If you create aRefreshPolicy, SyncPolicy
orSnapshotPolicy
, also add the following:Copydelphix policy createAndApply *> edit policy.scheduleList
delphix policy createAndApply policy.scheduleList * > add
delphix policy createAndApply policy.scheduleList * > set cronString=
delphix policy createAndApply policy.scheduleList * > set cutoffTime=
delphix policy createAndApply policy.scheduleList * > back -
Set your target parameters which are going to be a container, group etc.
Copydelphix policy createAndApply *> set target=
-
Verify and
commit.
Copydelphix policy createAndApply *> ls
delphix policy createAndApply *> commit