Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

Msvm_SwitchPort class

Hyper-V

Represents a port on the switch.

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

Syntax

class Msvm_SwitchPort : CIM_SwitchPort
{
  String   Caption = "Switch Port";
  String   ElementName;
  datetime InstallDate;
  String   StatusDescriptions[] = "OK";
  string   Status;
  uint16   HealthState = 5;
  String   OtherEnabledState;
  uint16   RequestedState = 12;
  uint16   EnabledDefault = 2;
  string   SystemCreationClassName = "Msvm_VirtualSwitch";
  string   SystemName;
  String   CreationClassName = "Msvm_SwitchPort";
  String   Description = "Microsoft Virtual Switch Port";
  uint16   OperationalStatus[] = 2;
  uint16   EnabledState = 5;
  datetime TimeOfLastStateChange;
  String   Name;
  String   NameFormat;
  uint16   ProtocolType;
  uint16   ProtocolIFType = 1;
  String   OtherTypeDescription = "Virtual Ethernet";
  boolean  BroadcastResetSupported = FALSE;
  uint16   PortNumber;
  string   ScopeOfResidence;
  uint32   VMQOffloadWeight = 100;
  uint32   ChimneyOffloadWeight = 0;
  uint32   VMQOffloadUsage;
  uint32   ChimneyOffloadUsage;
  uint32   VMQOffloadLimit;
  uint32   ChimneyOffloadLimit;
  boolean  AllowMacSpoofing;
};

Members

The Msvm_SwitchPort class has these types of members:

Methods

The Msvm_SwitchPort class has these methods.

MethodDescription
BroadcastReset

This method is not supported.

RequestStateChange

This method is not supported.

 

Properties

The Msvm_SwitchPort class has these properties.

AllowMacSpoofing
Data type: boolean
Access type: Write-only

Indicates whether the port will allow MAC spoofing.

ValueMeaning
TRUE

The port will allow MAC addresses to be spoofed. All valid unicast MAC address values are allowed except those of ports with the AllowMacSpoofing property set to FALSE.

FALSE

The port will allow only MAC addresses configured within Hyper-V management to be used.

 

Windows Server 2008:  The AllowMacSpoofing property is not supported until Windows Server 2008 R2.

BroadcastResetSupported
Data type: boolean
Access type: Read-only

Indicates whether the instrumentation supports the BroadcastReset method. This property is inherited from CIM_SwitchPort and is always set to FALSE.

Caption
Data type: String
Access type: Read-only

A short textual description (one- line string) of the object. This property is inherited from CIM_ManagedElement and is always set to "Switch Port".

ChimneyOffloadLimit
Data type: uint32
Access type: Write-only

The current TCP Chimney Offloading resources limit on this port. The limit is the maximum usage of TCP Chimney Offloading resources on the port.

Windows Server 2008:  The ChimneyOffloadLimit property is not supported until Windows Server 2008 R2.

ChimneyOffloadUsage
Data type: uint32
Access type: Write-only

The current TCP Chimney Offloading usage on this port. The usage is the amount of TCP Chimney Offloading resources in use on the port.

Windows Server 2008:  The ChimneyOffloadUsage property is not supported until Windows Server 2008 R2.

ChimneyOffloadWeight
Data type: uint32
Access type: Write-only

The weight assigned to this port for TCP Chimney Offloading. The weight is the relative importance when assigning TCP Chimney Offloading resources. Setting the ChimneyOffloadWeight property to 0 disables TCP Chimney Offloading on the port. The default is 0.

Windows Server 2008:  The ChimneyOffloadWeight property is not supported until Windows Server 2008 R2.

CreationClassName
Data type: String
Access type: Read-only

The name of the class or the subclass used in the creation of an instance. This property is inherited from CIM_ServiceAccessPoint and is always set to "Msvm_SwitchPort".

Description
Data type: String
Access type: Read-only

A textual description of the object. This property is inherited from CIM_ProtocolEndpoint and is always set to "Microsoft Virtual Switch Port".

ElementName
Data type: String
Access type: Read/write

A user-friendly 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 is always set to 2 (Enabled).

EnabledState
Data type: uint16
Access type: Read-only

The enabled and disabled states of this element. This property is inherited from CIM_ProtocolEndpoint and is always set to 5 (Not Applicable).

HealthState
Data type: uint16
Access type: Read-only

The current health of the element. This property is inherited from CIM_ManagedSystemElement and is always set to 5 (OK).

InstallDate
Data type: datetime
Access type: Read-only

A datetime value that indicates when the object was installed. This property is inherited from CIM_ManagedSystemElement and is not used.

