1.2 Packaging-Snapshot Method

Commercial off-the-shelf applications require combinations of file system and registry entries. To facilitate virtualization of these applications, ZENworks Application Virtualization Studio can take a snapshot of the application installations and automatically configure them based on modifications made to the host system during setup.

1.2.1 Machine Configuration

Make sure the machine you are using is configured to provide the best environment for taking the snapshot.

Perform the Snapshot on a Clean Machine

Performing the snapshot on a clean machine ensures that all dependencies are installed by the application setup. Installing on a machine with existing components can inadvertently include dependencies in the before snapshot and exclude them from the final output.

Use the Snapshot with Whole-Machine Virtualization

If you configure a clean machine by using whole-machine virtualization tools, such as VMware Workstation or Microsoft Virtual PC and then save a before snapshot based on this image, you can snapshot many distinct virtual applications in rapid succession by reverting the machine to the whole-machine virtual state and using the same before snapshot.

Take the Snapshot on the Earliest Variant of the Target Operating System

Most applications can be configured by performing the snapshot on the earliest (least common denominator) target operating system. For example, if an application functions on both Windows XP and Windows 7, perform the first snapshot on Windows XP. If specific configuration is required for later versions of operating systems, such as Windows 7, these can be captured separately and merged into the application by using the platform merge functionality.

1.2.2 Snapshot Process

Use the following best practices as you capture the snapshot and prepare it for virtualization.

Use the Proper Build Procedure

Capture the before snapshot on a clean machine. Install the application and any necessary dependencies/components. If necessary, perform a custom installation to include or exclude items from the build. When the installation is complete, perform the Capture and Diff snapshot. Edit the configuration file to remove unnecessary registry keys, files, and folders. Set the desired isolation settings. Finally, build and test the application.

Saving the Capture and Diff Snapshot

When you select a folder to save the Capture and Diff snapshot, select Make New Folder in ZENworks Application Virtualization Studio. This folder is not included in the snapshot. If the folder is included in the Capture and Diff snapshot, remove it by using the Filesystem tab.

Saving Before Pruning

Before beginning the pruning process, save a backup of the Capture and Diff snapshot (snapshot.xappl) in the same directory as the Files folder. Revert to the original Capture and Diff snapshot if there is an error.

Running the Native Application to Determine Isolation Characteristics

Run and use the native application to understand what registry keys and folders it updates at runtime. There are many free tools available that can help you track registry changes. This process lets you determine the proper isolation settings for folders and registry keys.

Setting a Folder as Fully Isolated or Merged

To determine if a folder should be set to full isolation or merge isolation, decide if the user would want access to files created within that folder, outside the virtual application environment. Set the folder to merge to allow users to access files, or set it to full to keep the folder isolated.

Removing Uninstall Shortcuts

There are two steps to removing uninstall shortcuts during the pruning process:

  1. If uninstall files have been created by the installation, these need to be removed from the file section and also from the multiple section, where triggers are defined.

  2. Remove the shortcut from the list of startup files; if a shortcut exists, select Multiple, then delete any uninstall files.

Removing Logs

When the application is ready for the final build, make sure to deselect the Generate Diagnostic-Mode executable check box. Otherwise logs are created every time the virtual application runs.

Testing Isolation

Complete the following steps to verify that a virtual application does not create unnecessary files outside of the sandbox:

  1. Take a before snapshot on a clean machine and run the virtual application.

  2. Use the virtual application as an actual user.

  3. Close the virtual application and take the Capture and Diff snapshot. Verify that there are no unintentional files or folders created outside the sandbox, within the Filesystem and Registry tab. If such files or folders exist, edit xappl to set the files and folders to Full Isolation and then retest for fixing isolation issues.