Skip to content

Instantly share code, notes, and snippets.

@pavelch
Created June 7, 2016 10:15
Show Gist options
  • Save pavelch/8a4e693b4494cde2a7b0ef9898b38aba to your computer and use it in GitHub Desktop.
Save pavelch/8a4e693b4494cde2a7b0ef9898b38aba to your computer and use it in GitHub Desktop.
$ServicesAll = @('Verne Config', 'VerneController', 'VerneIndexer','Tomcat8', 'OM_Configuration_Service', 'OM_Application_Server', 'OM_Robot_Store_Service', 'OM_Steam_Manager_Service', 'OM_Task_Manager_Service', 'OMCrawlerAdapter0', 'OMCrawlerAdapter1', 'OMCrawlerAdapterWatchDog', 'CodeCrawlerAdapter')
foreach ($service in $ServicesAll) {
$Srv = Get-Service -Name $service -ErrorAction SilentlyContinue
$stat = $Srv.Status
if ($stat) {
Write-Output "$service IS: $stat"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment