Status - property in ROOT\CIMV2\storage\iscsitarget namespace

Status in other namespaces

List of classes with Status local property in ROOT\CIMV2\storage\iscsitarget namespace

propertyClassOrigin
StatusCIM_ManagedSystemElementCIM_ManagedSystemElement

List of classes with Status derived property in ROOT\CIMV2\storage\iscsitarget namespace

propertyClassOrigin
StatusCIM_AuthenticationServiceCIM_ManagedSystemElement
StatusCIM_ComputerSystemCIM_ManagedSystemElement
StatusCIM_ConcreteJobCIM_ManagedSystemElement
StatusCIM_ControllerConfigurationServiceCIM_ManagedSystemElement
StatusCIM_EnabledLogicalElementCIM_ManagedSystemElement
StatusCIM_EthernetPortCIM_ManagedSystemElement
StatusCIM_IdentityManagementServiceCIM_ManagedSystemElement
StatusCIM_IPProtocolEndpointCIM_ManagedSystemElement
StatusCIM_iSCSIConfigurationServiceCIM_ManagedSystemElement
StatusCIM_iSCSIConnectionCIM_ManagedSystemElement
StatusCIM_iSCSIProtocolEndpointCIM_ManagedSystemElement
StatusCIM_iSCSISessionCIM_ManagedSystemElement
StatusCIM_JobCIM_ManagedSystemElement
StatusCIM_LogicalDeviceCIM_ManagedSystemElement
StatusCIM_LogicalElementCIM_ManagedSystemElement
StatusCIM_LogicalPortCIM_ManagedSystemElement
StatusCIM_NetworkPipeCIM_ManagedSystemElement
StatusCIM_NetworkPortCIM_ManagedSystemElement
StatusCIM_ObjectManagerCIM_ManagedSystemElement
StatusCIM_ObjectManagerCommunicationMechanismCIM_ManagedSystemElement
StatusCIM_ProtocolControllerCIM_ManagedSystemElement
StatusCIM_ProtocolEndpointCIM_ManagedSystemElement
StatusCIM_ReplicationServiceCIM_ManagedSystemElement
StatusCIM_ResourcePoolCIM_ManagedSystemElement
StatusCIM_SCSIProtocolControllerCIM_ManagedSystemElement
StatusCIM_SCSIProtocolEndpointCIM_ManagedSystemElement
StatusCIM_SecurityServiceCIM_ManagedSystemElement
StatusCIM_ServiceCIM_ManagedSystemElement
StatusCIM_ServiceAccessPointCIM_ManagedSystemElement
StatusCIM_SoftwareIdentityCIM_ManagedSystemElement
StatusCIM_StorageConfigurationServiceCIM_ManagedSystemElement
StatusCIM_StorageExtentCIM_ManagedSystemElement
StatusCIM_StorageHardwareIDManagementServiceCIM_ManagedSystemElement
StatusCIM_StoragePoolCIM_ManagedSystemElement
StatusCIM_StorageVolumeCIM_ManagedSystemElement
StatusCIM_SystemCIM_ManagedSystemElement
StatusCIM_TCPProtocolEndpointCIM_ManagedSystemElement
StatusCIM_WBEMServiceCIM_ManagedSystemElement
StatusMSFTSM_ComputerSystemCIM_ManagedSystemElement
StatusMSFTSM_ObjectManagerCIM_ManagedSystemElement
StatusMSFTSM_SoftwareIdentityCIM_ManagedSystemElement
StatusMSFTSM_SystemCIM_ManagedSystemElement
StatusMSFTSM_WSManCommunicationMechanismCIM_ManagedSystemElement
StatusMSFTSMNET_EthernetPortCIM_ManagedSystemElement
StatusMSFTSMNET_IPProtocolEndpointCIM_ManagedSystemElement
StatusMSISCSITARGET_ConcreteJobCIM_ManagedSystemElement
StatusMSISCSITARGET_ControllerConfigurationServiceCIM_ManagedSystemElement
StatusMSISCSITARGET_iSCSIConfigurationServiceCIM_ManagedSystemElement
StatusMSISCSITARGET_iSCSIConnectionCIM_ManagedSystemElement
StatusMSISCSITARGET_iSCSIProtocolEndpointCIM_ManagedSystemElement
StatusMSISCSITARGET_iSCSISessionCIM_ManagedSystemElement
StatusMSISCSITARGET_ReplicationServiceCIM_ManagedSystemElement
StatusMSISCSITARGET_SCSIProtocolControllerCIM_ManagedSystemElement
StatusMSISCSITARGET_StorageConfigurationServiceCIM_ManagedSystemElement
StatusMSISCSITARGET_StorageHardwareIDManagementServiceCIM_ManagedSystemElement
StatusMSISCSITARGET_StoragePoolCIM_ManagedSystemElement
StatusMSISCSITARGET_StorageVolumeCIM_ManagedSystemElement
StatusMSISCSITARGET_TCPProtocolEndpointCIM_ManagedSystemElement

