Get-SCLibraryShare

Get-SCLibraryShare

Gets VMM library shares.

構文

Parameter Set: Default
Get-SCLibraryShare [-ID <Guid]> ] [-OnBehalfOfUser <System.String> ] [-OnBehalfOfUserRole <Microsoft.SystemCenter.VirtualMachineManager.UserRole> ] [-VMMServer <ServerConnection> ] [ <CommonParameters>]

詳細説明

The Get-SCLibraryShare cmdlet gets Virtual Machine Manager (VMM) library shares.

A library share is a Windows share on a VMM library server that is used to store files that contain library resources. Resources can include virtual machine templates, hardware profiles, guest operating system profiles, virtual hard disks (Windows-based .vhd files, Citrix XenServer-based .vhd files or VMware-based .vmdk files), virtual floppy disks (Windows-based .vfd files or VMware-based .flp files), ISO images (.iso files), and scripts, as well as stored virtual machines.

For more information about library shares, type: Get-Help Add-LibraryShare -detailed.

パラメーター

-ID<Guid]>

Specifies the numerical identifier as a globally unique identifier (GUID) for a specific object.

エイリアス

none

必須?

false

位置は?

named

既定値

none

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-OnBehalfOfUser<System.String>

エイリアス

none

必須?

false

位置は?

named

既定値

none

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-OnBehalfOfUserRole<Microsoft.SystemCenter.VirtualMachineManager.UserRole>

エイリアス

none

必須?

false

位置は?

named

既定値

none

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-VMMServer<ServerConnection>

Specifies a VMM server object.

エイリアス

none

必須?

false

位置は?

named

既定値

none

パイプライン入力を許可する

True (ByValue)

ワイルドカード文字を許可する

false

<CommonParameters>

このコマンドレットは次の共通パラメーターをサポートします。-Verbose、-Debug、-ErrorAction、-ErrorVariable、-OutBuffer、-OutVariable.詳細については、以下を参照してください。 about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216)。

入力

入力型は、コマンドレットにパイプできるオブジェクトの型です。

出力

出力型は、コマンドレットによって生成されるオブジェクトの型です。

  • LibraryShare

Example 1: Get all library shares

This command gets all library share objects from the VMM library on VMMServer01, and then displays information about these library shares.

PS C:\> Get-SCLibraryShare -VMMServer "VMMServer01.Contoso.com"

Example 2: Get a specific library share on the specified library server

This command gets the library share object named AllVHDs on library server LibraryServer01 from the library on VMMServer01, and then stores the share object in the $LibShare variable.

PS C:\> $LibShare = Get-SCLibraryShare -VMMServer "VMMServer01.Contoso.com" | where { $_.LibraryServer.Name -eq "LibraryServer01.Contoso.com" -and $_.Name -eq "AllVHDs" }

Example 3: Get all library shares on a specific library server

The first command retrieves the library server object named LibraryServer01 from the library on VMMServer01, and then stores it in the $LibServer variable.

The second command gets all library share objects on LibraryServer01, and then stores the objects in the $AllLibShares variable.

The last command passes each object in $AllLibShares to the Get-Member cmdlet, which displays the .NET type for a library share object and the list of methods and properties that are associated with a VMM library share object.

PS C:\> $LibServer = Get-SCLibraryServer -VMMServer "VMMServer01.Contoso.com" -ComputerName "LibraryServer01.Contoso.com"
PS C:\> $AllLibShares = Get-SCLibraryShare | where { $_.LibraryServer.Name -eq "$LibServer" }
PS C:\> $AllLibShares | Get-Member

関連トピック

Add-SCLibraryShare

Find-SCLibraryShare

Get-SCLibraryServer

Read-SCLibraryShare

Remove-SCLibraryShare

Set-SCLibraryShare