[THIN] Re: session kill

  • From: Jeremy Saunders <jeremy@xxxxxxxxxxxxxxxxxxxx>
  • To: "thin@xxxxxxxxxxxxx" <thin@xxxxxxxxxxxxx>
  • Date: Tue, 3 Jun 2014 22:38:06 +0000

The TSSelfServReset.exe utility from 
http://www.ctrl-alt-del.com.au/CAD_TSUtils.htm may work for you.

From: thin-bounce@xxxxxxxxxxxxx [mailto:thin-bounce@xxxxxxxxxxxxx] On Behalf Of 
Raffensberger, Stephen D
Sent: Wednesday, 4 June 2014 4:42 AM
To: thin@xxxxxxxxxxxxx
Subject: [THIN] Re: session kill

Yes, sorry about that. I was going from memory and I’ve killed too many brain 
cells for that.
It’s query user that lets you specify the username…not logoff.
So, it’s not a one-liner. It’s the script below. The inside for loop parses the 
output from query user and gives the session ID to logoff.

for /f %%i in (CitrixFarmList.txt) do (
    query user %USERNAME% /server:%%i 2>NUL | find /i "%USERNAME%" > 
%TEMP%\%%i.txt
    FOR /F "tokens=3" %%j in (%TEMP%\%%i.txt) do @logoff %%j /server:%%i
    )

[Logo Produban]
Steve Raffensberger
Citrix Administrator
Produban US

From: thin-bounce@xxxxxxxxxxxxx<mailto:thin-bounce@xxxxxxxxxxxxx> 
[mailto:thin-bounce@xxxxxxxxxxxxx] On Behalf Of Jason CitrixADmin
Sent: Tuesday, June 03, 2014 4:06 PM
To: thin
Subject: [THIN] Re: session kill

Doesn't this command require the session name, not the username?


On Tue, Jun 3, 2014 at 2:01 PM, Raffensberger, Stephen D 
<sraffens@xxxxxxxxxxx<mailto:sraffens@xxxxxxxxxxx>> wrote:
I just publish a self-help script that scans the whole farm and terminates all 
sessions it finds.
The script is a one liner. You can call it something like “Kill Me Now”.

FOR /F %%i in (CitrixFarmList.txt) do logoff %USERNAME% /SERVER:%%i

When users become hung, they just execute this script.

[Logo Produban]
Steve Raffensberger
Citrix Administrator
Produban US

From: thin-bounce@xxxxxxxxxxxxx<mailto:thin-bounce@xxxxxxxxxxxxx> 
[mailto:thin-bounce@xxxxxxxxxxxxx<mailto:thin-bounce@xxxxxxxxxxxxx>] On Behalf 
Of Jason CitrixADmin
Sent: Tuesday, June 03, 2014 1:24 PM
To: thin
Subject: [THIN] session kill

I would like for users to be able to kill their own sessions.  Occasionally our 
app will hang up, and when that happens the only way we have been able to clear 
it is to reset the users session.   i am looking for a way to allow the users 
teh ability to do this themselves without having to involve support.

My current brain storm is have a "secondary" app launch with our main one.  It 
will simply be a button they can click that will force a log off using the 
shutdown /l /f command.
While I can implement that easily enough the trouble I am finding is that I 
need a way to make sure that this secondary app closes on its own if they exit 
the main app.
If built with a VBscript is there a way to get the secondary one to watch for 
the termination of the main app and close itself or exit if the main one closes?
I have very little scripting experience and am trying to come up with a 
solution on my own time at the moment that I can present since I know my 
suggestion will fall on mostly deaf ears if I ask for something to be developed.

We recently changed our email addresses to reflect the Bank’s new name, 
Santander. Please update your records accordingly.
This message contains information which may be confidential and privileged. 
Unless you are the addressee (or authorized to receive for the addressee), you 
may not use, copy or disclose to anyone the message or any information 
contained in the message. If you have received the message in error, please 
advise the sender by reply e-mail, and delete or destroy the message. Thank you.
________________________________

P Please consider the environment before printing this email




We recently changed our email addresses to reflect the Bank’s new name, 
Santander. Please update your records accordingly.
This message contains information which may be confidential and privileged. 
Unless you are the addressee (or authorized to receive for the addressee), you 
may not use, copy or disclose to anyone the message or any information 
contained in the message. If you have received the message in error, please 
advise the sender by reply e-mail, and delete or destroy the message. Thank you.
________________________________

P Please consider the environment before printing this email


GIF image

Other related posts: