How to detect and fix an abnormal client

Hello,

In my environment there is some abnormal client (there is only few actions in the client actions or its blank and in the sccm console the client is no or null)


Usually we run a script to rebuild the wmi repository and it fix that and if it doesn't, we uninstall and install the client.

the script:

net stop ccmexec

net stop winmgmt

del %windir%\system32\wbem\Repository

cd %windir%\system32\wbem
for /f %%s in ('dir /b *.dll') do regsvr32 /s %%s

for /f %%s in ('dir /s /b *.mof *.mfl') do mofcomp %%s

net start winmgmt

net start ccmexec

now my question is how can we detect when the client is abnormal(on the client)? (run a startup script?)

thanks a lot,

Gal

December 15th, 2013 4:17pm

Hi,

Either run a startup script, it is however hard to detect WMI problems and deleting the repository the way you do it above is not really a good idea(and supported) either as it can break applications. Have a look at Jason's startup script it can run wmdiag and give you a good idea of the state as well.

http://blog.configmgrftw.com/?page_id=349

Together with that use the Client status reporting that is available for SCCM 2007,http://technet.microsoft.com/en-us/library/cc161956.aspx and use the reports as a part of your overall client health plan.

regards,
Jrgen

Free Windows Admin Tool Kit Click here and download it now
December 15th, 2013 4:42pm

There is no need to check the abnormality from the client end as you will be able to see it as Non-Client when it doesn't report its inventory for certain period and also you can get it via querying through the DB..

What I ll suggest is create a query based collection to get the list of computers that did not report its hardware inventory for certain period of time, and you could get the troublesome clients..

Below query can be used to get the computers based on the its reporting time, change the day as per your convenience..

select SMS_R_SYSTEM.ResourceID,SMS_R_SYSTEM.ResourceType,SMS_R_SYSTEM.Name,SMS_R_SYSTEM.SMSUniqueIdentifier,SMS_R_SYSTEM.ResourceDomainORWorkgroup,SMS_R_SYSTEM.Client from SMS_R_System where SMS_R_System.ResourceId not in (select ResourceID from SMS_R_System where AgentName in ("Heartbeat Discovery") and DATEDIFF(day,AgentTime,GetDate())<=12)

Run the below query to get it from DB, change the collection it to your all systems, and the days required..

Declare @CloTbl table
(
      [Associate ID] varchar(25),
      [Computer Name] varchar(25),
      [SiteCode] varchar(5),
        [LastHWScan] varchar(255),
       [Days Since HWScan] int
)

insert into @CloTbl select * from(
select Sys.User_Name0 as 'Associate ID',SYS.Netbios_Name0 as 'Computer Name', SIS.SMS_Installed_Sites0 as 'SMS Site', WS.LastHWScan, 
DATEDIFF(day,WS.LastHWScan,GETDATE()) as 'Days Since HWScan' from v_R_System as SYS
join v_GS_WORKSTATION_STATUS WS on SYS.ResourceID = WS.ResourceID
join v_RA_System_SMSInstalledSites SIS on SYS.ResourceID = SIS.ResourceID
join v_fullcollectionmembership coll on SYS.ResourceID =coll.ResourceID
join v_GS_OPERATING_SYSTEM sys1 on SYS.ResourceID =sys1.ResourceID
WHERE coll.CollectionID = 'CA1000AA')P

select * from @CloTbl
where [Days Since HWScan] >'9'
order by [Days Since HWScan]

Hope it suffices..

December 16th, 2013 7:59am

thank you all!

this is very helpful

Free Windows Admin Tool Kit Click here and download it now
December 17th, 2013 4:34pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics