This section lists the command line arguments that are used with appcapture.exe to achieve tasks such as starting a capture session, updating an existing application, ending a capture session, and so on, using the command-line capture program.
The following table in this page lists the commands and parameters which can be used with the capture command-line program:
Note:
-
To use the commands and parameters in the earlier format, see App Volumes Administration guide, versions 2503 or earlier, at Omnissa Product Documentation.
-
The command-line arguments for MSIX app attach format cannot be used in the current version of App Volumes. For information about these arguments, see Omnissa App Volumes Administration Guide version 2503 and earlier.
-
When using the
/upgradecodeparameter, either a custom GUID or the UpgradeCode of a native MSI installer is required. To generate a custom GUID, use theNew-GuidPowerShell command./upgradecodeis used with commands such asappcapture.exe startandappcapture.exe packagemsix. For more information about this parameter, see the Options section in the table.
Description of Commands and Parameters
| Command line Argument | Task | Examples |
|---|---|---|
| Actions | ||
| help | This command displays the list of appcapture.exe commands, options, and their descriptions. | |
| start | This command starts a capture session for a new application or updates an existing application.appcapture.exe start /name name_of_the_package /upgradecode custom_GUID | native_MSI_application_installer_pathIf additional parameters such as
| Example: In this example, Notepad++, is the name of the package, captured in the VHD format. Author and description are added as capture details. As /output is not provided, the output files - Notepad++.vhd and Notepad++.json - are generated at this location: C:\ProgramData\Omnissa\AppVolumes\Packages by default.{867CAC46-AFDC-4462-8BE4-1F25861A5C55} is the custom GUID which is set as the app_product_guid property in the Notepad++.json file. For more information about /upgradecode, see the corresponding description in this table. |
| metadata | This command extracts the .json metadata file for the captured application, which can either be a VMDK or VHD application package.appcapture.exe metadata /file "path_of_the_captured_application_package"/file can be either .vmdk or .vhd.By default, the .json file is extracted to the same location as the captured application. If the /output parameter is provided, then the .json file is extracted to the location as specified in the parameter. | Example:In this example, Notepad++.json for the Notepad++.vhd application package is extracted to the path as specified in the /output parameter, which is C:\Users\TestUser\Desktop\Test. |
| convert |
This command converts the format of an application package to another format.
appcapture.exe convert /file "path_of_the_source_application_package" /format [VHD | VMDK | MSI]The application package located at the path specified by the /file parameter is converted to the application package format as mentioned in the /format parameter.This command can also be used to convert an App-V application package to an App Volumes package. For more information about converting an App-V application package, see Convert App-V Application Packages to App Volumes Application Packages. Note: To generate a .vhd application package from a .vmdk application package, which is captured using App Volumes Manager, the .vmdk package must be converted to a monolithic sparse .vmdk and then the appcapture.exe convert command can be used.
|
Examples:
|
| cancel | This command cancels an ongoing capture session.appcapture.exe cancelThe capture session gets canceled and the machine reboots. It is recommended that you revert to a clean snapshot before you start a new capture session. | Example:In this example, the capture session for Notepad++ gets canceled. |
| finalize | This command ends a capture session.appcapture.exe finalizeWhen finalize is used, the machine reboots and the command-line capture program automatically restarts. After the restart, the capture process is complete. If no additional parameters are provided, then the .vhd and .json files are generated by default. .vhd is the application package format and .json is the metadata file. By default, these files are located at: C:\ProgramData\Omnissa\AppVolumes\Packages.
| Example:In this example, Notepad++.vhd and Notepad++.json are generated at C:\ProgramData\Omnissa\AppVolumes\Packages after the capture session completes. |
| resume | This command resumes the command-line capture program after a machine reboot. If you have used the /manualresume parameter at application capture, then you must use this command to resume the program.appcapture.exe resume | Example:In this example, the machine reboots after application capture, but the program does not automatically restart after the reboot as the /manualresume is provided. When the resume command is provided, the program restarts. |
| update | This command uses /upgradecode to add or modify the app_product_guid property of a captured application package. If the package has an existing property, then the newly generated property replaces the existing one.You can also use the /productversion parameter to add or update the product version of the captured application.For information about the /upgradecode parameter, see the corresponding description and examples in this table. |
Examples:
7zip.msi package, which was captured earlier.NPP.vhd package. This property is present in the NPP.json file.7zip.msi App Volumes application package, which was captured earlier.(7z920-x64.msi) is set as the app_product_guid property in the .json file of the 7zip.VHD package. |
| test | This command tests and validates the captured .vhd application package. When this command is used, the program attaches the package to the virtual machine and enables the application bundles in the package for testing.appcapture.exe test /package path_of_the_VHD_packageNote: Before using the test command, you must revert to a clean snapshot, which is different from the one used for application capture.
| Example:In this example, Notepad++.vhd is attached to the virtual machine and enabled for testing. |
| testend | This command ends the test session. If you intend to test and validate another application, then revert to the snapshot taken before you started the test session for this application. | Example: |
| packagereport | This command is used to generate a .json file from which a read-only, HTML package report is generated for an existing application package.The report contains package content such as registry entries, files, and folders detected during packaging. Such information helps in maintaining, updating, and troubleshooting packages. For information about package report, see the About the App Volumes Application Package Report section in Capture an App Volumes Application. appcapture.exe packagereport /file path_of_the_captured_application_package /output report_output/file - indicates the path of the captured package. The captured package can be either VHD or VMDK./output - indicates the location at which the package report files must be generated (package_name.report.html and package_name.report.json). If an output path is not provided, then the files are generated at the same path as the captured package. | Example:In this example, the package report files are generated for emeditor.vhd which is an existing application package. After the command runs, the report files - emeditor.report.html and emeditor.report.json - are generated at C:\Users\localadmin\Desktop. |
| securityscan | This optional command performs a security scan on a VHD application package using Microsoft Defender. When the command runs, a securityscan.bat script is triggered which runs Microsoft Defender and the VHD package is scanned. After the scan finishes, a .json file is generated which contains information such as the time stamp of the scan, scan command, scan result, scan output, path of the VHD package for which the scan is run, volume ID, app ID, and so on. Some of this information is also added to the metadata file (.json) of the captured VHD package in a section called securityscan. appcapture.exe securityscan /path VHD_file_path /output scan_output_json_path/path - indicates path of the captured VHD packageNote: Ensure that the captured .json file is at the same path as the captured VHD package./output - indicates the location at which the scan result (.json) must be generatedThis location can be different from /pathFor the securityscan command to run successfully, it is mandatory to provide the /output parameter.When the same VHD package is scanned subsequently, scan results are overwritten in the .json file. To retain the earlier scan results for the package, a different .json file name can be provided in the /output parameter. However, the metadata file (.json) of the package contains only the latest scan results.Here are some considerations when using this command: Note: Currently, this command can be used only for the Microsoft Defender solution. Note: For information about a failed scan, see the output field in the .json file generated as an output of the securityscan command. Before importing the package to App Volumes Manager, ensure that the scan is successful.A scan summary can be generated on the console for a single file or multiple files (in the same folder) using the /summary parameter. For more information about this parameter, see one of the rows in the Options section of this table.
| Example:In this example, the securityscan command scans Notepad++.vhd and scan results (scannotepad++.json) are generated at the path as specified in the /output parameter. The scan results are also added to the securityscan section of Notepad++.json. |
| packagemsix | This command is used to generate an App Volumes application package for an MSIX application. The MSIX application can be converted to any of the App Volumes package formats: VHD, VHD+MSI, or VMDK. Using this command removes the need for manual steps such as creating and mounting a new VHD and unpacking the MSIX application into the VHD, when generating the package. . Before using the packagemsix command, ensure that you have the following:
The command is as follows: appcapture.exe packagemsix /name AppVolumes_package_name /upgradecode custom_GUID | native_MSI_application_installer_path /source path_of_the_MSIX_application_installer /msixmgr location_of_MSIXManagertool_executable /format AppVolumes_package_formatHere are a few considerations when using the command:
You can deliver the generated package to a Windows endpoint either using App Volumes Manager or a device management tool such as Workspace ONE UEM. To use App Volumes Manager as the delivery mechanism, you must first import the files into App Volumes Manager. If the generated package is a VHD or VMDK, see the What To Do Next section in Capture an App Volumes Application. If the generated package is an MSI, see Deliver App Volumes Applications to Windows Endpoints. | Example:In this example, the MSIXMGR tool is placed at C:\MSIXMGR\x64\msixmgr.exe. After the command runs, the following files Teams.vhd, Teams_workstation.vmdk, Teams.msi, and Teams.json are generated at C:\ProgramData\Omnissa\AppVolumes\Packages.This path C:\MSIXMGR\x64\msixmgr.exe is stored in the MSIXMgrToolPath registry value. |
| Options | ||
| /description | This parameter adds a description for a captured application either during a new capture session or when updating an existing application. When the package is imported to App Volumes Manager, this description can be viewed in the admin UI as part of package description. This parameter is optional. | Example: |
| /format | This parameter can be used to choose the output format of an application package during a new capture session or when converting an already-captured application to a different format. Hence, this parameter can be used with start and convert commands. The output formats can be VHD, VMDK, or MSI.
Note: If this parameter is not provided, then by default, the generated output is in the VHD format. You can use this parameter with the start command in the following ways :
| Example: In this example, the generated Notepad++.vhd format is converted to Notepad++.vmdk and Notepad++.msi formats. Later, the Notepad++.vhd format is deleted. |
| /manualresume | This parameter prevents the command-line capture program from an automatic restart after a machine reboot. The program must be manually restarted after the reboot using the resume command.This parameter is optional and can be used only with the start command.Sometimes during capture completion or application installation, the machine reboots. In either case, the command-line capture program automatically restarts on its own. Sometimes, you might want to perform some custom initialization task and prevent the automatic restart of the program. In such cases, this parameter can be used. After the machine reboots, the resume command must be used to restart the program and complete the capture session. | Examples:
If the machine reboots after application capture, then the program does not automatically restart after the reboot. The resume command must be provided for the program to restart. |
| /noreboot | This optional parameter can be used to prevent the agent machine from rebooting when finalizing an application capture. As a result, the agent machine completes the capture process successfully without undergoing a reboot. If the application getting captured has a requirement for machine reboot during the installation process, this reboot is not affected. Note: This parameter can be used only when capturing an application into VHD format. Using this parameter is optional as skipping the agent machine reboot depends on your packaging requirements. When the parameter is not used, the current behavior continues where the capture machine reboots to complete the packaging process. | Examples:
At the time of finalizing the capture, agent machine does not reboot and the capture process continues to completion. |
| /output | This parameter specifies the location of output files. For example, this parameter can be used when starting a capture session Using this parameter is optional. If this parameter is not provided, then by default, the output files are located at C:\ProgramData\Omnissa\AppVolumes\Packages.Note: This parameter can be used only with the following commands: start,metadata, and convert. | Example: In this example, the Test folder contains Notepad++.vhd and Notepad++.json after the capture session. |
| /prerequisitepackages | This parameter specifies the prerequisite packages required for capturing an application. Any package designated as a prerequisite is delivered and virtualized in the capture virtual machine before the intended application is captured, ensuring that all necessary dependencies are present during the capture process. For a better understanding of the prerquisite packages capability, see Understand the Role of Prerequisite Packages in Application Capture Note:
You can use the parameter with appcapture.exe start in the following ways:
|
|
| /productversion | If the version is missing from the application or needs a correction, this parameter generates or updates the product version for an application.
| Examples:
|
| /source | This parameter updates an existing VHD application package using the .vhd file as the source.This argument is optional. Note: Using this parameter is optional; however, this parameter must not be used when capturing a new application. | Example: In this example, Notepad++_update is the name of the updated package. This name must be different from the name given to the application package captured at first, which is Notepad++.vhd. The command-line capture program uses Notepad++.vhd as the source file to capture the updated package.
|
| /summary | This optional parameter generates a summary of the scan result of a single VHD file or multiple VHD files in the same folder on the console. Scan summary contains the name of the file and scan status (success, failure, and not scanned). For files that are not scanned, the securityscan command must be run again.appcapture.exe securityscan /summary folder path | filepathfolder path - indicates the folder which contains multiple .vhd files Scan summary is displayed for all the files in this folder. file path - file for which the scan summary is generated and displayed | Example: In this example, ScanVHD is the folder that contains multiple VHD files. When this parameter is used, scan results of all the files in the ScanVHD folder are displayed.In this example, the scan result of Notepad++.vhd is displayed as follows: Security scan summary for file.
|
| /upgradecode |
This parameter sets the app_product_guid property for a captured application package. app_product_guid links different versions of the same application together. During application capture, /upgradecode can use a custom GUID or the UpgradeCode of a native MSI installer of the application being captured to generate the app_product_guid property. At the time of application capture:
It is mandatory to use the /upgradecode parameter with the appcapture.exe start command. To add or modify the app_product_guid property of an existing application package, the appcapture.exe update command can be used.Ensure the following:
If the custom GUID is the same as the application GUID of an application in App Volumes Manager, then this package is automatically associated with the existing application after import. |
Examples of using UpgradeCode with the appcapture.exe start and appcapture.exe update commands respectively:
|
Was this page helpful?