Practical Apps DBA

Oracle Apps DBA’s Blog

Script to kill Inactive forms sessions

Posted by Navdeep Saini on May 22, 2007

Lots of time, due to user training issues, users leave their forms sessions open and do not end thier sessions. This can cause lots of issues as sometime even querying in a forms sessions places a lock (I know of Order Entry forms which used to behave like that) and as DBAs you will end up clearing blocking sessions in the database.

Oracle apps has timeout profiles (e.g. ICX Session Timeout) options and confirguration options (Apache timeouts etc) , but most of them do not end the database session. Following script checks the forms sessions in the database and kill the database and their corresponding forms (f60webmx) sessions, which were “INACTIVE” and idle (LAST_CALL_ET) for more than 1 hour.

This works for all types of configurations, whether single node or multi-node. For multi-node the requirement is to enable remsh (remote shell), otherwise change the script to use ssh (for more secure option). It also create log and appends to it and send e-mail if there are any sessions that needs to be killed.

Click here to download script

About these ads

33 Responses to “Script to kill Inactive forms sessions”

  1. hume said

    hai .. i’m humaedi , thank’s for your script. because i am studying ORACLE and get trouble.

  2. Hi Humaedi
    Thanks for reading my blog and I am glad that you find my script useful.

    Thanks again

  3. Kumar said

    Hi Navdeep,
    Very nice script,Will be very useful for junior’s like me.

    Good Work.


  4. Kumar
    I am glad that you find my script useful.


  5. Ken said

    I can`t find your scripts.May you send me?My email is


  6. Arun said


    Quite Superb….

    Keep it up………

  7. Kman said

    Good Job Navdeep!!!

  8. Vinayak Sawal said

    Thanks for all your good work
    which really help us.
    Keep up the good work.!

  9. John said

    Nice script, Navdeep. Do you have a similar script to identify inactive forms sessions in a RAC environment?

  10. Siham ELALGA said

    Thanks for all your good work,

    In my application with forms6i,whith each form opning, I open a new session , so i want to exit all forms after one hour (but if the last form in application is inactive for 1 hour)and return to the login form in which the user enter his password and login .

    Can you help me PLZ because it is a big pb for me.


  11. matmosis said

    this script is only for LINUX systems??
    is there one for Windows? i have Oracle 8i on Windows 2000 machine

    thanx a lot

  12. Mehboob said

    Hi Nav,

    Thanks for the contribution to the Oracle Apps, i am also working on Oracle Since last 4 Yrs and visiting all the blogs related to apps….. These blogs are increasing my knowledge thanks for these blogs…

  13. vasu said

    i want know about forms locking sessions
    how we can remove those sessions

  14. Ted said

    Thanks for the script — very helpful. I’m glad there are people, such as yourself, who like to share knowledge.

  15. Thanks Ted !!


  16. goolloog said

    I here the newcomer. Not absolutely I will understand with topic. Explain, please.

  17. DKumar said

    I am looking for a script that identifies the inactive forms session but not kill it and sends out an email to our DL and when we are comfortable we can kill it. I need this ASAP.


  18. This is very up-to-date information. I’ll share it on Digg.
    p.s. Year One is already on the Internet and you can watch it for free.

  19. ranbir said

    nice work! would like you to post more scenario regarding recovery and backup. nice to go thru this blog of urs. ssa!

  20. Prasant said

    Hi Navdeep,

    Thanks for such a nice Scripts , I was face Form Runway session ,now I think I can identified those Inactive Forms as well as Inactive User too. Once again thanks buddy !!!

    With Regards



    […]Script to kill Inactive forms sessions « Practical Apps DBA[…]…

  22. Buy Used Shurley English Curriculum Today…

    […]Script to kill Inactive forms sessions « Practical Apps DBA[…]…

  23. Altaf said

    Hi Navdeep,

    Thanks for the script. Keep up the good work.


  24. Good day! I could have sworn I’ve been to this website before but after browsing through some of the post I realized it’s new to
    me. Anyhow, I’m definitely delighted I found it and I’ll be bookmarking and
    checking back frequently!

  25. Magnificent web site. A lot of helpful info
    here. I am sending it to a few friends ans additionally sharing
    in delicious. And certainly, thank you for your effort!

  26. shoe rack said

    Howdy! Do you use Twitter? I’d like to follow you if that would be okay. I’m undoubtedly
    enjoying your blog and look forward to new posts.

  27. Greetings! This is my first visit to your blog! We are a
    team of volunteers and starting a new initiative in a community in the same niche.
    Your blog provided us valuable information to work on. You have done a extraordinary job!

  28. Appreciate it from Kinawley ;)

  29. Hello there, I found your web site by way of Google at the same time as searching for a comparable matter, your site got here up,
    it seems to be good. I have bookmarked it in my google bookmarks.

    Hi there, simply turned into aware of your weblog through Google, and
    found that it is really informative. I’m gonna be careful for brussels. I will be grateful should you continue this in future. Many other folks will probably be benefited from your writing. Cheers!

  30. Excellent beat ! I would like to apprentice whilst you amend your site, how can i subscribe for a weblog site?
    The account helped me a appropriate deal. I have been
    tiny bit acquainted of this your broadcast provided brilliant
    clear idea

  31. wikipedia said

    When someone writes an article he/she maintains the idea of a user in his/her
    brain that how a user can know it. Therefore that’s
    why this piece of writing is perfect. Thanks!

  32. Hey! I know this is kinda off topic however , I’d figured I’d ask.
    Would you be interested in trading links or maybe guest authoring a
    blog article or vice-versa? My site discusses a lot of the same topics as yours
    and I feel we could greatly benefit from each
    other. If you are interested feel free to
    send me an email. I look forward to hearing from you!

    Superb blog by the way!

  33. Yes! Finally something about consultation of bleeding nose.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


Get every new post delivered to your Inbox.

Join 60 other followers

%d bloggers like this: