Delen via


How to Use Optional Packages in Connection Groups

Starting in Microsoft Application Virtualization (App-V) 5.0 SP3, you can add optional packages to your connection groups to simplify connection group management. The following table summarizes the tasks that you can complete more easily by using optional packages, and provides links to instructions for each task.

Note   Optional packages are supported only in App-V 5.0 SP3.

Before using optional packages, see Requirements for using optional packages in connection groups.

Link to instructions Task

Use one connection group, with optional packages, for multiple users who have different packages entitled to them

Use a single connection group to make different groups of applications and plug-ins available to different end users.

For example, you want to distribute Microsoft Office to all end users, but distribute different plug-ins to different subsets of users.

Unpublish or delete an optional package, or unpublish an optional package and republish it later, without changing the connection group

Unpublish, delete, or republish an optional package without having to disable, remove, edit, add, and re-enable the connection group on the App-V Client.

You can also unpublish the optional package and republish it later without having to disable or republish the connection group.

Use one connection group, with optional packages, for multiple users with different packages entitled to them

Task description How to perform the task

With App-V 5.0 SP3

You can add optional packages to connection groups, which enables you to provide different combinations of applications and plug-ins to different end users.

Example: You want to distribute Microsoft Office to your end users, but enable a certain plug-in for only a subset of users.

To do this, create a connection group that contains a package with Office, and another package with Office plug-ins, and then make the plug-ins package optional.

End users who are not entitled to the plug-in package will still be able to run Office.

Method Steps

App-V Server – Management Console

  1. In the Management Console, select PACKAGES to open the PACKAGES page.

  2. Select CONNECTION GROUPS to display the Connection Groups library.

  3. Select the correct connection group from the Connection Groups library.

  4. Click EDIT in the CONNECTED PACKAGES pane.

  5. Select Optional next to the package name.

  6. Select the ADD PACKAGE ACCESS TO GROUP ACCESS check box. This required step adds to the connection group the package entitlements that you configured earlier when you assigned packages to Active Directory groups.

App-V Server - PowerShell cmdlet

Use the following cmdlet, and specify the -Optional parameter:

Add-AppvServerConnectionGroupPackage

Syntax:

Add-AppvServerConnectionGroupPackage [-AppvServerConnectionGroup] <SerializableConnectionGroup> [[-AppvServerPackage] <PackageVersion>] [-Optional] [-Order <int>] [-UseAnyPackageVersion]

Example:

Add-AppvServerConnectionGroupPackage -Name "Connection Group 1" -PackageName "Package 1" -Optional

App-V Client on a Stand-alone computer

  1. Create the connection group XML document, and set the Package tag attribute IsOptional to “true”.

  2. Use the following cmdlets to add and enable the connection group:

    • Add-AppvClientConnectionGroup

    • Enable-AppvClientConnectionGroup

Example connection group XML document with optional packages:

<?xml version="1.0" ?>
<AppConnectionGroup
   xmlns="https://schemas.microsoft.com/appv/2014/virtualapplicationconnectiongroup";
   AppConnectionGroupId="8105CCD5-244B-4BA1-8888-E321E688D2CB"
   VersionId="84CE3797-F1CB-4475-A223-757918929EB4"
   DisplayName="Contoso Software Connection Group" >
<Packages>
<Package
   PackageId="7735d1a8-5ef9-4df9-a1cf-3aa92ef54fe7"
   VersionId="ec560d6f-e62e-48eb-a9e5-7c52a8c2e149"
   DisplayName="Contoso Business Manager"
/>

<Package PackageId="fc6fe0f7-be3d-4643-b37d-fc3f62d4dd5c" VersionId="c67a71cd-3542-4a48-93e8-20c643c50970" DisplayName="Contoso Forms" IsOptional="false" />

<Package PackageId="8f6301a5-4348-4039-9560-b27a5bb72711" VersionId="6c694b45-3e19-46c6-a327-d159aa39e1d2" DisplayName="Contoso Tax" IsOptional="true" />

<Package PackageId="89d701bc-d507-4299-b6b6-000000003472" VersionId="*" DisplayName="Contoso Accounts" IsOptional="true" />

</Packages> </AppConnectionGroup>

 

With versions earlier than App-V 5.0 SP3

You had to create many connection groups to make specific application and plug-in combinations available to specific users.

Unpublish or delete an optional package, or unpublish an optional package and republish it later, without changing the connection group

Task description How to perform the task

With App-V 5.0 SP3

You can unpublish, delete, or republish an optional package, which is in a connection group, without having to disable or re-enable the connection group on the App-V Client.

You can also unpublish an optional package and republish it later without having to disable or republish the connection group.

Example: If you publish an optional package that contains a Microsoft Office plug-in, and you want to remove the plug-in, you can unpublish the package without having to disable the connection group.

Method Steps

App-V Server – Management Console

  • To unpublish the package: In the Management Console, select elect the PACKAGES page, right-click the package that you want to unpublish, and click unpublish.

  • To remove an optional package from a connection group: On the CONNECTION GROUPS page, select the package that you want to remove, and click the right arrow to remove the package from the connection group pane on the bottom left.

App-V Client on a Stand-alone computer

Use the following existing cmdlets:

  • Unpublish-AppvClientPackage

  • Remove-AppvClientPackage

For more information, see How to Manage App-V 5.0 Packages Running on a Stand-Alone Computer by Using PowerShell.

 

With versions earlier than App-V 5.0 SP3

You had to:

  1. Remove the connection group from each App-V Client computer where it was enabled.

  2. Unpublish the package.

  3. Remove the package from the connection group’s definition.

  4. Republish the connection group.

Requirements for using optional packages in connection groups

Review the following requirements before using optional packages in connection groups:

Requirement Details

Connection groups must contain at least one non-optional package.

  • Check carefully that you meet this requirement, as the App-V Server and the PowerShell cmdlet don’t validate that the requirement has been met.

  • If you accidentally create a connection group that does not contain at least one non-optional package, and the end user tries to open a packaged application in that connection group, the connection group will fail.

  • User-published connection groups can contain packages that are published globally or to the user.

  • Globally published connection groups must contain only globally published packages.

Globally published connection groups must contain packages that are published globally to ensure that the packages will be available when starting the connection group’s virtual environment.

If you try to add or enable globally published connection groups that contain user-published packages, the connection group will fail.

You must publish all non-optional packages before publishing the connection group that contains those packages.

A connection group’s virtual environment cannot start if any non-optional packages are missing.

The App-V Client fails to add or enable a connection group if any non-optional packages have not been published.

Before you unpublish a globally published package, ensure that the connection groups that are entitled to all the users on that computer no longer require the package.

The system does not check whether the package is part of another user’s connection group. Unpublishing a global package will make it unavailable to every user on that computer, so make sure that each user’s connection groups no longer contain the package, or alternatively make the package optional.

Managing Connection Groups