Previous Topic: repositionItem—Reorder Jobs Assigned to Unsealed Local Software PolicyNext Topic: unlink—Unlink Software Policy from Computer Group


link—Link Software Policy to Computer Group

This action links or re-links a software policy to an existing computer group. The computer group can be local or global. The software policy has to be unsealed otherwise the action will abort with error. For re-linking a policy either the option “currentGroup” or the option “replace” has to be coded with the call otherwise the re-linking will fail.

The software policy has to be unsealed but of any scope. The latter also halts for the computer group to which the policy is linked.

With the link action the policy can optionally be sealed.

The syntax of the action is as follows:

swPolicy	action=link
name=software_policy_name
[swpScope={distributed | local}]
group=computer_group_name
[groupScope={global | local}]
[{currentGroup=current_computer_group_name
[currentGroupScope={global | local}]| replace}]
[seal[={y|n}]]
name

The name of the software policy that is linked to the specified computer group.

swpScope

This option determines the type of software policy involved in the action.

«not coded»

If there is a locally created software policy of the required name then this one is taken, if not it is looked for a policy distributed from an enterprise manager. The latter is on domain managers only.

distributed

The specified software policy has to be a policy created at the enterprise manager and distributed to the addressed manager.

local

The specified software policy has to be a locally created policy.

Note: On enterprise manager all software policies have to be of type local.

group

This option specifies the name of an existing computer group to which the software policy specified will be assigned.

groupScope

This option specifies the type of group to which the software policy will be assigned.

global

The computer group has been created at the enterprise manager and maybe replicated to the domain.

local

The computer group has been created at the domain manager.

On enterprise managers all computer groups are global.

If the option is not coded the CADSMCMD first tries to locate the group as a local group and if this fails it looks for a global one.

currentGroup

This option specifies the name of a computer group the software policy is already linked to. If it is coded this link between the current group and the software policy will be removed and replaced by a link between the software policy and the new target computer group.

currentGroupScope

This option specifies the type of group the software policy is already linked to:

global

The computer group has been created at the enterprise manager and maybe replicated to the domain.

local

The computer group has been created at the domain manager.

On enterprise managers all computer groups are global.

If the option is not coded the CADSMCMD first tries to locate the group as a local group and if this fails it looks for a global one.

replace

If this option is specified then the specified group is linked to the specified software policy regardless of another group already being linked to the policy.

seal

If “seal” or “seal=y” is coded then the policy is sealed after the linkage has been completed otherwise it remains unsealed for further modifications. The seal is only performed when the linkage has been successful and no error has been reported. Warnings do not suppress the seal.

Note: If neither the replace option nor the currentGroup option is specified then the action will fail with an error if there is a group already linked to the software policy.