Mastering MSI: Customize Installation Locations on Windows Server for Optimal Deployment

Table of Contents

Deploying software across an enterprise network can be a complex undertaking, especially when managing numerous applications and ensuring their seamless installation on client machines. Microsoft Installer (MSI) packages, combined with Group Policy Objects (GPOs), offer a robust framework for automated software distribution in Windows Server environments. However, administrators often encounter specific challenges that require advanced manipulation beyond the standard graphical user interface. This article delves into methods for customizing MSI installation locations and configuring multiple UNC paths within a Software Deployment GPO, optimizing your deployment strategy.

GPO software deployment process

Understanding Group Policy Software Deployment

Group Policy Objects are fundamental tools for managing user and computer settings in Active Directory domains. When it comes to software deployment, GPOs allow administrators to assign or publish applications to users or computers, ensuring consistent software availability and installation. The process typically involves creating a shared network location (a Distribution Point) where MSI packages reside and then linking this share within a GPO.

The standard GPO console provides a straightforward way to specify a single Universal Naming Convention (UNC) path for an MSI package. This works well for simple deployments where the software distribution point remains static. However, real-world scenarios often demand greater flexibility, such as migrating a distribution share or enhancing redundancy for critical applications.

Common Deployment Scenarios and Challenges

Two primary scenarios highlight the limitations of the default GPO interface and necessitate a more intricate approach:

Scenario 1: Relocating an Existing MSI Package. Imagine you have an MSI package deployed via GPO, and for various reasons—perhaps server migration, storage consolidation, or network optimization—you need to change its UNC path. Simply updating the GPO path through the graphical interface for an already deployed package typically leads to a re-deployment. This means clients that have already installed the software will attempt to reinstall it, potentially causing disruptions, consuming bandwidth, and increasing administrative overhead. The goal is to update the path seamlessly without triggering a complete reinstallation.

Scenario 2: Configuring Multiple UNC Paths for an MSI Package. For critical applications or geographically dispersed organizations, having a single point of failure for software distribution is undesirable. You might want to provide multiple, redundant UNC paths for the same MSI package to ensure high availability and improve download speeds by directing clients to the nearest distribution point. Unfortunately, the standard GPO GUI allows you to specify only one package location at a time, making it challenging to implement a robust, fault-tolerant deployment strategy.

These scenarios underscore the need for a deeper understanding of how GPO software deployment information is stored within Active Directory and how to directly manipulate these underlying properties.

Advanced GPO Configuration with ADSI Edit

To overcome the limitations of the standard GPO interface, administrators can leverage ADSI Edit (Active Directory Service Interfaces Editor). ADSI Edit is a powerful, low-level tool that allows direct viewing and modification of objects and attributes in Active Directory. While incredibly versatile, it requires caution and a thorough understanding of Active Directory schema and object properties, as incorrect modifications can have severe consequences for your domain.

The Role of ADSI Edit in GPO Management

When you configure software deployment settings within a GPO, this information isn’t just stored in a file on a SYSVOL share; it’s also represented as objects and attributes within Active Directory. Specifically, the details about deployed MSI packages, including their UNC paths, are stored as properties of package objects tied to the GPO’s unique identifier (GUID or CLSID). ADSI Edit provides the direct interface to access and modify these properties.

Before proceeding, it’s crucial to ensure you have appropriate administrative permissions and, ideally, perform these operations in a controlled test environment first. Always have a recent backup of your Active Directory.

Step-by-Step Guide to Modifying MSI Package Locations

The following steps detail how to modify the UNC path of an MSI package or add multiple paths using ADSI Edit, addressing both scenarios outlined earlier.

Step 1: Identify the GPO and Package Object CLSID

First, you need to pinpoint the specific GPO that defines your MSI package deployment and then extract the unique identifier (CLSID) associated with that package object.

  1. Open the Group Policy Management Console (GPMC) on a domain controller or a management workstation with RSAT tools installed.
  2. Navigate to the GPO that contains the MSI package you wish to modify.
  3. Expand the GPO, then navigate to Computer Configuration (or User Configuration) -> Policies -> Software Settings -> Software Installation.
  4. Right-click on the specific MSI package you want to modify and select Properties.
  5. Go to the Deployment tab and click the Advanced button.
  6. Observe the Script Name field. You will see a path that looks something like \\<DomainName>\SysVol\<DomainName>\Policies\{<GPO_GUID>}\Machine\Applications\{<Package_CLSID>}. The alphanumeric string directly after \Applications\ (i.e., the {<Package_CLSID>}) is the unique identifier for your software package object. Make a careful note of this CLSID.

The CLSID is a globally unique identifier that serves as a unique address for the software package definition within the GPO’s structure in Active Directory. It’s essential for locating the correct object in ADSI Edit.

Step 2: Connecting to Your Domain with ADSI Edit

Now, with the CLSID in hand, you can open ADSI Edit and connect to your domain.

  1. Open ADSI Edit. You can typically find it by typing adsiedit.msc in the Run dialog or searching for it in Administrative Tools.
  2. In ADSI Edit, right-click on ADSI Edit in the left pane and select Connect to....
  3. In the Connection Settings dialog box, select Default naming context from the Select a well known Naming Context dropdown. This will automatically connect you to your domain’s naming context.
  4. Click OK to establish the connection.

A successful connection will display your domain’s naming context (e.g., DC=yourdomain,DC=com) in the left pane. This is where the core of your Active Directory objects resides.

ADSI Edit connect to domain

Step 3: Navigating to the Package Object in Active Directory

The software deployment information for GPOs is stored in a specific hierarchical structure within Active Directory. You will navigate this structure using the CLSID noted earlier.

  1. Expand your domain’s naming context in the left pane (e.g., DC=yourdomain,DC=com).
  2. Expand the CN=System container. This container holds system-level objects and configurations, including Group Policy objects.
  3. Within CN=System, expand CN=Policies. This is where all the GPO objects are stored, each identified by its unique GUID (which is the GPO’s GUID, not the package’s CLSID).
  4. Locate and expand the GPO object whose GUID matches the one you noted from the Script Name path in GPMC (the one just before \Machine\Applications\{<Package_CLSID>}).
  5. Once inside the specific GPO’s container, navigate through the following path:
    • Expand CN=Machine (or CN=User if it’s a user-assigned package). This node represents the computer-specific (or user-specific) settings within the GPO.
    • Expand CN=Class Store. This container holds information about software packages deployed through Group Policy.
    • Expand CN=Packages. This final container lists the individual software package definitions.
  6. Within CN=Packages, you should find an object whose CN (Common Name) is the CLSID of your MSI package that you noted in Step 1. Right-click on this object and select Properties.

This hierarchical path ensures you are modifying the precise software package definition associated with the correct Group Policy Object.

Step 4: Modifying the msiFileList Property

The critical property that defines the UNC path(s) for your MSI package is msiFileList. This is a multi-valued attribute, meaning it can store more than one entry, which is key for configuring multiple distribution points.

  1. In the Properties dialog for the package object, scroll down to find the msiFileList property.
  2. Select msiFileList and click Edit.
  3. The Value Editor dialog will display the current UNC path(s). Each path is prefixed with a number and a colon (e.g., 0:\\server\share\package.msi).

    • To change an existing path (Scenario 1): Select the old path (e.g., 0:\\oldserver\share\package.msi), click Remove, then in the Value(s) to add box, type your new path prefixed with 0: (e.g., 0:\\newserver\share\package.msi) and click Add.
    • To add multiple paths (Scenario 2): In the Value(s) to add box, type each additional UNC path, ensuring each is prefixed with a unique sequential number followed by a colon (e.g., 1:\\server2\share\package.msi, 2:\\server3\share\package.msi). Click Add after each entry. It is good practice to keep the primary path as 0:.

    Important Note: The numbering (0:, 1:, 2:, etc.) is crucial. Active Directory uses these prefixes to order and identify the multiple UNC paths associated with the package. Ensure each path has a unique, sequential number.

  4. After making your modifications, click OK to close the Value Editor, and then OK again to close the Properties dialog.

The UNC path for the Package Object has now been updated or expanded to reflect the new or multiple UNC paths.

ADSI Edit msiFileList property

Example msiFileList Property Content

Here’s a conceptual representation of how the msiFileList property might look before and after modifications:

Before Modification (Single Path):

Index Value
0 0:\\server1\software\app.msi

After Modification (Multiple Paths for Redundancy):

Index Value
0 0:\\server1\software\app.msi
1 1:\\server2\software\app.msi
2 2:\\server3\software\app.msi

This table illustrates how the msiFileList attribute holds a collection of strings, each representing a distinct distribution point. The client machines will attempt to access these paths in the order they are listed (typically, starting from 0:) or based on Active Directory site costing if configured.

