MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

How to kill my TSO session ?

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF
View previous topic :: View next topic  
Author Message
tony01
Beginner


Joined: 06 May 2006
Posts: 2
Topics: 1

PostPosted: Wed Aug 16, 2006 3:24 pm    Post subject: How to kill my TSO session ? Reply with quote

Hi everyone:

Who can tell me How to KILL my TSO session ?

Some times I lost my network connection and when I try to reconnect to my TSO session I get a message " user already in use", so I need to KILL my tso session or wait 15 minutes to re-stablish my session.

Thanks .
_________________
tony01
Back to top
View user's profile Send private message
Bill Dennis
Advanced


Joined: 03 Dec 2002
Posts: 579
Topics: 1
Location: Iowa, USA

PostPosted: Wed Aug 16, 2006 4:32 pm    Post subject: Reply with quote

Are you able to set the RECONNECT option on the bottom of the LOGON screen?
_________________
Regards,
Bill Dennis

Disclaimer: My comments on this foorum are my own and do not represent the opinions or suggestions of any other person or business entity.
Back to top
View user's profile Send private message
semigeezer
Supermod


Joined: 03 Jan 2003
Posts: 1014
Topics: 13
Location: Atlantis

PostPosted: Wed Aug 16, 2006 6:05 pm    Post subject: Reply with quote

Reconnect works on some systems, not others. There are a few ways to kill the session, but usually the best way is to connect with another id that has priviledges to do this. Other alternatives (all require sufficient privilidge) include logging in to the operator console and cancelling the id, using a remote spool manager like IBM's Breeze or a home grown CGI script on a web server to cancel the id, submitting a batch job through FTP that can cancel the id... basically any way you can get into the system with the ability to issue a cancel command will work. If this is a frequent problem, I suspect that writing a little CGI program in Rexx that runs on the web server and is authenticated to the userid itself is probably easy to write and only moderately difficult to set up, but of course that assumes knowledge of Rexx, CGI, and web server setup.
Back to top
View user's profile Send private message Visit poster's website
coolman
Intermediate


Joined: 03 Jan 2003
Posts: 283
Topics: 27
Location: US

PostPosted: Wed Aug 16, 2006 6:11 pm    Post subject: Reply with quote

what do you have at your shop? If you have SDSF, you can run in SDSF in batch from one of your co-worker's id (making you as the USER of the job), purge your id of the MVS system and then you can try logging back on
________
strawberry cough pictures


Last edited by coolman on Sat Feb 05, 2011 1:48 am; edited 1 time in total
Back to top
View user's profile Send private message
ofer71
Intermediate


Joined: 12 Feb 2003
Posts: 358
Topics: 4
Location: Israel

PostPosted: Thu Aug 17, 2006 12:28 am    Post subject: Reply with quote

Try this:
Code:
/* REXX */                                               
                                                         
ARG USER_ID                                             
IF USER_ID = '' THEN                                     
  USER_ID = USERID()                                     
                                                         
IF USER_ID ?= USERID() THEN DO                           
  SAY 'Are you sure you want to cancel 'USER_ID '?'     
  PULL ANSWER                                           
  IF ANSWER = 'Y' | ANSWER = 'YES' |,                   
     ANSWER = 'y' | ANSWER = 'yes' THEN                 
    SIGNAL DOIT                                         
  ELSE                                                   
    SIGNAL JUST_EXIT                                     
END                                                     
                                                         
DOIT:                                                   
  SDSFCMD = "/C U=" || USER_ID                           
  "ISPEXEC SELECT PGM(ISFISP) PARM("SDSFCMD")"           
                                                         
JUST_EXIT:                                               
                                                         
EXIT                                                     
                                                         


O.
________
Valiant Charger


Last edited by ofer71 on Sat Feb 05, 2011 11:40 am; edited 1 time in total
Back to top
View user's profile Send private message Send e-mail
shekar123
Advanced


Joined: 22 Jul 2005
Posts: 528
Topics: 90
Location: Bangalore India

PostPosted: Thu Aug 17, 2006 1:15 am    Post subject: Reply with quote

