Get-SCGuestOSProfile

Gets a guest operating system profile object from the VMM library.

Syntax

Get-SCGuestOSProfile [[-Name] <String>] -AnswerFile <Script> [-OnBehalfOfUser <String>]
 [-OnBehalfOfUserRole <UserRole>] [-OperatingSystem <OperatingSystem>] [<CommonParameters>]
Get-SCGuestOSProfile [[-Name] <String>] [-OnBehalfOfUser <String>] [-OnBehalfOfUserRole <UserRole>]
 [-VMMServer <ServerConnection>] [<CommonParameters>]

Description

The Get-SCGuestOSProfile cmdlet gets one or more guest operating system profile objects from the Virtual Machine Manager (VMM) library.

Examples

Example 1: Get all guest operating system profiles from the library

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

This command gets all guest OS profile objects from the library on VMMServer01 and displays information about these profiles to the user.

Example 2: Get a specific guest operating system profile from the library

PS C:\> Get-GuestOSProfile -Name "NewOSProfile01"

This command gets the guest OS profile object named NewOSProfile01 and displays information about this profile to the user.

Parameters

-AnswerFile

Specifies a script object stored in the VMM library to use as an answer file. The name of the answer file script depends on the operating system that you want to install on a virtual machine:

- Sysprep.inf. Windows XP, Windows Server 2000, or Windows Server 2003

  • Unattend.xml. Windows Vista, Windows 7, or Windows Server 2008

Type:Script
Aliases:SysPrepFile
Required:True
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-Name

Specifies the name of a VMM object.

Type:String
Required:False
Position:0
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-OnBehalfOfUser

Specifies a user name. This cmdlet operates on behalf of the user that this parameter specifies.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-OnBehalfOfUserRole

Specifies a user role. To obtain a user role, use the Get-SCUserRole cmdlet. This cmdlet operates on behalf of the user role that this parameter specifies.

Type:UserRole
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-OperatingSystem

Specifies the type of operating system for a virtual machine. To list the names of all available operating systems in VMM, type Get-SCOperatingSystem.

Type:OperatingSystem
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VMMServer

Specifies a VMM server object.

Type:ServerConnection
Required:False
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False

Outputs

GuestOSProfile

This cmdlet returns a **GuestOSProfile** object.