Wednesday 10 July 2013

Batch File: List a Perticular Service of All WMI Enabled Computers

@echo off
for /F %%s in (d:\Servers.txt) do (
  echo Processing %%s
  echo Processing %%s >> d:\Services.txt
  sc.exe \\%%s query netlogon >> d:\Services.txt
  echo. >> d:\Services.txt
)

No comments:

Post a Comment