tony01,

Some more info to avoid logging off and login:

There might some instances / set up where if you do not use TSO Session for some speficed duration your session gets automatically logged off and again you need to log on .To avoid that you can use AUTOUPDATE OPTION.Try this :
IN SPOOL TYPE &60 which will autoupdate the session for every 60 seconds and you can give any value and Hit Enter
Code:

SDSF STATUS DISPLAY ALL CLASSES                        LINE 1-2 (2)           
NP   JOBNAME  JobID    Owner    Prty Queue      C  Pos  SAff  ASys Status     
     SHEKAR   TSU06917 SHEKAR     15 EXECUTION          XXXX  XXXX             
     SHEKARR  JOB06517 SHEKAR      1 PRINT      A    35                       
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
COMMAND INPUT ===> &60                                        SCROLL ===> CSR 

You will get:
Code:

SDSF STATUS DISPLAY ALL CLASSES                        LINE 1-2 (2)           
NP   JOBNAME  JobID    Owner    Prty Queue      C  Pos  SAff  ASys Status     
     SHEKAR   TSU06917 SHEKAR     15 EXECUTION          XXXX  XXXX             
     SHEKARR  JOB06517 SHEKAR      1 PRINT      A    35                       
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
                                                                               
COMMAND INPUT ===> **** AUTO UPDATE -  60 SECONDS ****        SCROLL ===> CSR 

Again to come to normal mode Press ESC Key.
_________________
Shekar
Grow Technically
Back to top
View user's profile Send private message
Bill Dennis
Advanced


Joined: 03 Dec 2002
Posts: 579
Topics: 1
Location: Iowa, USA

PostPosted: Thu Aug 17, 2006 8:20 am    Post subject: Reply with quote

shekar,
Nice trick, but tony01 is getting the terminal disconnected, not timed out due to inactivity.
_________________
Regards,
Bill Dennis

Disclaimer: My comments on this foorum are my own and do not represent the opinions or suggestions of any other person or business entity.
Back to top
View user's profile Send private message
Steve Coalbran
Beginner


Joined: 09 Mar 2005
Posts: 22
Topics: 0
Location: Stockholm, Sweden

PostPosted: Thu Aug 17, 2006 9:11 am    Post subject: Reply with quote

Hi tony01,
If you are locked out, as is oft the case: looping or chopped with reconnect failures, etc., and on your own working late...
(well it is Friday at 11:30 you doen't exactly want to ring up a colleague to help cancel you?!... or suffer the sarcasm of Operations?!!
Bummer!?... and even the pubs are shut now ?!)


This method works for me everytime (well, before I hacked it into this forum anyhow!).
Note that only the M/C SDSF command should be necessary and the sleep shouldn't be necessary but seems to help!
On your PC you need these two files on a private directory. Tailor the lowercase values appropriately ...
Code:

n.nn.nnn.nn  -  IP Address of the TSO host
uuuuuuuu     -  TSO userid
pppppppp     -  TSO password
ffffffff     -  filename of JCL file

1. JCL - mine is called CANCELME.JCL
Code:

