ChangeSwAssignment

Change software assignment

Related Topics Link IconRelated Topics

Definition

Use this command to set the execution mode for a package's policy instance or software set or for canceling pending executions. These changes are applied during the current Installer session, if possible.
This command is also useful if you want to make sure that a specific package is also installed on a computer when executing another package on that computer.

Instead of specifying a package, you can also specify a software tag. In this case the system includes all packages that have the same software tag (package property).

The command leads to the following behavior:

  • Standard Policies
    Provided that there is a policy for the respective computer or user, the command changes the execution mode of the policy instance. If there is no policy instance available for an Installation (even if the policy is valid), the system creates one.
  • Shop Policies
    Provided that there is a shop policy for the respective computer or user, the command either creates the corresponding policy instance (in case of an Installation) or changes the execution mode of the available policy instance.

Example:

A software package gets assigned with a shop policy. While the system is executing an eScript, a dialog pops up telling the end user that the installation can be aborted (ExitProc (Undone).
The end user selects the software to be installed from the Software Shop and the policy's execution mode is therefore set to Installation. When the Installer starts installing the software during its next run, it issues the information to the end user. If the end user aborts the installation (see above), the Installation execution mode still remains, which means that the package will be installed again each time the Installer is running.
You can prevent this from happening by running the command ChangeSWAssignment with the Uninstallation execution mode.

Settings

Execution Modes

The following execution modes are available:

  • Installation
  • Reinstallation
  • Repair
  • Update
  • Uninstallation

The availability of these execution modes is independent of whether the respective package supports them or not.
If you select Reinstallation, for example, and the package does not support reinstallation, the Installer uninstalls the package first and installs it afterward.
If there is no way the Installer can reach its goal, the compliance status is set to Not possible.

In some cases it may be useful to select multiple execution modes.
Example:
A package must be installed with the current revision. Depending on the status of the package on the managed computer, several execution modes may be applicable (Installation, Reinstallation, Update).
In this case, we recommend selecting all of the applicable execution modes. DSM automatically uses the right mode when executing the command.

The execution mode Cancel aborts specific actions that are currently running.
These include:

  • Reinstallation
  • Repair

If the running actions, such as installation or uninstallation, have not been executed yet (Compliance pending, active execution mode = Installation/Uninstallation), you can undo them by specifying the 'reverse' execution mode.

Options

  • Ignore end user execution restrictions
    If you select this option, the system does not consider the modes the end user is allowed to execute; these restrictions are ignored.
    If you deselect this option, the system only executes the modes the end user is allowed to execute in the Software Shop.
  • Apply to Job-Policies only
    Select this option to determine whether the command handles job policies or standard policies. Use this command, for example, to set a job to 'reinstall'.
  • Ignore automatic policies
    Select this option to exclude automatic policies from being executed.
  • Ignore non-automatic policies
    Select this option to exclude automatic policies (i.e. Shop policies) from being executed.

Use the last two options if you want to uninstall only Shop policies, for example, without uninstalling other 'standard' policies at the same time.