Eswar Koneti's Blog

All about Configmgr and its connected objects…….

  • About Author
      View eswar koneti's LinkedIn profile
  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 106 other subscribers

  • Awards


  • FaceBook Updates

  • Catagories

  • Meta

  • Copyright!

    All the blog posts in this website are owned by Eswar Koneti and may not be reused in any mode without prior approval of Eswar Koneti. You may quote one paragraph from the blog posts if you link to the original blog post.
    Happy Reading!

SCCM Migration report Collections with mix of users and computers

Posted by Eswar Koneti on 1st April 2013

If you are planning to migrate your SCCM 2007 environment to SCCM 2012,you may have to think about your packages,collections,OSD and other stuff.

you cannot migrate all collections from SCCM 2007 to SCCM 2012.Couple of things to note before you migrate them.

Points to note  on collection migration:

1. Collection can contain only either devices or users but not both.

2.  Every collection must have Limitation.

3.   Sub collections are no longer exists instead you have folders.

blogged couple of posts on archiving/removing packages not been used for X days that will help you to not migrate them to CM12.

In this blog,will show you how to identify the collections that has both users and computers member of it  to look at the collections if you want to take of users/Computers query before you go on migration.

Configmgr Report:

select
fcm.CollectionID ‘Collection ID’,COLL.Name
from
v_FullCollectionMembership fcm,v_Collection COLL
where fcm.CollectionID=coll.CollectionID
group by
fcm.CollectionID,COLL.Name
having
count(distinct fcm.ResourceType) > 1

Tags: , , , , , , , , ,
Posted in CM2012, Collections, ConfigMgr (SCCM), Configmgr2012, SCCM 2007, SCCM 2012, SCCM Reports, SQL Quiries | No Comments »

SCCM Configmgr How to remove SCCM Client manually without ccmsetup.exe

Posted by Eswar Koneti on 3rd January 2013

The easiest possible way to remove the sccm client is to run the command line ccmsetup.exe /uninstall from windows\ccmsetup folder.

But what if ccmsetup.exe do not exists on some of the client machines and you would require to remove the client on them ? and if ccmsetup.exe does not work for you to remove the sccm client successfully ?

Mike Griswold did a post on this how to do manual executions to remove sccm client without using ccmsetup.exe on the way at his customer place.

So You can perform below steps to manually clean-up all the traces of the client.

1. SMS Agent Host Service

 

2. CCMSetup service (if present)

 

3. \windows\ccm directory

 

4. \windows\ccmsetup directory

 

5. \windows\ccmcache directory

 

6. \windows\smscfg.ini

 

7. \windows\sms*.mif (if present)

 

8. HKLM\software\Microsoft\ccm registry keys

 

9. HKLM\software\Microsoft\CCMSETUP registry keys

 

10. HKLM\software\Microsoft\SMS registry keys

Full Post http://blogs.technet.com/b/michaelgriswold/archive/2013/01/02/manual-removal-of-the-sccm-client.aspx

Tags: , , , , , , ,
Posted in Checklist, Client Push Installation, SCCM 2007, Setup & Deployment, Trobleshooting Tips | No Comments »

SCCM Configmgr 2007 Reporting services Error ‘Cannot create a connection to data source’

Posted by Eswar Koneti on 2nd January 2013

 

When i try to run SCCM Reporting Services Report,I get error always saying ‘Cannot create a connection to data source ‘AutoGen__5C6358F2_4BB6_4a1b_A16E_8D96795D8602_’.

I verified if the user has  sufficient permissions to access the database (datasource) or not,User has enough permissions.

Error Message:

image thumb1 SCCM Configmgr 2007 Reporting services Error ‘Cannot create a connection to data source’

If you look at the above Screen shot,it says “You have specified integrated security or credentials in the connection string for the data source, but the data source is configured to use a different credential type. To use the values in the connection string, you must configure the unattended report processing account for the report server

I check the properties of Reporting server from SCCM Console under Data Source authentication Tab. I see below Settings.

image thumb2 SCCM Configmgr 2007 Reporting services Error ‘Cannot create a connection to data source’ I changed the settings from Credentials stored securely by the report server to Windows Integrated Security.

With this change,I ran the report again.It worked.

Tags: , , , ,
Posted in CM2012, ConfigMgr (SCCM), Configmgr2012, Reporting Services, SCCM 2007, SCCM 2012, SCCM Reports, SSRS | No Comments »

SCCM Report UnInstallation String for application with Count

Posted by Eswar Koneti on 24th December 2012

Various methods to get the Uninstallation String for particular application.You can go with MOF changes to get uninstall string from registry(HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall and HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall ) using Mark regkeytomof or You can use BDNA Normalize.

Now aDays ,most of the organizations are converting Applications to MSI with more customizations with unattended installation  except some applications which has msi inbuild with EXE file using Packaging Tools. More info about Packaging stuff,you can get from ttp://www.itninja.com/

You can uninstall particular application if you have MSI ID or product ID using simple Command msiexec /x {ProductID} .

If you have used MSI based application to install on the computer,this information is tracked in SCCM (ProdID is enabled in MOF file by default).

This report talks about specific application and its MSI product ID with count of machines installed on.

select distinct DisplayName0,’msiexec /x ‘+ProdID0,COUNT(*) as ‘Total’  from v_ADD_REMOVE_PROGRAMS where DisplayName0 =@Appname
group by DisplayName0,ProdID0

Prompt:

select distinct DisplayName0, Version0

I have added MSIEXEC /X to the existing product ID to save excel time icon wink SCCM Report  UnInstallation String for application with Count

If you want to list all adobe products,replace DisplayName0 =@Appname with DisplayName0 like ‘%Adobe%’

Note: Please don’t forget to change the quotes as they are fancy.

Tags: , , , , , , ,
Posted in CM2012, Configmgr2012, SCCM 2007, SCCM 2012, SCCM Reports, SQL Quiries, System Center 2012 Configuration Manager | No Comments »

SCCM Configmgr Clean Up Backlogs in Despooler.Box\Receive Folder

Posted by Eswar Koneti on 18th December 2012

SCCM Inbox Folders plays Vital Role in troubleshooting problems with different components. You should keep an Eye on the inbox folders for a backlog of files that wait to be processed.

There are various methods to monitor the inbox folders (tools/Scripts etc). This Post is going to be focus on Despooler.Box\Receive and clean up files residing older than 30 days.

Despooler.box\Receive stores the data that is received from a child site or a parent site and process it accordingly.Typically, files are processed and moved as soon as Configuration Manager 2007 receives the instruction file (.ins file).

In Short about what despooler does is  Despooler component receives the data and hands it off to Replication Manager component then Replication Manager hands the data to the appropriate component to process further.

But Due to some Reasons,Packages which are sending from hierarchy to child sites stuck and breaks the thread and it again starts sending from beginning.Because of this,files remains in Receive folder without being processed for longer time.

If you are in small environment (less than 10 sites or so) you can check it manually by looking at Despooler.Box\Receive what files are Old based on modified date and remove them.

Here is simple VB script that looks for the folder name and get file name,Size and modifieddate. If the Despooler is receiving any files from its parent, you get current date.

Set fso = CreateObject(“Scripting.FileSystemObject”)
Set objinputfile=fso.OpenTextFile(“C:\Scripts\Servers.txt”,1,True)
Set objoutputfile=fso.OpenTextFile(“C:\Scripts\Results.csv”,2,True)
Do While Not objinputfile.AtEndOfStream
strcomputer=objinputfile.ReadLine
Set recive = fso.GetFolder(“\\” & strComputer & “\Driveletter$\SCCM\inboxes\despoolr.box\receive“)
Set colFiles = recive.Files
For Each objFile in colFiles