Name
Data type: String
Access type: Read-only

A string that identifies this protocol endpoint with either a port or an interface on a device. This property is inherited from CIM_ProtocolEndpoint.

NameFormat
Data type: String
Access type: Read-only

The naming heuristic that is selected to ensure that the value of the Name property is unique. This property is inherited from CIM_ProtocolEndpoint and is not used.

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

The current statuses of the element. This property is inherited from CIM_ProtocolEndpoint and is always set to 2 (OK).

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 is inherited from CIM_EnabledLogicalElement and is not used.

OtherTypeDescription
Data type: String
Access type: Read-only

A string that describes the type of protocol endpoint when the Type property of this class (or any of its subclasses) is set to 1 ("Other"). This property is inherited from CIM_ProtocolEndpoint and is always set to "Virtual Ethernet".

PortNumber
Data type: uint16
Access type: Read-only

The numeric identifier for a switch port. This property is inherited from CIM_SwitchPort but it is not used.

ProtocolIFType
Data type: uint16
Access type: Read-only

The IANA ifType MIB. This property is inherited from CIM_ProtocolEndpoint and is always set to 1 (Other).

ProtocolType
Data type: uint16
Access type: Read-only

Information to categorize and classify different instances of this class. This property is inherited from CIM_ProtocolEndpoint and is not used.

RequestedState
Data type: uint16
Access type: Read-only

The last requested or desired state for the management service. This property is inherited from CIM_EnabledLogicalElement and is always set to 12 (Not Applicable).

ScopeOfResidence
Data type: string
Access type: Read/write

The AzMan scope for the switch service. This scope will be used when performing access checks for the switch service.

Status
Data type: string
Access type: Read-only

The current status of the object. Operational and non-operational status can be defined. Operational status can include "OK", "Degraded", and "Pred Fail". "Pred Fail" indicates whether an element is functioning properly, but is predicting a failure (for example, a SMART-enabled hard disk drive).

Non-operational status can include "Error", "Starting", "Stopping", and "Service". "Service" can apply during disk mirror-resilvering, reloading a user permissions list, or other administrative work. Not all such work is online, but the managed element is neither "OK" nor in one of the other states.

This property is inherited from CIM_ManagedSystemElement

"OK"

"Error"

"Degraded"

"Unknown"

"Pred Fail"

"Starting"

"Stopping"

"Service"

"Stressed"

"NonRecover"

"No Contact"

"Lost Comm"

StatusDescriptions
Data type: String array
Access type: Read-only

Strings that describe the various OperationalStatus array values. This property is inherited from CIM_ManagedSystemElement and is always set to "OK".

SystemCreationClassName
Data type: string
Access type: Read-only

The creation class name of the scoping system. This property is inherited from CIM_ServiceAccessPoint and is always set to "Msvm_VirtualSwitch".

SystemName
Data type: string
Access type: Read-only

The system name of the scoping system. This property is inherited from CIM_ServiceAccessPoint.

TimeOfLastStateChange
Data type: datetime
Access type: Read-only

The date or time when the enabled state of the element last changed. This property is inherited from CIM_ProtocolEndpoint and is not used.

VMQOffloadLimit
Data type: uint32
Access type: Write-only

The current VMQ offloading limit on this port. The limit is the maximum usage of VMQ offloading resources on the port.

Windows Server 2008:  The VMQOffloadLimit property is not supported until Windows Server 2008 R2.

VMQOffloadUsage
Data type: uint32
Access type: Write-only

The current VMQ offloading usage on this port. The usage is the amount of VMQ resources in use on the port.

Windows Server 2008:  The VMQOffloadUsage property is not supported until Windows Server 2008 R2.

VMQOffloadWeight
Data type: uint32
Access type: Write-only

The weight assigned to this port for virtual machine queue (VMQ) offloading. The weight is the relative importance when assigning VMQ resources. Setting the VMQOffloadWeight property to 0 disables VMQ on the port. The default is 100.

ValueMeaning
0

Disables VMQ on the port.

100

Default value.

 

Windows Server 2008:  The VMQOffloadWeight property is not supported until Windows Server 2008 R2.

Remarks

Access to the Msvm_SwitchPort class might be restricted by UAC Filtering. For more information, see User Account Control and WMI.

Examples

See Querying Networking Objects.

Requirements

Minimum supported client

None supported

Minimum supported server

Windows Server 2008

End of client support

None supported

End of server support

Windows Server 2012

Namespace

\\.\Root\Virtualization

MOF

WindowsVirtualization.mof

See also

CIM_SwitchPort
Networking Classes

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.