PowerShell

After running PS in administrator mode, check user connections to make sure there are no remote connection to the App Server.  The script below works on my servers.

CLS
# Declare Separator
$div = “===========================================================”

Write-Output $div
Write-Output H0123NS
Write-Output $div
query session /server:H0123NS /connect
Write-Output “”
Write-Output $div
Write-Output H0987NS
Write-Output $div
query session /server:H0987NS /connect
Write-Output “”

 

 

Advertisements