objoutputfile.WriteLine strComputer & vbTab & objFile.Name & vbTab & objFile.size & vbTab & objFile.DateLastModified

Next
loop
msgbox(“done”)

Note : If you have sccm installed on different Drives with different folder names without unique ,this script may not be helpful to you.

Provide all the site names to servers.txt and results will be piped to results.csv file.

Once you get the results,you can sort it with File Size and Modifieddate to take further action.

I would prefer to delete the files from receive folder older than month.

Here you go with the script to delete files from despoolr.box\receive older than 30 days:

 

Set fso = CreateObject(“Scripting.FileSystemObject”)
Set objinputfile=fso.OpenTextFile(“C:\Scripts\desplooer-servers.txt”,1,True)
Set objoutputfile=fso.OpenTextFile(“C:\Scripts\despooler-results.csv”,2,True)
Do While Not objinputfile.AtEndOfStream
strcomputer=objinputfile.ReadLine

Set objWMIService = GetObject(“winmgmts:\\” & strComputer)
If Err.Number <> 0 Then
objoutputfile.WriteLine (strcomputer & ” is not Up or problem in connecting to WMI”)
Err.Clear
Else
strDays= 30
Set recive = fso.GetFolder(“\\” & strComputer & “\f$\SMS\inboxes\despoolr.box\receive”)
Set colFiles = recive.Files
For Each objFile in colFiles
If DateDiff(“d”, objFile.DateLastModified, Date) > strDays Then
fso.DeleteFile(objFile)
objoutputfile.WriteLine strComputer & vbTab & “Deleted”
end if

Next
end if
loop
msgbox(“done”)

Until then !

Tags: , , , , , , ,
Posted in CM2012, ConfigMgr (SCCM), Configmgr2012, Distribution Point, Replication, SCCM 2007, Scripting, Secondary Site, Setup & Deployment, System Center 2012 Configuration Manager, Trobleshooting Tips | No Comments »

SCCM Patch Compliance LastState,statename

Posted by Eswar Koneti on 14th December 2012

when you SCCM patch deployment ,State of the patch status are sent back to SCCM .Below are the available LastStates for the patches when they are deployed.

Using Laststate/LastStateName from View v_GS_PatchStatusEx ,you can create variety of reports to know the status of the any patch package.

 

LastState LastStateName
0 No Status
101 Failed
102 Reboot pending
105 Install Verified
107 Preliminary Success

 

couple of Patch Compliance reports based on laststate/Laststatename are 

SCCM Patch Compliance Progress report:  http://eskonr.com/2009/10/patch-status-compliancesoftware-updates-report-in-sms-sccm/

Software Update Compliance Status on Specific Collection : http://eskonr.com/2009/09/report-for-software-update-report-for-software-update-compliance/

SCCM monthly Patch statistics report http://eskonr.com/2011/10/sccm-monthly-patch-statistics-reports-to-the-management-in-a-simplified-manner/

Tags: , , , ,
Posted in Patch Reports, SCCM 2007, Software Updates, SQL Quiries | No Comments »

How to get AD computer info into #SCCM / #Configmgr 2007/2012 Database ?

Posted by Eswar Koneti on 11th December 2012

Getting AD information into SCCM Database can be done using AD discovery Methods From SCCM Configmgr but there are cases where in some of the computers may not be discovered or Computers do not exist in AD but do available in SCCM Database.

I used MaikKoster Old blog post as reference and made some customizations/Updates in the query to retrieve information about only Active Computers (Exclude disabled Machines).

Comparing AD Computer information with SCCM Database sometimes interesting to know about client health and are there any missing out clients did not discover into SCCM Database.

This also helps you to focus more on clients inventory issues .There are cases where in User will be logged into domain(last logon timestamp) but client will not report to site .With this you can create hardware inventory report for computers not reported with in X number of Days with AD last logon Timestamp.(if your discovery is not customized and run frequently).

