counter customizable

Get Lenovo Bios Boot Order in SCCM 2007


Edit the sms_def.mof file.

Here is an example on how to create a report for the boot order of Lenovo computers. To get the necessary data for the report we need to modify the SMS_DEF.mof file to collect more data from WMI Name Space Root\WMI and Class Lenovo_BiosSetting.

First locate your sms_def.mof file located under SCCM_Install_dir\inboxes\clifiles.src\hinv and create a backup copy to a safe location. Open sms_def.mof with Notepad. At the end of the file past the following:

//================= Lenovo Bios


class Lenovo_BiosSetting : SMS_Class_Template

    [SMS_Report(TRUE),key]  string CurrentSetting;
    [SMS_Report(TRUE)    ]  boolean Active;

Save the file and then run this from a commandpromt:

mofcomp.exe path_to_file\sms_def.mof


This will read data from CurrentSetting and store it in the database as v_GS_Lenovo_BiosSetting. The database view will be created when the first inventory data are found.



Create the report

Now to create a report that will show or collected data. Create a new report with a name of your choice I use Lenovo Bios Settings in this example. Select a Category, I use Hardware – General or create a new one, press edit SQL Statement.


Copy and past the statement below into the


SELECT    at.[Netbios_Name0] AS ‘Netbios Name’
        ,[SerialNumber0] AS ‘Serial Number’
      ,bt.[SMBIOSBIOSVersion0] AS ‘Bios Version’
      ,ct.[Model0] AS ‘Model’
      ,ct.[Manufacturer0] AS ‘Manufacturer’
      ,[CurrentSetting0] AS ‘Boot Order’
  FROM [dbo].[v_GS_Lenovo_BiosSetting0] BS
inner join [dbo].[v_R_System]at on at.[ResourceID] =  BS.[ResourceID]
inner join [dbo].[v_GS_PC_BIOS]bt on bt.[ResourceID] =  BS.[ResourceID]
inner join .[dbo].[v_GS_COMPUTER_SYSTEM]ct on ct.[ResourceID] =  BS.[ResourceID]
  WHERE CurrentSetting0 LIKE ‘BootOrder,%’
  ORDER BY at.Netbios_Name0




Just click Next and use default settings on the dialogs that comes up. Now you should something like this when you run the report (if you have got any data).



This is just an example of how it could be done so this post is provided “AS-IS” with no warranties.

Be sure to test in a lab environment before you do anything in your production environment.

Mikael Karlsson posted at 2012-10-8 Category: Configuration Manager 2007, Lenovo, SCCM