Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

Msvm_VirtualEthernetSwitch class

Hyper-V

Represents a virtual Ethernet switch. Each switch has many different ports to which network adapters can be attached. The switch itself is not highly configurable and acts mostly as a placeholder.

The following syntax is simplified Managed Object Format (MOF) code, and it includes all of the inherited properties.

Syntax

class Msvm_VirtualEthernetSwitch : CIM_ComputerSystem
{
  string   InstanceID;
  string   Caption = "Virtual Switch";
  string   Description = "Microsoft Virtual Switch";
  string   ElementName;
  datetime InstallDate;
  uint16   OperationalStatus[];
  string   StatusDescriptions[];
  string   Status;
  uint16   HealthState = 5;
  uint16   CommunicationStatus;
  uint16   DetailedStatus;
  uint16   OperatingStatus;
  uint16   PrimaryStatus;
  uint16   EnabledState = 5;
  string   OtherEnabledState;
  uint16   RequestedState;
  uint16   EnabledDefault = 2;
  datetime TimeOfLastStateChange;
  uint16   AvailableRequestedStates[];
  uint16   TransitioningToState;
  string   CreationClassName = "Msvm_VirtualEthernetSwitch";
  string   Name = "GUID";
  string   PrimaryOwnerName;
  string   PrimaryOwnerContact;
  string   Roles[];
  string   NameFormat;
  string   OtherIdentifyingInfo[];
  string   IdentifyingDescriptions[];
  uint16   Dedicated[];
  string   OtherDedicatedDescriptions[];
  uint16   ResetCapability = 5;
  uint16   PowerManagementCapabilities[];
  uint32   MaxVMQOffloads;
  uint32   MaxIOVOffloads;
};

Members

The Msvm_VirtualEthernetSwitch class has these types of members:

Methods

The Msvm_VirtualEthernetSwitch class has these methods.

MethodDescription
RequestStateChange

This method is not supported.

SetPowerState

This method is not supported.

 

Properties

The Msvm_VirtualEthernetSwitch class has these properties.

AvailableRequestedStates
Data type: uint16 array
Access type: Read-only

Indicates the possible values for the RequestedState parameter of the RequestStateChange method used to initiate a state change. The values listed will be a subset of the values contained in the RequestedStatesSupported property of the associated instance of CIM_EnabledLogicalElementCapabilities, where the values selected are a function of the current state of the CIM_EnabledLogicalElement object. This property can be non-Null if an implementation is able to advertise the set of possible values as a function of the current state. This property will be Null if an implementation is unable to determine the set of possible values as a function of the current state.

This property is inherited from CIM_EnabledLogicalElement.

Enabled (2)
Disabled (3)
Shut Down (4)
Offline (6)
Test (7)
Defer (8)
Quiesce (9)
Reboot (10)
Reset (11)
DMTF Reserved (.. )
Caption
Data type: string
Access type: Read-only

A short description of the object. This property is inherited from CIM_ManagedElement, and it is always set to "Virtual Switch".

CommunicationStatus
Data type: uint16
Access type: Read-only

Indicates the ability of the instrumentation to communicate with the underlying managed element. A Null value indicates that this property is not implemented. This property is inherited from CIM_ManagedSystemElement.

Unknown (0)
Not Available (1)
Communication OK (2)
Lost Communication (3)
No Contact (4)
DMTF Reserved (..)
Vendor Reserved (0x8000.. )
CreationClassName
Data type: string
Access type: Read-only

The name of the class or subclass that is used in the creation of an instance. This property is inherited from CIM_System, and it is always set to "Msvm_VirtualEthernetSwitch".

Dedicated
Data type: uint16 array
Access type: Read-only

Indicates whether the computer system is a special-purpose system (dedicated to a particular use), versus being a general-purpose system. This property is inherited from CIM_ComputerSystem, and it is always set to 0 (Not Dedicated).

Description
Data type: string
Access type: Read-only

A description of the object. This property is inherited from CIM_ManagedElement, and it is always set to "Microsoft Virtual Switch".

DetailedStatus
Data type: uint16
Access type: Read-only

Compliments the PrimaryStatus property with additional status detail. A Null value indicates that this property is not implemented. This property is inherited from CIM_ManagedSystemElement.

Not Available (0)
No Additional Information (1)
Stressed (2)
Predictive Failure (3)
Non-Recoverable Error (4)
Supporting Entity in Error (5)
DMTF Reserved (..)
Vendor Reserved (0x8000.. )
ElementName
Data type: string
Access type: Read-only

A display name for the object. This property is inherited from CIM_ManagedElement.

EnabledDefault
Data type: uint16
Access type: Read-only

An administrator's default or startup configuration for the enabled state of an element. This property is inherited from CIM_EnabledLogicalElement and will be one of the following values.

Enabled (2)
Disabled (3)
Enabled but Offline (6)
EnabledState
Data type: uint16
Access type: Read-only

The enabled and disabled states of an element. This property can also indicate the transitions between these requested states. This property is inherited from CIM_EnabledLogicalElement, and it is always set to 5 (Not Applicable).

HealthState
Data type: uint16
Access type: Read-only

Specifies the current health of the element. This attribute expresses the health of this element but not necessarily that of its subcomponents.

When a critical error occurs, check the event log for details. The EnabledState property can also contain more information. For example, when disk space is critically low, HealthState is set to 25, the virtual machine pauses, and EnabledState is set to 32768 (Paused).

This property is inherited from CIM_ManagedSystemElement.

ValueMeaning
OK
5

The element is fully functional and is operating within normal operational parameters and without error.

Major Failure
20

The element has suffered a major failure.

Critical failure
25

The element is nonfunctional, and recovery might not be possible.

 

IdentifyingDescriptions
Data type: string array
Access type: Read-only

This property is inherited from CIM_ComputerSystem, and it is always set to Null.

InstallDate
Data type: datetime
Access type: Read-only

The date and time the virtual machine configuration was created for a virtual machine, or Null, for a management operating system. This property is inherited from CIM_ManagedSystemElement.

InstanceID
Data type: string
Access type: Read-only
Qualifiers: Key

Uniquely identifies an instance of this class. This property is inherited from CIM_ManagedElement.

MaxIOVOffloads
Data type: uint32
Access type: Read-only

The maximum number of single root IO virtualization (SR-IOV) virtual function offloads available on this switch.

MaxVMQOffloads
Data type: uint32
Access type: Read/write

The maximum number of virtual machine queue (VMQ) offloads allowed for a port on this switch.

Name
Data type: string
Access type: Read-only

The label by which the object is known. This property is inherited from CIM_System, and it is always set to "GUID".

NameFormat
Data type: string
Access type: Read-only

A string that identifies how the system name was generated, using the subclass heuristic. This property is inherited from CIM_ComputerSystem, and it is always set to Null.

OperatingStatus
Data type: uint16
Access type: Read-only

Provides current status information for the operational condition of the element and can be used for providing more detail with respect to the value of the EnabledState property. A Null value indicates that this property is not implemented. This property is inherited from CIM_ManagedSystemElement.

Unknown (0)
Not Available (1)
Servicing (2)
Starting (3)
Stopping (4)
Stopped (5)
Aborted (6)
Dormant (7)
Completed (8)
Migrating (9)
Emigrating (10)
Immigrating (11)
Snapshotting (12)
Shutting Down (13)
In Test (14)
Transitioning (15)
In Service (16)
DMTF Reserved (..)
Vendor Reserved (0x8000.. )
OperationalStatus
Data type: uint16 array
Access type: Read-only

An array that contains the current statuses of the object. This property is inherited from CIM_ManagedSystemElement.

OtherDedicatedDescriptions
Data type: string array
Access type: Read-only

A string that describes how or why the system is dedicated when the Dedicated array includes the value 2 (Other). This property is inherited from CIM_ComputerSystem, and it is always set to Null.

OtherEnabledState
Data type: string
Access type: Read-only

The enabled or disabled state of the element when the EnabledState property is set to 1 (Other). This property must be set to Null when EnabledState is any value other than 1. This property is inherited from CIM_EnabledLogicalElement, and it is always set to Null.

OtherIdentifyingInfo
Data type: string array
Access type: Read-only

This property is inherited from CIM_ComputerSystem, and it is always set to Null.

PowerManagementCapabilities
Data type: uint16 array
Access type: Read-only

This property is inherited from CIM_ComputerSystem, but it is not used.

PrimaryOwnerContact
Data type: string
Access type: Read-only

A string that indicates how the primary system owner can be reached (for example, a phone number or an email address). This property is inherited from CIM_System, and it is always set to Null.

PrimaryOwnerName
Data type: string
Access type: Read-only

The name of the primary system owner. This property is inherited from CIM_System, and it is always set to Null.

PrimaryStatus
Data type: uint16
Access type: Read-only

Provides high level status information. This property should be used in conjunction with the DetailedStatus property to provide high level and detailed health status of the element and its subcomponents. A Null value indicates that this property is not implemented. This property is inherited from CIM_ManagedSystemElement.

Unknown (0)
OK (1)
Degraded (2)
Error (3)
DMTF Reserved (..)
Vendor Reserved (0x8000.. )
RequestedState
Data type: uint16
Access type: Read-only

The last requested or desired state for the element as passed to the RequestStateChange method, or 12 (Not Applicable) if no state change is in progress. The actual state of the element is represented by EnabledState. This property is provided to compare the last requested and current enabled or disabled states. This property is inherited from CIM_EnabledLogicalElement.

ResetCapability
Data type: uint16
Access type: Read-only

This property is inherited from CIM_ComputerSystem, and it is always set to 5 (Not implemented).

Roles
Data type: string array
Access type: Read-only

An array of strings that describe the roles the system plays in the information technology environment. This property is inherited from CIM_System, and it is always set to Null.

Status
Data type: string
Access type: Read-only

A string that specifies the status of the element. This property is inherited from CIM_ManagedSystemElement.

StatusDescriptions
Data type: string array
Access type: Read-only
Qualifiers: ArrayType ("Indexed")

An array that contains strings that describe the corresponding OperationalStatus array values. This property is inherited from CIM_ManagedSystemElement.

TimeOfLastStateChange
Data type: datetime
Access type: Read-only

The date and time when the enabled state of the element last changed. This property is inherited from CIM_EnabledLogicalElement.

TransitioningToState
Data type: uint16
Access type: Read-only

Indicates the target state to which the instance is transitioning. This property is inherited from CIM_EnabledLogicalElement.

Requirements

Minimum supported client

Windows 8 [desktop apps only]

Minimum supported server

Windows Server 2012 [desktop apps only]

Namespace

Root\Virtualization\V2

MOF

WindowsVirtualization.V2.mof

 

 

Community Additions

Show:
© 2015 Microsoft