You can use this procedure in SMS 2003, SCCM 2007 and SCCM 2012 environments.

Updated : Please be clear what information do you want to retrieve from AD into SCCM Database in the initial phase else you may lead to an issue to update the existing table with custom values.

I tried adding more attributes from AD to the existing SQL Job what is already been created but i failed . I have to drop the table ,Change the query and run the job to make it Work.

This procedure requires you to download Log Parser (http://www.microsoft.com/en-us/download/details.aspx?id=24659) and install it on CM server.If your SQL hosting on different Box,Install it on SQL Box with default settings (next,next,next,close icon smile How to get AD computer info into #SCCM / #Configmgr 2007/2012 Database ? )

Start SQL server Management Studio

image thumb7 How to get AD computer info into #SCCM / #Configmgr 2007/2012 Database ?

Move onto SQL server Agent—>Jobs—>Create New Job

image3 thumb How to get AD computer info into #SCCM / #Configmgr 2007/2012 Database ?

On the General Tab,Enter the required Fields as per appropriate.

image67 thumb How to get AD computer info into #SCCM / #Configmgr 2007/2012 Database ?

Move to Next tab Steps .This is the step where you Create Job to execute and get AD computer Information into SCCM Database.

Click on New

image61 thumb How to get AD computer info into #SCCM / #Configmgr 2007/2012 Database ?

You are prompted to select Different fields like Step Name (AD info), Type(ActiveX Script) and Run as(SQL server Agent Service Account).

Next is to import the the script to execute. Download the Script from Maikkoster website here and Import it using Open.

image21 thumb How to get AD computer info into #SCCM / #Configmgr 2007/2012 Database ?

Once you are imported , you are required to supply values for the below Objects :

strLDAP = “LDAP://eskonr.com
strSQLServer = “sccmSQL
strDatabase = “SMS_CEN
strTable = “ADComputersInfo

Note: Strtable is Table not view

Replace the below customized query with existing One after ‘ Create query text

strQuery = “SELECT cn, objectpath, operatingSystem, operatingSystemServicePack”
strQuery = strQuery & “, CASE LastLogonTimestamp WHEN 0 THEN NULL ELSE ”
strQuery = strQuery & ” TO_TIMESTAMP(ADD(DIV(TO_REAL(LastLogon), 10000000.0), TO_REAL(TIMESTAMP(’1601′,’yyyy’)))) END AS [LastLogon]”
strQuery = strQuery & “, CASE pwdLastSet WHEN 0 THEN NULL ELSE ”
strQuery = strQuery & ” TO_TIMESTAMP(ADD(DIV(TO_REAL(pwdLastSet), 10000000.0), TO_REAL(TIMESTAMP(’1601′,’yyyy’)))) END AS [PwdLastSet]”
strQuery = strQuery & ” INTO ” & strTable & ” FROM”
strQuery = strQuery & “‘” & strLDAP & “‘” & ” where ”
StrQuery = strQuery & “userAccountControl” & “=” & “4096″

Note : You can do customizations to the above query depends on your requirement.

“Please replace the Quotes as the blog converts them to fancy ”

Click Ok.

Go to Schedule Tab,Click New

image53 thumb How to get AD computer info into #SCCM / #Configmgr 2007/2012 Database ?

Schedule it as per the requirement.

image27 thumb How to get AD computer info into #SCCM / #Configmgr 2007/2012 Database ?

Click on Ok, OK

Start the job which we created now.

image33 thumb How to get AD computer info into #SCCM / #Configmgr 2007/2012 Database ?

You see from below,Job is executed successfully.

image36 thumb How to get AD computer info into #SCCM / #Configmgr 2007/2012 Database ?

Now its time to create Various reports based on your needs.

Simple report to list Computers which are not available in SCCM but do Exist in AD as Active.

SELECT [cn] AS ‘Computer Name’
,[ObjectPath] AS ‘Path’
,[operatingSystem] AS ‘OS’
,[operatingSystemServicePack] AS ‘SP’
,[LastLogon]
,DATEDIFF(dd, [LastLogon], getdate()) AS ‘days LastLogon’
,[PwdLastSet]
,DATEDIFF(dd, [PwdLastSet], getdate()) AS ‘days PwdLastSet’
FROM [DatabaseName].[dbo].[tablename]
WHERE cn NOT IN (SELECT name0 FROM v_GS_Computer_System)
ORDER BY LastLogon

Replace the Database name and table what you given in VB Script earlier.
Until Next !

Tags: , , , , , , , , ,
Posted in CM2012, ConfigMgr (SCCM), Configmgr2012, SCCM 2007, SCCM 2012, Scripting, Setup & Deployment, System Center 2012 Configuration Manager | 7 Comments »

SCCM Package replication issue A newer version of package has already arrived, delete the replication file

Posted by Eswar Koneti on 7th December 2012

Another interesting package replication problem.John Marcum posted solution on his blog with DB edit but that did not solve my problem though package issue is similar.

I have to do couple of more things to fix the issue what John said in his blog. Am not going to explain more about why it happens etc. If you interested,Read Johns Blog.

When you do Preload for Bulk number of PCK file,Sometimes you may not succeeded in decompressing all the files and arise issues like below from distmgr.log .

From the console,if you look at package status,you end up with Install pending .

The error message from distmgr.log :

“A newer version (21) of package xxx000C1 has already arrived, delete the replication file F:\SMS\inboxes\distmgr.box\INCOMING\4EE5A01M.PCK for version 19”

image thumb4 SCCM Package replication issue A newer version of package has already arrived, delete the replication file

Tried refreshing the package ,removing from DP and Reading ,did not help.

In order to fix this error,i have to do couple of things . 1) Edit the Database 2) Delete the files from pkginfo.box,distmgr.box

Note : Directly editing the DB is not supported unless you really know what you are doing else do not proceed. and ensure you have Database Backup before you do this.

1) Edit DB to change the PCK Source Version to 0.

Update PkgStatus

Set Status = ’2′, SourceVersion = ’0′

Where ID = ‘P01005DC’ and sitecode=P01′ and type=’1′

If this is child site and reporting to another Site,Do the same procedure until you reach Central site.

As per John Article,After refreshing the package,it did not succeded and it still gives me the same error .If John procedure works, Well and Good else Follow the below step to fix it.

2) Next delete the package files from pkginfo.box(ICO,NAL,PKG) and distmgr.box(PKG) for the specific package.

Now Refresh the package from central/Primary where it is created and monitor Distmgr.log file on problem site.

You see something like below after package refresh replication to problem site.

Updated Replicated package server 

Updated replicate package program info for package

Successfully processed .PKG file

image thumb5 SCCM Package replication issue A newer version of package has already arrived, delete the replication file

Also you see something like below

The compressed files for package P01XXXXX hasnt arrived from the site P01 Yet, will try later

image thumb6 SCCM Package replication issue A newer version of package has already arrived, delete the replication file

Preload the latest PCK file now using Preloadpkgonsite tool, You will see the decompress of the package

Tags: , , , , , , , , ,
Posted in ConfigMgr (SCCM), Distribution Point, Replication, SCCM 2007, Software Distribution, Troubleshooting Issues | No Comments »

#SCCM /#Configmgr Failed to insert SMS Package because SDM Type Content is not present in the CI_Contents table. Will try later

Posted by Eswar Koneti on 5th December 2012

Recently I had major issue while replicating the patch packages to sites and they started experiencing the problem to process the patch information (CID and SDMpackages).

I am really not sure if this is because of recent MS patch released in October 2012,More info can be found here  ,due to this,all the revised updates (which you can see from WSUS console )went back downloaded=No from Downloaded=Yes .

