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 client status message

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

Logged in as: Guest
  Printable Version
All Forums >> [Scripting Technologies] >> VB Script >> sccm client status message Page: [1]
Login
Message << Older Topic   Newer Topic >>
sccm client status message - 5/9/2008 9:15:33 AM   
i.samarelli

 

Posts: 11
Score: 0
Joined: 5/9/2008
Status: offline
In the SCCM SDK I read that is possibile to talk directely with the SCCM Client in ordert to send some status message back to the server during an Advertisment.
At the moment I can only contact the MP via SMSAPI or via WMI, but this has a big disadvantage:
- I need to  tell the program which MP to contact (while the SCCM Client already know it!)
- I need to pass user/pwd to the MP
The SMSApi is not good for my case because I need to insert a lot of clients configuration.
By using the SMSEvent messages it seems that a program con connect to SCCM Client and send its messages to the SCCM Server without problem: if a MP failed the SCCM Client would try to find another one. Even the authentication would be very better.
I would like to use this tecnique in order to send a list of messages to the SCCM Server after I Advertised a Task Sequence.
Unfortunately the documentation is very poor and missing of further information/examples: can anyone help me?

Thx
Ignazio

Post #: 1
RE: sccm client status message - 5/9/2008 5:01:11 PM   
mseely

 

Posts: 40
Score: 1
Joined: 5/4/2008
Status: offline
Here is a sample ...

Mark

---


Set oEvent = CreateObject("Microsoft.SMS.Event")
oEvent.EventType = "SMS_GenericStatusMessage_Info"
oEvent.SetProperty "Attribute401","Test1"
oEvent.SetProperty "Attribute402","Test2"
'Attributes go from 400-404  [Not all need to be used in a message]
'400 is generally PackageID
'401 is generally AdvertID
'402 is generally CollectionID
'403 is generally User Account initiating action
oEvent.SetProperty "InsertionString1","Info1"
oEvent.SetProperty "InsertionString2","Info2"
oEvent.SetProperty "InsertionString10","Watermark"
'InsertionStrings go from 1-10.
'The insertionstrings are the strings which would usually be entered into the string that shows up when you view the status messages in the sms console.
'Since The mesaage is a generic message, I usually use one of the insertionstrings as a 'watermark' 
'   so that when I'm querying the statusmessages i can find the ones relating to what i'm looking for.
oEvent.Submit

(in reply to i.samarelli)
Post #: 2
RE: sccm client status message - 5/12/2008 10:52:02 AM   
i.samarelli

 

Posts: 11
Score: 0
Joined: 5/9/2008
Status: offline
Thank you very much for your quick response.
I can now generate the status message, but even if I try inserting something as description (using InsertionStringN) I cannot see them from the MGMT Console.
As far as I understood I should create a resource DLL that expose the structure of my message, then the InsertionString1 to 10 act as parameter for my message.
I've tried to look at the SMS SDK, but I did not find any sample or detailed documentation about that.
As an example I do not know how to call this DLL, how to structure it, and so on...

Do you know where can I find such information?
Thx
IGnazio

(in reply to mseely)
Post #: 3
RE: sccm client status message - 5/15/2008 11:43:29 AM   
lgharda

 

Posts: 1
Score: 0
Joined: 5/15/2008
Status: offline
Dear Ignazio,
have discovered anything new about this topic? I am also trying to add the discription but fail to do so.
Kind regards
Benno

(in reply to i.samarelli)
Post #: 4
RE: sccm client status message - 5/15/2008 11:56:34 AM   
i.samarelli

 

Posts: 11
Score: 0
Joined: 5/9/2008
Status: offline
Hello, unfortunately I had no luck.
Due I had to search in the old SMS Documentation I decided to search in the old MSDN (2001/2003) and hope to find out more information about this topic (hopefully better an example).

BTW I will post a reply in case of success
Ignazio



(in reply to lgharda)
Post #: 5
RE: sccm client status message - 5/15/2008 1:52:48 PM   
mseely

 

Posts: 40
Score: 1
Joined: 5/4/2008
Status: offline
Using the Generic Status messages, there won't be a way to get the insertion strings to show up in the console's Statusmessage section  section as is.

When using the generic statusmessages, I usually create a customized query/report which picks up the genericstatusmessages, filters using the watermark, and displays the information as I want it.   

I will see if I can find a sample query.

(in reply to i.samarelli)
Post #: 6
RE: sccm client status message - 5/15/2008 3:21:55 PM   
i.samarelli

 

Posts: 11
Score: 0
Joined: 5/9/2008
Status: offline
Hello, I'm not so sure that I cannot populate the Description field of the custom status message because if you use the WMI provider you can do it. The problem is that the WMI provider needs the connection first to authenticate the SMS Provider and then all your clients would use user/name and password that are very dangerous for maintenance and also for the secuity as well.

I think your example would be very helpful!

Thx
Ignazio

(in reply to mseely)
Post #: 7
RE: sccm client status message - 5/20/2008 12:49:07 PM   
beiwen

 

Posts: 1
Score: 0
Joined: 5/20/2008
Status: offline
Hello Ignazio,

I had promised to tell you when I would find a solution.

First: I think there is no way to get the text showing up when you use the SMS_GenericStatusMessage_Info. As far as I figured out, you have to send a raw message, so that you can map it to a custom message dll. The raw message cannot be send through the automation object (at least I did not find a way). Somewhat rudimentary details about the custom message dll are only available with the 2003 SDK.
Althoug the solutions is now more complicated that you vb script, it works and depends only on the CCM client - no need for a connection to the server.

What I have done:
  • I have written a class library in c# that
    • loads the smscstat.dll library
    • retrieves the function pointers for CreateSMSStatusMessage and ReportSMSStatusMessage
    • unloads the library

  • I have used the template for custom messages from the 2003 SDK to write my own custom message dll (in fact I just slightly modified it)
  • I followed the instructions in the readme from the template to deploy the custom message dll

For the class library I used the sample form this post: http://forums.microsoft.com/TechNet/ShowPost.aspx?PostID=3144409&SiteID=17
- actually you should now this ;-)

Kind regards
Benno

(in reply to i.samarelli)
Post #: 8
Page:   [1]
All Forums >> [Scripting Technologies] >> VB Script >> sccm client status message 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.359