Forum Stats

  • 3,751,342 Users
  • 2,250,347 Discussions
  • 7,867,392 Comments

Discussions

V$SESSION STATUS = INACTIVE and STATUS = SNIPED

user135518
user135518 Member Posts: 169
edited Aug 6, 2007 11:33AM in General Database Discussions
Please, can someone explain the difference between STATUS of INACTIVE and a STATUS of SNIPED in V$SESSION? METALINK was not helpful in this regard.

Thank You
gelems

Comments

  • 516450
    516450 Member Posts: 1,358
    Here is the information from the documentation:

    ACTIVE - Session currently executing SQL

    INACTIVE

    KILLED - Session marked to be killed

    CACHED - Session temporarily cached for use by Oracle*XA

    SNIPED - Session inactive, waiting on the client


    HTH

    Thanks
    Chandra
  • user135518
    user135518 Member Posts: 169
    Thank you for your reply.

    This is my dilemma, the documentation does not define INACTIVE and does define SNIPED as "Session inactive, waiting on client". Need to know the difference between INACTIVE and SNIPED.
  • 579237
    579237 Member Posts: 158
    this is my confusion too..many a time when i check session i find hunderds of inactive sessions ..what does that mean
  • 516450
    516450 Member Posts: 1,358
    Ok, take a look at Metalink Note:1005059.6...which has some information on this.

    HTH

    Thanks
    chandra pabba
  • 477483
    477483 Member Posts: 72 Green Ribbon
    Inactive - nothing is being done, server waits for tasks to be assigned from the client.

    Sniped - the session has passed the idle_time limit defined in user profile. The session will remain snipped until the client communicates with the db again, when it will get "ORA-02396: exceeded maximum idle time, please connect again" and the session is removed from v$session.
  • 293720
    293720 Member Posts: 530
    Inactive means the session is connected, and idle. The client is not currently making a database call.

    Sniped means the system has killed the session, but the client doesn't know it.

    -Mark
  • Madrid
    Madrid Member Posts: 7,573
    Sniped:
    When IDLE_TIME is set in the users' profiles or the default profile. This will kill the sessions in the database (status in v$session now becomes SNIPED) and they will eventually disconnect. It does not always clean up the Unix session (LOCAL=NO sessions). At this time all oracle resources are released but the shadow processes remains and OS resources are not released. This shadow process is still counted towards the parameters of init.ora.
    This process is killed and entry from v$session is released only when user again tries to do something. Another way of forcing disconnect (if your users come in via SQL*Net) is to put the file sqlnet.ora on every client machine and include the parameter "SQLNET.EXPIRE_TIME" in it to force the close of the SQL*Net session.


    For further references:

    session inactive ??
    make a job to delete the sniped sessions
    How do I put a timeout in my DataBase?
    Killing Session with Locks in Linux



    ~ Madrid
  • Elber
    Elber Member Posts: 164
    edited Aug 6, 2007 11:33AM
    I have 200 sessions inactive, if my reosurce_limit is SESSION=200, when other session need to open, what will hapen? Some INACTIVE SESSION will release?


    Tks,

    Elber.

    Message was edited by:
    Elber
  • 416047
    416047 Member Posts: 945
    No, the one trying to connect will get an error.

    You can use profiles to limit the time a session can remain idle if you want to terminate those sessions.

    http://download.oracle.com/docs/cd/B10501_01/server.920/a96521/users.htm#15451
    gelems
This discussion has been closed.