DaveWentzel.com            All Things Data

SQL Agent Monitor

 

$server
get-wmiobject win32_service -computername $server|select name, state|
where {($_.name -like "SQLAGENT*" -or $_.name -like "SQL*AGENT") -and $_.state -match "Stopped"
}|Out-String
 
 

Add new comment