//jobcard
/*JOBPARM  SYSAFF=(*)
//WAITASEC EXEC PGM=IKJEFT01,PARM='BPXBATCH pgm /bin/sleep 5'   
//SYSTSPRT DD DUMMY 
//SYSTSIN  DD DUMMY     
//CANCELME EXEC PGM=ISFAFD 
//ISFOUT   DD DUMMY   
//ISFIN    DD *
M/C U=uuuuuuuu
PRE uuuuuuuu
DA
++ALL
FIND 'uuuuuuuu'
++C
RESET
//                           

and...
2. Command - mine is called CANCELME.CMD
Code:

FTP
OPEN n.nn.nnn.nn
uuuuuuuu
pppppppp
QUOTE SITE FILETYPE=JES
PUT C:/ffffffff.JCL
BYE

When you need to Cancel YourSelf...

  1. Edit the CMD file
  2. Confirm your password is still correct in the CMD file
  3. Cut + Paste(Right-Click option) this file into an MSDOS window.

and "Robert's yer father's brother" - as they say!

Wink /Steve Cool
Back to top
View user's profile Send private message Send e-mail MSN Messenger
tony01
Beginner


Joined: 06 May 2006
Posts: 2
Topics: 1

PostPosted: Fri Aug 18, 2006 2:13 pm    Post subject: Reply with quote

Thank you all for your inputs.

Steve Coalbran very useful script, It works , but in my case
I am not AUTHORIZED to execute /C u=myuserid commands in SDSF,
so I can not use this command.

Anyway thanks a lot everyone.

Tony
_________________
tony01
Back to top
View user's profile Send private message
muralikrishnan
Beginner


Joined: 08 Feb 2006
Posts: 19
Topics: 11

PostPosted: Tue Aug 29, 2006 8:19 pm    Post subject: Reply with quote

Hi,

I guess you can also make use of this JCL to purge your ID if reconnecting the session fails.


Code:

//CANCEL@ JOB (SESSION),MSGCLASS=O,NOTIFY=&SYSUID,     
// TIME=(,01),USER=XXXXXXX,PASSWORD=XXXXXXXX             
//*                                                     
//BATCH   EXEC PGM=SDSF,DYNAMNBR=150,REGION=1024K,TIME=5
//ISFOUT   DD  SYSOUT=*                                 
//ISFIN    DD  *                                         
OWNER XXXXXXX                                           
ST XXXXXXX                                               
FIND 'XXXXXXX'                                           
++P                                                     
ST                                                       
/*                       


You can submit this JCL through your co-worker's ID. Just supply your Username and Password.

Please correct me if I am wrong.
Back to top
View user's profile Send private message
acevedo
Beginner


Joined: 03 Dec 2002
Posts: 127
Topics: 0
Location: Europe

PostPosted: Wed Aug 30, 2006 1:17 am    Post subject: Reply with quote

I faced the very same problem some years ago... I exposed one solution that was accepted by management, security team and others, published and now it's widely known and used in my shop... above you have several methods BUT you need the trigger, asumming you have CICS just use one transaction to submit the job using the CICS Spool sentences...

just pass the CICS USERID to the PROC.

Code:

//CANCELU   JOB 'CANCELACION DE SESION',MSGCLASS=X,TYPRUN=SCAN         
// COMMAND 'RO BCAR,C U=???????'                                       
//IEFBR14  EXEC PGM=IEFBR14                                             



HTH.
Back to top
View user's profile Send private message
Cogito-Ergo-Sum
Advanced


Joined: 15 Dec 2002
Posts: 637
Topics: 43
Location: Bengaluru, INDIA

PostPosted: Thu Sep 07, 2006 5:13 pm    Post subject: Reply with quote

acevedo,
Have you TYPRUN=SCAN coded purposely ? Or, would it be removed when executed ?
_________________
ALL opinions are welcome.

Debugging tip:
When you have eliminated all which is impossible, then whatever remains, however improbable, must be the truth.
-- Sherlock Holmes.
Back to top
View user's profile Send private message
acevedo
Beginner


Joined: 03 Dec 2002
Posts: 127
Topics: 0
Location: Europe

PostPosted: Fri Sep 08, 2006 3:52 am    Post subject: Reply with quote

try it... you'll see that even with TYPRUN=SCAN... your session will be canceled.
Back to top
View user's profile Send private message
Cogito-Ergo-Sum
Advanced


Joined: 15 Dec 2002
Posts: 637
Topics: 43
Location: Bengaluru, INDIA

PostPosted: Fri Sep 08, 2006 4:32 am    Post subject: Reply with quote

acevedo wrote:
try it... you'll see that even with TYPRUN=SCAN... your session will be canceled.


Thank you, acevedo. I do not think, I will be able to try as I doubt, if I have access for running the console commands.
_________________
ALL opinions are welcome.

Debugging tip:
When you have eliminated all which is impossible, then whatever remains, however improbable, must be the truth.
-- Sherlock Holmes.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group