Category Archives: OSD

SCCM 2007 – OSD Configuration – Task Sequence WMI Query for Lenovo ThinkPads

During the imaging process, it becomes necessary to provide WMI queries within task sequences in order to differentiate between computer models. Typically, this is accomplished by utilizing the following query within a conditional statement inside a task sequence task item:

SELECT * FROM Win32_ComputerSystem WHERE Model = “[model name from WMI]”

Unfortunately, if you are using Levono products, this can have multiple values for the same computer familiy. (i.e.  the ThinkPad X61 has several different model “numbers,” none of which have the label “ThinkPad X61”.) In order to provide a query which will yield the commonly used model “name” for Lenovo Thinkpads, use the following query:

SELECT * FROM Win32_ComputerSystemProduct WHERE Version = “ThinkPad [model number]”

(i.e. SELECT * FROM Win32_ComputerSystemProduct WHERE Version “ThinkPad X200”)

It is also very handy to keep a spreadsheet of all the model numbers and corresponding model names for use in reporting CASE statements to make your reports easier for management to decipher.

SCCM 2007 – OSD Troubleshooting – Task Sequence has failed with the error code (0x80091007)

So everything is working fine and all of the sudden I receive the following error during the preliminary injection of a laptop model into my task sequence:

Task Sequence: TS: Windows XP w/SP3 – Model Injection has failed with the error code (0x80091007). For more information, please contact your system administrator or help desk operator.

So, I pick up the phone and dial myself.

As per just about every post I could find, I verified that all drivers necessary for pre-boot were injected into the boot image, that all necessary post-image drivers had been imported into SCCM and that they had properly replicated to all DP’s. No red flags there. I checked my task sequence (which for this particular purpose, only images and installs good and bad drivers… post image software layering is disabled… otherwise, it’s identical to my production TS.) No red flags there either.

Four days of repeated troubleshooting. I deleted the image package and re-created it – again waiting for replication to finish before changing the TS to reflect the new package name. No change.

Then, as I was explaining to someone why the OSI model is so important to troubleshooting network problems, a lightbulb appeared over my head…..

I replaced the hard drive and it works perfectly…….

The purpose of this post? Before you bang your head against a table long enough to form a permanent dent, pay your respects to the physical aspects of your work environment.

 

Nuff said….

SCCM 2007 – OSD Troubleshooting – SMS_PXE_SERVICE_POINT Message ID: 6314

Just a short note for those of you (like me) who are continually ensuring that you have the latest drivers working in your OSD environment – whether or not you adopt them. I have multiple task sequences devoted to model injection – primarily because drivers are being constantly updated as problems are resolved by vendors. Personally, I like to make sure that these drivers can be added to the system without causing problems elsewhere.

One issue I run into every so often occurs when I am repeatedly reimaging a specific model to test new drivers. I haven’t quite nailed down the cause of the issue, but I have figured out how to get past it so I can continue working.

Issue:  When imaging a specific machine multiple times and then leaving the machine information in SCCM overnight, regardless of whether you have cleared the last pXE advertisement, the machine will act as those this flag is not cleared. The machine can be deleted from SCCM, recreated, let the deletion sit overnight, etc – and the advertisement will not clear.

Reason:  It seems as though the cache on the WDS server is retaining the data from the machine in question and it is actually preventing the boot and subsequent imaging process from taking place. A message will be received in SMS_PXE_SERVICE_POINT status messages stating “The SMS PXE Service Point intructed device to boot normally since it has no PXE advertisement assigned.” (NOT my spelling… the message actually says “intructed”)

Resolution:  Restart the WDS service on the pXE server. This clears the cache and allows the box to pXE boot and image.

SCCM 2007 – OSD Troubleshooting – Task Sequence WMI queries on computer models returning false results

I’ve written a few items concerning adding WMI queries to driver packages within the OSD task sequences within SCCM2007. Recently I hit a snag which was somewhat perplexing until I decided to browse the WMI with several different tools.

Generally, I’ve taken to browsing the WMI on various computers models with SCCM Client Center as it is very good, all-purpose tool. As I was building a model injection task sequence for Windows 7 (x64) I discovered that none of my WMI queries for Win32_ComputerSystem.Model were functioning. Where they had performed flawlessly in Windows XP they were failing in Windows 7.

For example:

Running the following query on an OptiPlex 755 returned a 0 value. (I’m using a 755 so testing the query locally via the SCCM console was a good method of verification.)

SELECT * FROM Win32_ComputerSystem WHERE Model = “OptiPlex 755”

For testing purposes, I changed the = to a LIKE and just left the remainder as “OptiPlex%” which returned a positive result. Additionally, changing the remainder to “OptiPlex 755%” also yielded a positive result. At this point I knew that something was different in the way this particular class was either registered within Windows 7 or something was different in the way it was read.

Using SCCM Client Center yielded a value of “OptiPlex 755”. I decided to go download the old WMI Administrative Tools app from Microsoft (located – http://www.microsoft.com/downloads/details.aspx?FamilyID=6430f853-1120-48db-8cc5-f2abdc3ed314&displaylang=en) to see what it would yield. Lo and behold, the value was “OptiPlex 755 ” – the spaces being 17 in total. I tested this by inserting 17 spaces into my query and the result came back positive.

My recommendation at this time, in order to save people the trouble of checking each model in their environment for the number of spaces, is to change the query to the following: (insert your computer model where OptiPlex 755 is in the query below)

SELECT * FROM Win32_ComputerSystem WHERE Model LIKE “OptiPlex 755%”

If this fails on any particular machine, I will post here, and would appreciate readers doing the same.

SCCM 2007 – OSD Configuration – Naming Conventions and Task Sequence Queries

I was working on a task sequence consolidation this morning and thought I would throw this one out there in case anyone else has a similar situation.

In our environment, we have several applications which require location-specific parameters… basically, the developers have created different configuration files which are based on the site location of the end-user. If you use task sequences for both OSD and application deployment, this should work for you as well, depending upon your machine naming convention. I prefer to use a convention which is organized as such:

[Location Acronym][Unique Identifier][Departmental Acronym]

i.e. and machine in Austin with a serial number of 123456 and a department of Technology would be AST123456TECH – just an example

Although the application programs have dependencies, the configuration program is the last step in the process. So, I have created the first two dependency programs and then configuration programs for each location dependent upon the last program in the dependency chain. All of these are placed in the same task sequence, in order of dependency, and then I use a WMI query to ensure that the proper configuration program is run at the end of the chain based on machine name. (Machine name just happens to be convenient for us, but you could use this same technique for anything obtainable in the WMI which could be used as a locational identifier.)

Query used for the Austin configuration program:

SELECT * FROM Win32_ComputerSystem WHERE Name LIKE “AST%”

You can follow the results in the SMSTS.log file: (I’ve taken out the time stamps)

Query = SELECT * FROM Win32_ComputerSystem WHERE Name LIKE “AST%”
Expand a string: root\cimv2
Expand a string: SELECT * FROM Win32_ComputerSystem WHERE Name LIKE “AST%”
The WMI condition expression is evaluated to be TRUE
The AND expression is evaluated to be TRUE
The condition for the action (Install – [Location Configuration Program] – AST) is evaluated to be true

Really pretty simple when you look at it, but quite handy for consolidation.