Results 1 to 5 of 5
  1. #1
    Join Date
    Jun 2009
    Location
    India
    Posts
    50

    Unanswered: isql sessions are timedout/inactive

    Hi,

    Few of the developers are getting their isql sessions inactive/timedout for every 15 mins, when they are trying to connect from application server to Sybase DB server.

    However, the isql sessions are active for longer duration when connected directly to Sybase DB Server.

    TIMEOUT variable is not set (i.e commented) in file /etc/default/login on both application & Database server.

    Could you plz guide me, if there is any way that i could resolve inactive/timeout issues from application server?

  2. #2
    Join Date
    Sep 2003
    Location
    Switzerland
    Posts
    443
    Quote Originally Posted by Neevarp
    Hi,

    TIMEOUT variable is not set (i.e commented) in file /etc/default/login on both application & Database server.
    This doesnt sound right. Tell us first how the application connects to database.

  3. #3
    Join Date
    Mar 2009
    Location
    Sydney, Australia
    Posts
    258
    This is "normal", not expected or planned, but pretty much ordinary, when you have done nothing consciously to prevent it. Basically the ASE is very busy, and the connection attempt times out. Logging into ASE directly is far less overhead than logging into the app server, which then connects with ASE, so you will get (a) better response and (b) less timeouts.

    There are two separate problems:
    1 Do not connect from the app server to ASE using isql, that is slow and unnecessary. Most app servers allow a direct connection and have Sybase Open CLient already loaded (install it if not). Always use a direct connection.

    1.1 Make sure these app server to ASE connections are persistent (you do not want them connecting and disconnecting all the time). Most app servers can be configured to use a connection pool of (eg) 10 proxy connections to ASE. That is, 300 users connect to the app server; app server uses 10 persistent connections to ASE, servicing all 300 users on those 10 connections.

    2 ASE is busy. Too busy to accept another connection. To deal with that, you have to get into the ASE, and look at what it is doing, basically a P&T inspection.
    Regards
    Derek Asirvadem (Formerly DerekA)
    Information Architect / Senior Sybase DBA
    Copyright 2009 Software Gems Pty Ltd

    I answer questions from the Original Poster only. If you have a genuine question, as the moderators have requested, start a new thread.

    http://www.softwaregems.com.au

  4. #4
    Join Date
    Jun 2009
    Location
    India
    Posts
    50
    HI Derak,

    Thanks for the info. If a user directly connects to DB server then he is not facing any isql timeout issues. However, developers are not having access directly connect to DB server, but can connect from Client machine through Sybase openclient. Below are the details

    Client Machine :

    SunOS Client 5.10 Generic_120011-14 sun4u sparc SUNW,Sun-Fire-V890
    TCP Keeplaive = 7200000(7200 sec)
    Sybase Openclient - 11.1.1-EBF8707


    DB Server 1:

    SunOS DBSrv1 5.10 Generic_127111-05 sun4v sparc SUNW,Sun-Fire-T200
    TCP Keepalive = 120000(120 sec)
    DB Instance = DB_PROD (Version : 15.0.2)


    DB Server 2:

    SunOS DBsrv2 5.10 Generic_127111-05 sun4v sparc SUNW,Sun-Fire-T200
    TCP Keepalive = 7200000 (7200 sec)
    DB Instance = DB_TEST (Version : 15.0.2)



    Users when they connect from Client Machine through Sybase Openclient to DB_PROD through isql, isql sessions are active atleast for 40 mins - this is fine. However, when they connect to DB_TEST from the same client machine, isql sessions are timed out after 20 mins appx - I need to work on this.

    CS_LOGIN_TIMOUT variable is not set in Sybase openclient Configuration directory & in DB Server 1, DB Server 2 Configuration directries.

    Will this issue be resolved by setting tcp keeplaive value to 120 secs for DB Server 2? Else, could you please guide me if i need to dig in to DB paramaeters?

  5. #5
    Join Date
    Mar 2009
    Location
    Sydney, Australia
    Posts
    258
    1 First, get Sybase OpenClient 15.0.2 (from one of the DB Servers) and put it on the Client machine. (It is crazy running a 11.1 OpenClient against a 15.0 server; there will be other problems later on; the oldest Open Client I can recommend for 15.0 is 12.5.)

    2 If they are using their app plus OpenCIlent, then that is a direct connection to ASE, there is no app-server involved (isql is just a character app that allows batches of SQL to be submitted; it just runs OpenClient to connect to ASE).

    3 tcp_keepalive is used for deciding whether the client (every connection to ASE is a client from DB_Server_x) is actually alive or dead; only when the connection is no longer present. If you set it high (120 mins), then you will have a different problem: dead connections will not be cleaned up within ASE. If they have locks held, etc. that could be serious. tcp_keepalive of 2 mins (as on DB_PROD) is correct.

    4 The isql or OpenClient sessions timing out is a different problem. Look into tcp_keepidle. That's from memory, I do not have a Solaris box handy right now. This kind of issue is usually due to a Solaris setting such as tcp_keepalive/keepidle, etc.
    Regards
    Derek Asirvadem (Formerly DerekA)
    Information Architect / Senior Sybase DBA
    Copyright 2009 Software Gems Pty Ltd

    I answer questions from the Original Poster only. If you have a genuine question, as the moderators have requested, start a new thread.

    http://www.softwaregems.com.au

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •