SMS / SCCM Cleint health find Script

here is the Batch file script for SCCM / SMS Clients health along with Last hardware scan report sent time and lastheartbeat time stamp it will show you in the command window this will help you to know the status of Client agent.   ==================================================================================== @echo off@echo Client Version  Last Hardware Inventory  Hours Since Last HINVosql.exe -S … Read more

To Know the Collection Name based on Collection SCCM/ SMS ID

To Know the Collection Name based on Collection SCCM/ SMS ID ******************* SELECT     CollectionID, CollID, Name, Comment, OwnedByThisSite, LastChangeTime, EvaluationStartTime, LastRefreshTime, RefreshType,                       LastMemberChangeTime, MemberClassName, CurrentStatusFROM         dbo.v_Collection WHERE     (CollectionID = 'CollectionID') ************** ——————-Thanks,https://sccm07.blogspot.com/

Active Directory Scripts

Active Directory Scriptinghttps://www.microsoft.com/technet/scriptcenter/guide/sas_ads_overview.mspx?mfr=true ——————————————————————————————– rem this code creates a user account with the common name MyerKen: Set objOU = GetObject("LDAP://ou=Management,dc=NA,dc=fabrikam,dc=com")Set objUser = objOU.Create("User", "cn=MyerKen") objUser.Put "sAMAccountName", "myerken"objUser.SetInfo Attribute Default Setting pwdLastSet User must change password at next logon userAccountControl Password Not Required userAccountControl Account Disabled ———————————————————————Setting a User Account Password Set objUser = GetObject _("LDAP://cn=MyerKen,ou=Management,dc=NA,dc=fabrikam,dc=com") … Read more

VBSCRIPT To Shutdown Exchange 200x server

  ' StopService.vbs' Author Guy Thomas https://computerperformance.co.uk ' Version 2.7 – March 2005 ' —————————————-' ' Option Explicit Dim objService, objWMI, colListOfServices, intExSrvDim strExService1, strExService2, strExService3, strExService4Dim strComp, strWMIsrv '  Amend strExService if you do not have exchange e.g. Alerter strExService1 = "MSexchangeIS"strExService2 = "MSexchangeMTA"strExService3 = "MSexchangeSA"strExService4 = "MSexchangeSRS"intExSrv = 1 ' Loops through all … Read more

SCCM Client Installation Script:– batch file program

SCCM Client Installation Script:–   here is my SCCM Client Installation batch file script.   ================================================================================================================================================================================ ECHO *********** %1 runing X copy kil.exe xcopy /y kill.exe %1admin$ psexec %1 -c  kill.exe "kill.exe ccmexec.exe" ECHO *********** %1 Copy dependent files to client admin$ xcopy /y ccmsetup.exe %1admin$ ECHO *********** %1 Uninstall SCCM Cleint psexec %1 -c  kill.exe … Read more

SCCM Client: Patch Managemnt to Force Client Deployement on remote systems

To Force Client Deployment ================================================================================================================================================================       ' Set the required variables.     actionNameToRun = "Software Updates Assignments Evaluation Cycle"     ' Create a CPAppletMgr instance.    Dim oCPAppletMgr    Set oCPAppletMgr = CreateObject("CPApplet.CPAppletMgr")     ' Get the available ClientActions object.    Dim oClientActions    Set oClientActions = oCPAppletMgr.GetClientActions()     ' Loop through the available client actions. Run the … Read more

SCCM Client Discovery Data Cycle intiate on remote systems

To intiate Discovery Data Cycle run this Script:— ==================================================================================================================================================================   On Error Resume NextDim oCPAppletMgrSet oCPAppletMgr = CreateObject("CPApplet.CPAppletMgr")Dim oClientActionsSet oClientActions = oCPAppletMgr.GetClientActions()Dim oClientActionFor Each oClientAction In oClientActions If oClientAction.Name = "Discovery Data Collection Cycle" ThenoClientAction.PerformActionEnd IfIf oClientAction.Name = "Request & Evaluate Machine Policy" Then oClientAction.PerformAction End IfNext================================================================================================================================================     The above script will run on … Read more

SCCM Client SUP registry Value Check Script

To find SCCM Client have the SUP server Registry key value status   This script will check Weather the Client system is scanning properly with SUP server or not ============================================================================================================================================================================================================================================================ On Error Resume NextConst HKEY_LOCAL_MACHINE = &H80000002 Set Fso = CreateObject("Scripting.FileSystemObject") Set InputFile = fso.OpenTextFile("MachineList.Txt") Do While Not (InputFile.atEndOfStream) strComputer = InputFile.ReadLine Set objRegistry = … Read more

To enable remotely admin$ / default shares on remote systems

To enable remotely admin$ / default shares on remote systems This script will be useful to enable remotely admin$ shares ============================================================================================================================================ Set objExcel = CreateObject(“Excel.Application”)objExcel.Visible = TrueobjExcel.Workbooks.AddintRow = 2 objExcel.Cells(1, 1).Value = “Machine Name”objExcel.Cells(1, 2).Value = “Admin Share Exists” Set Fso = CreateObject(“Scripting.FileSystemObject”)Set InputFile = fso.OpenTextFile(“MachineList.Txt”)Do While Not (InputFile.atEndOfStream)strComputer = InputFile.ReadLine On Error Resume NextSet … Read more