Later month Ago,MS released fix for this to get the issue sorted out also some other functions more here http://support.microsoft.com/kb/2783466

Below is the Error message which I get on problem site (distmgr.log) and unable to insert the Patch info into Database.The reason I tell you below why it is not.

Failed to Insert SMS package CEN00XXX because SDM type Content xxxxxxxxxxxxx-xxxx-xxxx-xxxxxxxxxxxxxxxxx is not prensent in CI-Contents Table,will try later

 

from objreplmgr.log :

Processing replication file F:\SMS\inboxes\objmgr.box\INCOMING\Retry\Sitecode_66082.CID in retry.

SDM Package Name Site_B97EB0D1-435F-4CEC-88B7-5A1E7645B585/SUM_07f87a3d-23b3-4ec1-b35c-6461a82ded35 Version 2 has not arrived yet. Will retry

Failed to insert Object 07f87a3d-23b3-4ec1-b35c-6461a82ded35 from replication file F:\SMS\inboxes\objmgr.box\INCOMING\Retry\Sitecode_66082.CID.

Problem site is looking for object 07f87a3d-23b3-4ec1-b35c-6461a82ded35 with version 2 which is not arrived.

Before you follow this guide,I would suggest you to read steve Rachui Blog explaining about Software updates and process Part1 and Part 2.Thanks to Steve for nice explanation on software updates and CI.

*************This post is more of Database Editing to fix the issue and no warranties provided. If you don’t know what you are doing /without enough information,you are at Risk**************

To check how many CIDs left over to process, check it from inbox folders . Path \Inboxes\objmgr.box\incoming\retry

If the CID files are processed max number of times,they are moved to retry\bad folder.

To get all SDMpackage names,try to filter the log with word “SDM Package Name” ,you may get bulk number of IDs out of which some of them are Repeated.

Copy the SDM package names to Excel and remove duplicates.

Copy the results to excel and remove the duplicates. You now have all SDM packagenames.

I have something below from the log/Excel after removing duplicates.

Site_B97EB0D1-435F-4CEC-88B7-5A1E7645B585/SUM_0d9f9145-9e83-4c44-a8d5-9decbe25a586

Site_B97EB0D1-435F-4CEC-88B7-5A1E7645B585/SUM_cc5d5d63-32bb-4593-bd6f-3b61ba97707f

Site_B97EB0D1-435F-4CEC-88B7-5A1E7645B585/SUM_f4ba81de-c60b-4e2f-9589-9cc888bc09da

If you want to know more about what it says,Please Refer Steve blog.

Let’s have a look at Database on problem site and its parent site to see what information they contain and are they really out of sync ?

I take an example with central,Parent and child

Take the first ID :0d9f9145-9e83-4c44-a8d5-9decbe25a586

If I run the below query on central DB ,I get below results :

select * from CI_SDMPackages WHERE (SDMPackageName like ‘%0d9f9145-9e83-4c44-a8d5-9decbe25a586%’)

clip image004 thumb #SCCM /#Configmgr Failed to insert SMS Package because SDM Type Content is not present in the CI Contents table. Will try later

Problem Parent :clip image006 thumb #SCCM /#Configmgr Failed to insert SMS Package because SDM Type Content is not present in the CI Contents table. Will try later

Problem site :clip image008 thumb #SCCM /#Configmgr Failed to insert SMS Package because SDM Type Content is not present in the CI Contents table. Will try later

Look at problem site, it still has version 1 and IsDeleted value is not set to 1 and it does not have latest Version =2.

How do we fix it ?

We will change the LastModifiedData and set Isdeleted=1 for these error Objects on central and let the sync happens with child sites.

Set the DateLastmodified on Central DB:

UPDATE CI_ConfigurationItems SET DateLastModified = GETDATE() WHERE CI_UniqueID in (

‘0d9f9145-9e83-4c44-a8d5-9decbe25a586’,

‘cc5d5d63-32bb-4593-bd6f-3b61ba97707f’,

‘f4ba81de-c60b-4e2f-9589-9cc888bc09da’)