mermaid graph TD A[Start] --> B{Identify GPO and Package CLSID}; B --> C[Open GPMC]; C --> D[Navigate to Software Installation]; D --> E[Package Properties]; E --> F[Deployment Tab & Advanced]; F --> G[Note Package CLSID]; G --> H{Open ADSI Edit}; H --> I[Connect to Domain]; I --> J[Navigate to CN=System\CN=Policies\{GPO_GUID}\CN=Machine\CN=Class Store\CN=Packages\{Package_CLSID}]; J --> K[Right-click Package Object & Properties]; K --> L[Locate 'msiFileList' property]; L --> M{Edit 'msiFileList'}; M --> N{Scenario 1: Change Path}; N --> O[Remove Old, Add New with 0: Prefix]; M --> P{Scenario 2: Add Multiple Paths}; P --> Q[Add New Paths with Sequential Prefixes (1:, 2: etc.)]; O --> R[Confirm Changes & Close ADSI Edit]; Q --> R; R --> S[Force GPO Update on Clients]; S --> T[Verify Deployment]; T --> U[End];

Post-Modification and Best Practices

Once you have modified the msiFileList property using ADSI Edit, there are several crucial steps to ensure the changes propagate effectively and that your deployment remains stable.

Forcing Group Policy Update and Replication

Changes made directly in Active Directory (like those via ADSI Edit) require time to replicate across all domain controllers. While replication typically occurs quickly in a well-configured environment, you might need to force it for immediate effect or for testing purposes.

  1. Active Directory Replication: On a domain controller, you can use repadmin /syncall to force replication across your site or domain.
  2. Client-Side Group Policy Update: Client machines will not immediately recognize the change until their Group Policy settings are refreshed.
    • You can wait for the regular background refresh interval (typically 90-120 minutes for computers).
    • To force an immediate update on client machines, use the gpupdate /force command. This can be run remotely via PowerShell or other management tools for multiple machines. This command forces clients to download the latest Group Policy settings from a domain controller.

Testing and Verification

Thorough testing is paramount after making direct modifications to Active Directory objects.

  1. Pilot Deployment: Before rolling out to your entire environment, test the updated GPO on a small group of pilot machines.
  2. Verify New Installations: For new machines or machines that haven’t received the software yet, ensure they successfully install the application from the new or multiple specified UNC paths.
  3. Monitor Existing Installations: For machines that already have the software (in Scenario 1, where you changed the path), verify that the GPO update does not trigger an unwanted reinstallation. The change in msiFileList should only update the deployment information, not force a re-execution of the installation logic.
  4. Event Viewer: On client machines, check the Event Viewer (specifically, Windows Logs -> System and Applications and Services Logs -> Microsoft -> Windows -> GroupPolicy -> Operational) for any errors or warnings related to software installation or Group Policy processing.

Best Practices for Software Deployment via GPO

Beyond manipulating msiFileList, adhere to general best practices for robust MSI deployment:

  • Centralized Distribution Points: Maintain dedicated file servers for software distribution. Ensure these shares have appropriate NTFS and share permissions (read access for Authenticated Users or specific security groups that need to install the software).
  • Permissions: Verify that the “read” permissions are correctly set on your new or existing distribution shares for the computers or users that will be receiving the software. Lack of proper permissions is a common cause of deployment failures.
  • Network Connectivity: Ensure reliable network connectivity between client machines and the distribution points. For remote offices, consider implementing local distribution points or using technologies like BranchCache.
  • MSI Transforms (MST files): For customizing MSI installations (e.g., specifying installation directories, license keys, or feature selections), always use MST files instead of directly modifying the MSI. GPOs support applying MST files alongside the MSI package.
  • Version Control: When updating software, create new GPO packages or use the “Upgrade” feature within the existing GPO to manage different versions gracefully. Avoid reusing the same package definition for different software versions without proper upgrade rules.
  • Documentation: Maintain clear documentation of your GPOs, including the MSI packages deployed, their paths, and any customizations made via ADSI Edit or MST files. This is invaluable for troubleshooting and future management.
  • Group Policy Caching: Be aware that client machines cache GPO information. While gpupdate /force refreshes settings, in some rare cases, it might take a restart for certain policy changes to take full effect, especially those related to system startup.

By meticulously following these advanced configuration steps and adhering to best practices, you can effectively manage MSI package locations on Windows Server, ensuring optimal, reliable, and flexible software deployment across your enterprise. This proactive approach helps mitigate potential issues, reduces administrative burden, and provides a more robust infrastructure for your organization’s software needs.


Do you have experience with customizing MSI deployment locations using ADSI Edit? Share your insights, tips, or any challenges you’ve encountered in the comments section below! Your experiences can help others optimize their deployment strategies.

Post a Comment