myITforum.com Community Forum myITforum.com Community Forum

Home  Forums  Blogs  Live Support chat  Search Articles  Wiki  FAQ  Email Lists  Register  Login  My Profile  Inbox  Address Book  My Subscription  My Forums 

Photo Gallery  Member List  Search  Calendars  FAQ  Ticket List  Log Out

All Forums RSS Feed Subscription:


  


SCCM 2007 SP1 & Extend Hardware Inventory

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
  Printable Version
All Forums >> [Management Products] >> System Center Products >> System Center Configuration Manager >> SCCM 2007 SP1 & Extend Hardware Inventory Page: [1]
Login
Message << Older Topic   Newer Topic >>
SCCM 2007 SP1 & Extend Hardware Inventory - 8/25/2008 10:13:40 AM   
omangon

 

Posts: 6
Score: 0
Joined: 8/8/2008
Status: offline
Hello
I'm not very proud of it but , i didn"t success to extend hardwar inventory.
I mean that i succeed to enable the default inventory classes from SMSreport from false to true, but adding a custom class doesn't matter.
My Test environnement is :
Vmware ESX Server with
Windows 2008 64 Bits  US
SCCM 2007 SP1 US
What i do is :
Add in configuration.mof the following
#pragma namespace( "\\\\.\\root\\cimv2" )
#pragma deleteclass("TOTALMASTERI", NOFAIL)
[
dynamic,
provider("RegProv"),
ClassContext ("local|HKEY_LOCAL_MACHINE\\SYSTEM\\Setup")
]
class TOTALMASTERI
{
[key]
string KeyName="";
[PropertyContext ("SystemPartition")] string version;
};

Add in sms_def.mof the folliwing:


#pragma namespace( "\\\\.\\root\\cimv2\\sms" )
#pragma deleteclass("TOTALMASTERI", NOFAIL)
[   SMS_Report (TRUE),  SMS_Group_Name ("TOTAL INF"),  SMS_Class_ID ("MICROSOFT|TOTALMASTERI|1.0") ]
class TOTALMASTERI : SMS_Class_Template
{
[SMS_Report (TRUE), key] string KeyName;
[SMS_Report (TRUE)] string version;
};

Trigger hardware inventory from my client/server
See the dataldr.log working fine (adding classes)
see in wbemtest the class created but i cannot see instance (empty one)
Post #: 1
RE: SCCM 2007 SP1 & Extend Hardware Inventory - 8/25/2008 10:34:30 AM   
skissinger


Posts: 2119
Score: 134
Joined: 9/13/2001
From: Sherry Kissinger
Status: offline
It looks like you have a mix of trying to get values from a subkey, but then also individual regkey values.  I'm guessing you are adding the specific regkey "version" yourself in your image or something?  Because I don't have that key in my lab client in that HKLM\system\setup area, or in a subkey under there.

Can I send you here, and if you have questions, just post them.  (note, the wiki's example of static keys doesn't show the [ ] around the word DYNPROPS; they are supposed to be there, like [DYNPROPS], but I'm having a problem getting them to show up right in the wiki.  So just be aware of that if you're going to copy that example)

_____________________________

mofmaster@smsexpert.com (version 2007) | http://www.smsexpert.com | http://www.sccmexpert.com
My Blog
Microsoft MVP - ConfigMgr

(in reply to omangon)
Post #: 2
RE: SCCM 2007 SP1 & Extend Hardware Inventory - 8/25/2008 11:07:10 AM   
omangon

 

Posts: 6
Score: 0
Joined: 8/8/2008
Status: offline
Hello
what i try to get is the following key
HKEY_LOCAL_MACHINE\system\setup
   SystemPartition     REG_SZ  \Device\HarddiskVolume1

So i was thinking that this command in MOF [PropertyContext ("SystemPartition")] string version; 
mean get me the SystemPartition Property of the Key (so the key SystemPartition) and display me as version in Ressource explorer ?

(in reply to skissinger)
Post #: 3
RE: SCCM 2007 SP1 & Extend Hardware Inventory - 8/25/2008 11:16:04 AM   
jnelson993


Posts: 900
Score: 127
Joined: 2/18/2005
From: Minneapolis, MN
Status: offline
Isn't the information in v_GS_PARTITION enough?  There's BootPartition0 and PrimaryPartition0...

If you don't have it enabled in your MOF, it's in the Win32_DiskPartition section. 


_____________________________

Number2 (John Nelson)
MyITForum - Blog
MyITForum - Forum Posts

(in reply to omangon)
Post #: 4
RE: SCCM 2007 SP1 & Extend Hardware Inventory - 8/25/2008 11:17:20 AM   
skissinger


Posts: 2119
Score: 134
Joined: 9/13/2001
From: Sherry Kissinger
Status: offline
Edit: what John said.

< Message edited by skissinger -- 8/25/2008 11:18:09 AM >


_____________________________

mofmaster@smsexpert.com (version 2007) | http://www.smsexpert.com | http://www.sccmexpert.com
My Blog
Microsoft MVP - ConfigMgr