UPDATE CI_SDMPackages SET DateLastModified = GETDATE() WHERE (

SDMPackageName like ‘%0d9f9145-9e83-4c44-a8d5-9decbe25a586%’ OR

SDMPackageName like ‘%cc5d5d63-32bb-4593-bd6f-3b61ba97707f%’ OR

SDMPackageName like ‘%f4ba81de-c60b-4e2f-9589-9cc888bc09da%’ )

Run the below query on problem site to Fix isdeleted=1 for the older version and let the current version sync.

update ci_sdmpackages

set IsDeleted = 1

WHERE (

SDMPackageName like ‘%0d9f9145-9e83-4c44-a8d5-9decbe25a586%’ OR

SDMPackageName like ‘%cc5d5d63-32bb-4593-bd6f-3b61ba97707f%’ OR

SDMPackageName like ‘%f4ba81de-c60b-4e2f-9589-9cc888bc09da%’ )

and SDMPackageVersion = ’1′

Let’s wait for couple of hours to sync the modified data with problem site.

So here is the outcome on problem Site after couple of hours

clip image010 thumb #SCCM /#Configmgr Failed to insert SMS Package because SDM Type Content is not present in the CI Contents table. Will try later

Now move the .CID file back to objmgr.box\incoming folder from retry folder to process it and monitor objreplmgr.log if that succeeds or not.

Note :This procedure is recommended only if you have less objects failed rather going with synchild/.sha that generates huge traffic .If more objects failed to process, go with synchild/.sha non-office hours.

Detailed information available here on http://blogs.technet.com/b/mwiles/archive/2011/06/24/troubleshooting-failed-to-insert-object-error-message.aspx

Tags: , , , , , , , , ,
Posted in Replication, SCCM 2007, Software Updates, Trobleshooting Tips, Troubleshooting Issues | No Comments »

SCCM report Domain Controllers with IP Address

Posted by Eswar Koneti on 5th December 2012

SCCM report for Domain Controllers with RAM,Operating System,IP Address etc.

Full Details : http://social.technet.microsoft.com/Forums/en-US/configmgrreporting/thread/0dedf567-7bbd-4c36-bc7a-12c409a79618

SELECT

      sys.Name0 AS ‘System Name’,

      os.Caption0 AS ‘Operating System’,

      os.CSDVersion0 AS ‘Service Pack’,

      PM.TotalPhysicalMemory0 /1024 as ‘RAM in MB’,

      OS.InstallDate0 AS ‘Original OS Install Date’,

      os.LastBootUpTime0 AS ‘Last Boot Time’,

      NAC.IPAddress0 AS ‘IP Address’,

      NAC.IPSubnet0 AS ‘Subnet Mask’

FROM

      dbo.v_GS_NETWORK_ADAPTER_CONFIGUR NAC

INNER JOIN dbo.v_GS_OPERATING_SYSTEM OS ON NAC.ResourceID = OS.ResourceID

INNER JOIN dbo.v_GS_PC_BIOS BIOS ON NAC.ResourceID = BIOS.ResourceID

INNER JOIN dbo.v_GS_SYSTEM sys ON NAC.ResourceID = sys.ResourceID

INNER JOIN dbo.v_GS_COMPUTER_SYSTEM CS on NAC.ResourceID = CS.ResourceID

INNER JOIN dbo.v_GS_X86_PC_MEMORY PM on NAC.ResourceID = PM.ResourceID

Where

      NAC.IPaddress0 is Not Null

and CS.Roles0 like ‘%Domain_Controller%’

 

Note : Blog converts the quotes to fancy, Please replace them.

Tags: , , , , , , , , , ,
Posted in SCCM 2007, SCCM Reports, SQL Quiries | No Comments »