none
WMI class from list | unable to get properties RRS feed

  • Question

  • Hello,

    I have listed required wmi classes for myself.

    $AllClasses = Get-WmiObject -List -Namespace $namespace -ComputerName $SCCMServerName

    PS DBP:\> $AllClasses | Where-Object {$_ -like "*DP*"}

    Here is the list... I see that my listed class exist named : SMS_DPGroupDistributionStatus

       NameSpace: ROOT\sms\site_DBP

    Name                                Methods              Properties                                                                                                                          
    ----                                -------              ----------                                                                                                                          
    __MethodProviderRegistration        {}                   {provider}                                                                                                                          
    SMS_MigrationDP                     {}                   {AdditionalRoleInstalled, AddressScheduleEnabled, AttachingSite, AttachingSitecode...}                                              
    SMS_VhdPackage                      {RefreshPkgSource... {ActionInProgress, AlternateContentProviders, Description, ExtendedData...}                                                         
    SMS_DPGroupMembers                  {}                   {DPNALPath, GroupID}                                                                                                                
    SMS_DPGroupPackages                 {}                   {GroupID, PkgID}                                                                                                                    
    SMS_DPGroupCollections              {}                   {CollectionDescription, CollectionID, CollectionMemberCount, CollectionName...}                                                     
    SMS_SupportedPlatforms              {GetSupportedPlat... {CI_UniqueID, Condition, DisplayText, IsSupported...}                                                                               
    SMS_SupportedPlatformsOfflineSer... {}                   {Name, OsVersionBuild, ProductType}                                                                                                 
    SMS_OSDeploymentKitSupportedPlat... {}                   {DeploymentKitVersion, Name, OsVersionBuild, ProductType}                                                                           
    SMS_MeteredProductRule              {}                   {ApplyToChildSites, Comment, Enabled, FileName...}                                                                                  
    SMS_G_System_EndpointProtectionS... {}                   {AmFullscanRequired, AmManualStepsRequired, AmOfflineScanRequired, AmRecentlyCleaned...}                                            
    SMS_DPStatus                        {}                   {AppCI, Failed, Installed, LastUpdated...}                                                                                          
    SMS_DPStatusPerDP                   {}                   {DPName, Failed, Installed, LastUpdated...}                                                                                         
    SMS_EndpointProtectionAgentConfig   {}                   {AgentID, DisableFirstSignatureUpdate, EnableBlueProvider, EnableEP...}                                                             
    SMS_DPGroupContentInfo              {}                   {Description, GroupID, IsPredefinedPackage, Name...}                                                                                
    SMS_DPContentInfo                   {}                   {Description, IsPredefinedPackage, NALPath, Name...}                                                                                
    SMS_DistributionDPStatus            {}                   {GroupCount, ID, InsString1, InsString10...}                                                                                        
    SMS_DPGroupInfo                     {}                   {AssignedContentCount, Description, FeatureType, GroupID...}                                                                        
    SMS_DPGroupDistributionStatus       {}                   {Assets, ContentCount, GroupID, MessageCategory...}                                                                                 
    SMS_DPGroupDistributionStatusDet... {}                   {ContentName, DPName, GroupID, ID...}                                                                                               
    SMS_DPStatusSummary                 {UpdateSummaryData}  {DeploymentType, Description, Name, NumberErrors...}                                                                                
    SMS_DPStatusInfo                    {}                   {IsDPMonEnabled, IsMulticast, IsPullDP, IsPXE...}                                                                                   
    SMS_DPStatusDetails                 {}                   {DPName, ID, InsString1, InsString10...}                                                                                            
    SMS_EndpointProtectionHealthStatus  {}                   {ApplyPolicyFailedCount, ApplyPolicySucceededCount, CollectionID, InstallFailedCount...}                                            
    SMS_EndpointProtectionThreatData    {}                   {DefaultActionID, IsAV, Name, ThreatID...}                                                                                          
    SMS_EndpointProtectionDashboardB... {}                   {Bucket, CollectionID, CollectionName}                                                                                              
    SMS_CM_UpdatePackDetailedPrereqM... {}                   {Applicable, Description, IsComplete, MessageTime...}                                                                               
    SMS_CloudProxyConnector             {}                   {MaxConcurrentRequestsLast30Days, ProxyServiceName, ServerName, SiteCode...}                                                        
    SMS_CloudProxyRoleEndpoint          {}                   {EndpointName, InternalEndpointName, MaxConcurrentRequestsLast30Days, ProxyServiceName...}                                          
    SMS_CloudProxyExternalEndpoint      {AddEndpoint}        {ClientAuthScheme, EndpointName, InternalEndpointName, InternalServerName...}                                                       
    SMS_EmbeddedProperty                {}                   {ItemType, PropertyName, Value, Value1...}                                                                                          
    SMS_EmbeddedPropertyList            {}                   {ItemType, PropertyListName, Values}                                                                                                
    SMS_TaskSequenceReferenceDps        {}                   {Hash, PackageID, ServerNALPath, SiteCode...}                                                                                       
    SMS_TaskSequenceAppReferenceDps     {}                   {Hash, PackageID, ServerNALPath, SiteCode...}                                                                                       
    SMS_Category_LocalizedProperties    {}                   {CategoryInstanceName, LocaleID}                                                                                                    
    SMS_CI_LocalizedProperties          {}                   {Description, DisplayName, InformativeURL, LocaleID}                                                                                
    SMS_TaskSequence_DownloadPackage... {}                   {Condition, ContinueDownloadOnError, ContinueOnError, Description...}      

    QUESTION: When i try to get Get-WmiObject -class SMS_DPGroupDistributionStatus

    it said invalid class name, but it still exist in all classes list. Why?

    PS DBP:\> Get-WmiObject -class SMS_DPGroupContentInfo
    Get-WmiObject : Invalid class "SMS_DPGroupContentInfo"
    At line:1 char:1
    + Get-WmiObject -class SMS_DPGroupContentInfo
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        + CategoryInfo          : InvalidType: (:) [Get-WmiObject], ManagementException
        + FullyQualifiedErrorId : GetWMIManagementException,Microsoft.PowerShell.Commands.GetWmiObjectCommand

    Wednesday, February 1, 2017 11:00 AM

Answers

  • Hi Aurimas,

    you still need to specify the namespace and computername:

    Get-WmiObject -class SMS_DPGroupContentInfo -Namespace $Namespace -ComputerName $SCCMServerName

    Cheers,
    Fred


    There's no place like 127.0.0.1

    • Marked as answer by TechSpark0 Wednesday, February 1, 2017 11:07 AM
    Wednesday, February 1, 2017 11:04 AM

All replies

  • Hi Aurimas,

    you still need to specify the namespace and computername:

    Get-WmiObject -class SMS_DPGroupContentInfo -Namespace $Namespace -ComputerName $SCCMServerName

    Cheers,
    Fred


    There's no place like 127.0.0.1

    • Marked as answer by TechSpark0 Wednesday, February 1, 2017 11:07 AM
    Wednesday, February 1, 2017 11:04 AM
  • Ok :) thanks, when searching wmi class and properties of it im always should type name space. Clear.
    Wednesday, February 1, 2017 11:07 AM
  • Think of wmi as a folder structure and "Get-WmiObject -List" like a dir command:

    "-Namespace" is the folder you are searching in
    "-ComputerName" is the Computer where that 'folder structure' is on


    There's no place like 127.0.0.1

    Wednesday, February 1, 2017 11:19 AM