(in reply to omangon)
Post #: 5
RE: SCCM 2007 SP1 & Extend Hardware Inventory - 8/25/2008 11:30:10 AM   
omangon

 

Posts: 6
Score: 0
Joined: 8/8/2008
Status: offline
I have not mention the following, this is for a test, because what i try to do is to test to gather a key in a Windows embeded key.
After that if it works, i will put my key in the registry and gather them.
So if i cannot gather an already existing key provide by Windows, i will not succeed to gather my own one :-)

So on Windows 2003 R2 with SCCM 2007 SP1 , i didn't have any problem to get it, but on Windows 2008 SP1 64 bits with SCCM 2007SP1 i didn't
I know that Registry key on 64 bit system are in HKLM\SOFTWARE\WOW6432NODE  but here i try to access one in HKLM\SYSTEM.
any idea or succeed test ?

(in reply to skissinger)
Post #: 6
RE: SCCM 2007 SP1 & Extend Hardware Inventory - 8/25/2008 11:38:04 AM   
skissinger


Posts: 2119
Score: 134
Joined: 9/13/2001
From: Sherry Kissinger
Status: offline
In that case, please check here, and start with "Custom Inventory, individual regkeys". (Remember about the [] around DYNPROPS not being displayed correclty.

_____________________________

mofmaster@smsexpert.com (version 2007) | http://www.smsexpert.com | http://www.sccmexpert.com
My Blog
Microsoft MVP - ConfigMgr

(in reply to omangon)
Post #: 7
RE: SCCM 2007 SP1 & Extend Hardware Inventory - 8/28/2008 5:10:07 AM   
omangon

 

Posts: 6
Score: 0
Joined: 8/8/2008
Status: offline
Hello
The sollution in your articles is not working in my environnment (Windows 2008 64 Bits)
But i'have found the tricky things, i would like to add to your wiki the following things:
In a 64 bits environnments, the default request must be focus in the architecture where the Key or Classes exists by adding the following syntaxe in a classes in the sms_def.mof:
For 32 bits Value to retrieve
[SMS_Report(TRUE),
SMS_Group_Name("YourGroup"),
SMS_Context_1  ("__ProviderArchitecture=32|uint32"),
SMS_Context_2  ("__RequiredArchitecture=true|boolean"),
SMS_Class_ID("MICROSOFT|YourClass|1.5")]

For 64 bits to retrieve
[SMS_Report(TRUE),
SMS_Group_Name("YourGroup"),
SMS_Context_1  ("__ProviderArchitecture=64|uint32"),
SMS_Context_2  ("__RequiredArchitecture=true|boolean"),
SMS_Class_ID("MICROSOFT|YourClass|1.5")]

In general you have to declare 2 times your classes, so they can be esxecute on 32bits and 64 bits environnments.

Thanks again for your articles they show me the path.

I have something special how to retrieve the contents of a Sub registry key when we don't know the value and contents.

Here an example:

HKLM\SOFTWARE\MYKEY

Inside this key you have multiple value string that are not known before
so what i want is the contents of MYKEY.

(in reply to skissinger)
Post #: 8
RE: SCCM 2007 SP1 & Extend Hardware Inventory - 8/28/2008 6:23:44 AM   
skissinger


Posts: 2119
Score: 134
Joined: 9/13/2001
From: Sherry Kissinger
Status: offline
If the values within "MYKEY" are consistently named; yes, it's possible within the MOF.  Compare against gathering the values of the Uninstall regkey.  If the values within MYKEY are randomly named, I cannot think of a MOF-only way to pull data from randomly named regkeys.  You could script something though, and redirect it to other self-created always-named-the-same regkeys, and pull it in that way.

_____________________________

mofmaster@smsexpert.com (version 2007) | http://www.smsexpert.com | http://www.sccmexpert.com
My Blog
Microsoft MVP - ConfigMgr

(in reply to omangon)
Post #: 9
RE: SCCM 2007 SP1 & Extend Hardware Inventory - 8/28/2008 7:13:04 AM   
omangon

 

Posts: 6
Score: 0
Joined: 8/8/2008
Status: offline
Ok thanks for your answer.

I will build a script that populate a key with my named value.

So the 64 bits system arn't so amusing with MOF.

(in reply to skissinger)
Post #: 10
RE: SCCM 2007 SP1 & Extend Hardware Inventory - 8/28/2008 9:40:33 AM   
skissinger


Posts: 2119
Score: 134
Joined: 9/13/2001
From: Sherry Kissinger
Status: offline
LOL.  mof editing is almost never fun.  I call it "challenging" and "career building". 

_____________________________

mofmaster@smsexpert.com (version 2007) | http://www.smsexpert.com | http://www.sccmexpert.com
My Blog
Microsoft MVP - ConfigMgr

(in reply to omangon)
Post #: 11
Page:   [1]
All Forums >> [Management Products] >> System Center Products >> System Center Configuration Manager >> SCCM 2007 SP1 & Extend Hardware Inventory Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts



  
Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI

0.689