powershellscripts.com

Tutorials  PowerShell Cmdlet Help for Export-VApp



NAME
Export-VApp

SYNOPSIS
Exports a virtual appliance to the provided destination.

SYNTAX
Export-VApp [[-Destination] ] [-VApp] [-Name ] [-Force] [-Format ] [-Cr
eateSeparateFolder] [-Description ] [-Server ] [-RunAsync] [-WhatIf] [-Confirm] [ ers>]


DESCRIPTION
Exports a virtual appliance to the provided destination. If no destination is specified, the cmdlet creates a new f
older in the current working directory and exports the virtual appliance to it. The name of the new folder is the s
ame as the name of the virtual appliance as it appears in vCenter Server.


PARAMETERS
-Destination
Specify a destination path to the file system location where you want to export the virtual appliances. If the
value of the Destination parameter is a folder, the virtual appliance is exported to a container folder (OVF).
If the destination is a file, the virtual appliance is exported in OVA format.

Required? false
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false

-VApp
Specify the virtual appliance you want to export.

Required? true
Position? 2
Default value
Accept pipeline input? true (ByValue)
Accept wildcard characters? true

-Name
Specify a name for the exported virtual appliances.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false

-Force
Indicate whether the cmdlet overwrites the existing destination files and creates directories to complete the s
pecified file path.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false

-Format
Specify the file format of the specified virtual appliance. The default format is OVF. The valid values are OVF
and OVA.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false

-CreateSeparateFolder
Indicate that you want to create a separate folder for each virtual appliance.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false

-Description
Provide a description of the exported virtual appliance.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false

-Server
Specify the vSphere servers on which you want to run the cmdlet. If no value is given to this parameter, the co
mmand runs on the default servers. For more information about default servers, see the description of Connect-V
IServer.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? true

-RunAsync
Indicate that the command returns immediately without waiting for the task to complete. In this mode, the outpu
t of the cmdlet is a Task object. For more information about the -RunAsync parameter run " help About_RunAsync"
in the vSphere PowerCLI console.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false

-WhatIf
Indicate that the cmdlet is run only to display the changes that would be made and actually no objects are modi
fied.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false

-Confirm
If the value is $true, indicates that the cmdlet asks for confirmation before running. If the value is $false,
the cmdlet runs without asking for user confirmation.

Required? false
Position? named
Default value $true
Accept pipeline input? false
Accept wildcard characters? false


This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer and OutVariable. For more information, type,
"get-help about_commonparameters".

INPUTS



OUTPUTS
FileInfo


NOTES




-------------- Example 1 --------------

C:\PS>Get-VApp VApp* | Export-VApp "c:\vapps\"


Retrieves all virtual appliances whose names start with "VApp" and exports them to the specified path.





-------------- Example 2 --------------

C:\PS>Export-VApp "c:\NewFolder\" $vApp -Name "EMail_vApp" -Force


Exports the virtual appliances in the $vApp variable to the specified location and assigns a name to the folder.





-------------- Example 3 --------------

C:\PS>Export-VApp -vApp $vApp -Destination "c:\vapps\Vapp\" -Force -CreateSeparateFolder:$false


Exports the virtual appliances in the $vApp variable to the specified location without creating a separate folder f
or each virtual appliance.





-------------- Example 4 --------------

C:\PS>Export-VApp -vApp $vApp -Destination "c:\vapps\myVapp\" -Format Ova


Exports a virtual appliance to an Ova file.






RELATED LINKS
Online version: http://www.vmware.com/support/developer/PowerCLI/PowerCLI501/html/Export-VApp.html
Get-VApp
Import-VApp
New-VApp
Remove-VApp
Set-VApp
Start-VApp
Stop-VApp
Move-VApp