Added Functionality - Count files in the inboxes\despooler.box\receive folder

Sep 18, 2012 at 11:34 PM

I use the tool for a few things and it works great especially as we have 2100 Secondaries. I have added a function to count files in the inboxes\despooler.box\receive folder as we see our Secondaires occassionally not processing these and it is difficult to view centrally and the SCOM guys havent added an Alert yet.

So under 'Other Actions' I added 'Despooler File Count' in the HTML. The function looks like this :

  ' ~~~~~~~~~~~~~~
 ' Get Despooler Count 
 Function actionDespoolerCount(remoteComputer)
 
  Set colFiles = objWMIService.ExecQuery("Select * from CIM_DataFile where Path = '\\SCCM\\inboxes\\despoolr.box\\receive\\' AND Drive = 'D:'")
  If err.number <> 0 Then
   statWMIerror = statWMIerror + 1
   Log " !! Failed to query CIM_DataFile WMI class! Error "&err.number&" ("&err.description&")", True, "getDespoolerCount", 3
   Exit Function
  End If
  
  fileCount = colFiles.count
  Log " ** Despooler File Count : " & fileCount, True, "getDespoolerCount", 1
  
  actionDespoolerCount = fileCount
  
 End Function

 

Sep 23, 2012 at 10:21 PM

Thank you, Darren

This is great contribution! I'm not going to make a new release just yet. If there will be more additions, I can gather them together. Until then, I believe anyone interested in such functionality can either implement it themselves using your code, or post a +1 request in this thread to boost the release. I'll add it to issue tracker as well.