Does anyone have a script, WMI or command line that can kill ALL active TS sessions without having to explicitely specify the session ID # ?
Currently we use the following script prior to the BigFix restart 30 command which is not effective on Citrix servers. - (restart initiates but active RDP connections prevent successful execution)
dos echo y | cmd /c For /f “tokens=3” %i in (‘QWinsta’) do logoff %i
dos echo y | cmd /c For /f “tokens=2” %i in (‘QWinsta’) do logoff %i
dos echo y | cmd /c For /f “tokens=3” %i in (‘QWinsta’) do tsdiscon %i
dos echo y | cmd /c For /f “tokens=2” %i in (‘QWinsta’) do tsdiscon %i
dos echo y | cmd /c For /f “tokens=3” %i in (‘QWinsta’) do rwinsta %i
dos echo y | cmd /c For /f “tokens=2” %i in (‘QWinsta’) do rwinsta %i
I’m testing the following action script which works however i need to use the ‘restart’ command aswell because the tsshutdn command doesnt exist on Windows 2000 workstation. -
dos cmd /c tsshutdn 60 /reboot
restart 1
Is there anyway, using BES 5.1, I can script (within the action script) - If WinxXP, 2003, or 2000 Svr then ‘TSSHUTDN’ elseif Windows 2000 ‘restart 1’
In BES 6.0, the clients would support the following:
IF {name of operating system = “Win2000”}
restart 60
ELSE
dos cmd /c tsshutdn 60 /reboot
ENDIF
Unfortunately, BES 5.1 Clients don’t support that action syntax…
Maybe we can try this:
restart 300
continue if {name of operating system = “WinXP” OR name of operating system = “Win2003”}
dos cmd /c tsshutdn 60 /reboot
This might work… basically all computers will run “restart 300” and then only the xp/2003 computers will run the tsshutdn command (others will fail the “continue if” line).
I need to create a fixlet that identifies disconnected TS / cirtix sessions and logs them off and disconnects them. There will be GOOD sessions on the clients so I can’t disconnect everyone. I’ve scoured around the forum, but can’t find anything. Any ideas?