Copy-ContentLibraryItem
This cmdlet copies content library items to a local content library.
Syntax
-ContentLibraryItem
<ContentLibraryItem[]>
-Destination <LocalContentLibrary>
[-Name <String>]
[-Notes <String>]
[-Server <VIServer[]>]
[CommonParameters]
-Destination <LocalContentLibrary>
[-Name <String>]
[-Notes <String>]
[-Server <VIServer[]>]
[CommonParameters]
Parameters
Required | Parameter Name | Type | Position | Features | Description |
---|---|---|---|---|---|
required |
|
ContentLibraryItem[] | named |
|
Specifies the content library item that you want to copy. | required |
|
LocalContentLibrary | named |
|
Specifies the local content library where you want to copy the item. | optional |
|
String | named |
|
Specifies the name on the library item. Library item names cannot be undefined or an empty string. Names do not have to be unique. Note: If not specified, the name of the source content library item will be used. | optional |
|
String | named |
|
Specifies a human-readable description for the content library item that you want to copy. | optional |
|
VIServer[] | named |
|
Specifies the vCenter Server systems on which you want to run the cmdlet. If no value is provided or $null value is passed to this parameter, the command runs on the default servers. For more information about default servers, see the description of the Connect-VIServer cmdlet. |
Output
VMware.VimAutomation.ViCore.Types.V1.ContentLibrary.ContentLibraryItem
Examples
Example 1
$item = Get-ContentLibraryItem -Name 'vm1'
$library = Get-ContentLibrary -Name 'Local content library' -Local
Copy-ContentLibraryItem -ContentLibraryItem $item -Destination $library
Copies a content library item named 'vm1' to the 'Local content library' content library.
Related Commands
ContentLibrary
This cmdlet creates a new local or subscribed content library.
This cmdlet modifies content library's properties.
This cmdlet removes the specified content libraries.
Creates a new local or subscribed content library that uses Datastore1 as a repository for its items.
ContentLibraryItem
This cmdlet retrieves catalog items from the content library.
This cmdlet copies content library items to a local content library.
This cmdlet exports content library item's files to the local machine.
This cmdlet modifies content library item's properties.
This cmdlet removes the specified content library items.
This cmdlet creates a new content library item in the specified content library.