Code samples for Status property

Get instance of WMI class using GetObject, Status property of MSFTSM_WSManCommunicationMechanism

Short VBS code - get a single specified instance of MSFTSM_WSManCommunicationMechanism class or get a default unnamed instance (singleton) of the class, using one single command GetObject with exact path of the wmi object.

'https://wutils.com/wmi/
Dim wmiObject
Set wmiObject = GetObject( _
 "WINMGMTS:\\.\ROOT\CIMV2\storage\iscsitarget:" + _
 "MSFTSM_WSManCommunicationMechanism.CreationClassName=""MSFTSM_WSManCommunicationMechanism"",Name=""MSFT:SM.WS-Management"",SystemCreationClassName=""MSFTSM_System"",SystemName=""MS iSCSITarget: ..rootdomain.com""")
Wscript.Echo wmiObject.Status 'or other property name, see properties
See more VBS samples of MSFTSM_WSManCommunicationMechanism class

WMI query - sample windows WQL with C#, Status property of MSFTSM_WSManCommunicationMechanism

Get a specified instance of MSFTSM_WSManCommunicationMechanism by a key, get a default unnamed instance (singleton) of the class or list instances of the class by wmi query using this c# sample code.
See in another language: VBScript, VB.Net.
//https://wutils.com/wmi/

//Project -> Add reference -> System.Management
//using System.Management;

//create a management scope object
ManagementScope scope = new ManagementScope("\\\\.\\ROOT\\CIMV2\\storage\\iscsitarget");

//create object query
ObjectQuery query = new ObjectQuery("SELECT * FROM MSFTSM_WSManCommunicationMechanism Where CreationClassName=\"MSFTSM_WSManCommunicationMechanism\"Name=\"MSFT:SM.WS-Management\"SystemCreationClassName=\"MSFTSM_System\"SystemName=\"MS iSCSITarget: W2012SDC.rootdomain.com\"");

//create object searcher
ManagementObjectSearcher searcher =
                        new ManagementObjectSearcher(scope, query);

//get a collection of WMI objects
ManagementObjectCollection queryCollection = searcher.Get();

//enumerate the collection.
foreach (ManagementObject m in queryCollection) 
{
  // access properties of the WMI object
  Console.WriteLine("Status : {0}", m["Status"]);
  
}

WMI query - sample windows WQL with VB.Net, Status property of MSFTSM_WSManCommunicationMechanism

Get a specified instance of MSFTSM_WSManCommunicationMechanism by a key, get a default unnamed instance (singleton) of the class or list instances of the class by wmi query using this VB.Net sample code.
See in another language: VBScript, C#
'Project -> Add reference -> System.Management
'Imports System.Management

'Get the namespace management scope
Dim Scope As New ManagementScope("\\.\ROOT\CIMV2\storage\iscsitarget")

'Get a result of WML query 
Dim Query As New ObjectQuery("SELECT * FROM MSFTSM_WSManCommunicationMechanism Where CreationClassName="MSFTSM_WSManCommunicationMechanism"Name="MSFT:SM.WS-Management"SystemCreationClassName="MSFTSM_System"SystemName="MS iSCSITarget: W2012SDC.rootdomain.com"")

'Create object searcher
Dim Searcher As New ManagementObjectSearcher(Scope, Query)

'Get a collection of WMI objects
Dim queryCollection As ManagementObjectCollection = Searcher.Get

'Enumerate wmi object 
For Each mObject As ManagementObject In queryCollection
  'write out some property value
  Console.WriteLine("Status : {0}", mObject("Status"))
Next
comments powered by Disqus
WUtils.com