session keeps dying?

Discussion in 'ASP .Net' started by Steve Letford, Aug 5, 2003.

  1. Hi,
    I've just read the ms KB article on how sessions can die because of the
    underscore in the machine name and don't think that it applies to me. I've
    tried using the IP address of the server and have tested it locally using
    localhost and my sessions still die.

    It seems to happen on one particular page. It has some heavy db activity
    but my connections are pooled.

    It also seems to happen before any activity occurs once it has started to
    fail then every postback to the same page will cause the session to die.

    Does anyone have any ideas. Also if the aspnet worker process is recycled
    would the memory process be set back to a low figure?

    Thanks for any help.

    Steve
    Steve Letford, Aug 5, 2003
    #1
    1. Advertising

  2. Steve Letford

    Ram Guest

    If ASPNET worker process is recycled, your application is restarted.
    Then you will loose all your sessions also.

    "Steve Letford" <> wrote in message news:<#>...
    > Hi,
    > I've just read the ms KB article on how sessions can die because of the
    > underscore in the machine name and don't think that it applies to me. I've
    > tried using the IP address of the server and have tested it locally using
    > localhost and my sessions still die.
    >
    > It seems to happen on one particular page. It has some heavy db activity
    > but my connections are pooled.
    >
    > It also seems to happen before any activity occurs once it has started to
    > fail then every postback to the same page will cause the session to die.
    >
    > Does anyone have any ideas. Also if the aspnet worker process is recycled
    > would the memory process be set back to a low figure?
    >
    > Thanks for any help.
    >
    > Steve
    Ram, Aug 5, 2003
    #2
    1. Advertising

  3. Steve Letford

    Marina Guest

    The session_end can fire that often, if you had started a new session every
    3-4 minutes. Then as those sessions end, the event is fired.

    "Steve Letford" <> wrote in message
    news:...
    > Thanks for the reply,
    > But I checked my memory usage for the aspnet worker process and it remains
    > high when the session ends. Does this mean that it hasn't recycled?
    >
    > Also, I've noticed that without doing anything, i.e. clicking any buttons.
    > I have put a break point on my session_end and it fires every 3 or 4
    > minutes.
    >
    > Not too sure what is going on here?
    > Any ideas?
    >
    > Thanks for your help.
    >
    > Steve
    > "Ram" <> wrote in message
    > news:...
    > > If ASPNET worker process is recycled, your application is restarted.
    > > Then you will loose all your sessions also.
    > >
    > > "Steve Letford" <> wrote in message

    > news:<#>...
    > > > Hi,
    > > > I've just read the ms KB article on how sessions can die because of

    the
    > > > underscore in the machine name and don't think that it applies to me.

    > I've
    > > > tried using the IP address of the server and have tested it locally

    > using
    > > > localhost and my sessions still die.
    > > >
    > > > It seems to happen on one particular page. It has some heavy db

    > activity
    > > > but my connections are pooled.
    > > >
    > > > It also seems to happen before any activity occurs once it has started

    > to
    > > > fail then every postback to the same page will cause the session to

    die.
    > > >
    > > > Does anyone have any ideas. Also if the aspnet worker process is

    > recycled
    > > > would the memory process be set back to a low figure?
    > > >
    > > > Thanks for any help.
    > > >
    > > > Steve

    >
    >
    Marina, Aug 5, 2003
    #3
  4. Thanks but I'm wondering why the session is ending. I'm not doing anything.
    I'm just sitting watching the screen. My session timeout should be at 20
    mins.

    If the aspnet worker process is recycling wouldn't I see the memory usage of
    it going down each time as it recycles, this isn't happening. Which leaves
    me a bit confused..

    Thanks for any more help.

    Steve

    "Marina" <> wrote in message
    news:...
    > The session_end can fire that often, if you had started a new session

    every
    > 3-4 minutes. Then as those sessions end, the event is fired.
    >
    > "Steve Letford" <> wrote in message
    > news:...
    > > Thanks for the reply,
    > > But I checked my memory usage for the aspnet worker process and it

    remains
    > > high when the session ends. Does this mean that it hasn't recycled?
    > >
    > > Also, I've noticed that without doing anything, i.e. clicking any

    buttons.
    > > I have put a break point on my session_end and it fires every 3 or 4
    > > minutes.
    > >
    > > Not too sure what is going on here?
    > > Any ideas?
    > >
    > > Thanks for your help.
    > >
    > > Steve
    > > "Ram" <> wrote in message
    > > news:...
    > > > If ASPNET worker process is recycled, your application is restarted.
    > > > Then you will loose all your sessions also.
    > > >
    > > > "Steve Letford" <> wrote in message

    > > news:<#>...
    > > > > Hi,
    > > > > I've just read the ms KB article on how sessions can die because of

    > the
    > > > > underscore in the machine name and don't think that it applies to

    me.
    > > I've
    > > > > tried using the IP address of the server and have tested it locally

    > > using
    > > > > localhost and my sessions still die.
    > > > >
    > > > > It seems to happen on one particular page. It has some heavy db

    > > activity
    > > > > but my connections are pooled.
    > > > >
    > > > > It also seems to happen before any activity occurs once it has

    started
    > > to
    > > > > fail then every postback to the same page will cause the session to

    > die.
    > > > >
    > > > > Does anyone have any ideas. Also if the aspnet worker process is

    > > recycled
    > > > > would the memory process be set back to a low figure?
    > > > >
    > > > > Thanks for any help.
    > > > >
    > > > > Steve

    > >
    > >

    >
    >
    Steve Letford, Aug 5, 2003
    #4
  5. Finally figured it out.
    My page has a dynamically created javascript tree and I have a link that
    allows all the items in the tree to expand or contract.
    If this link is called then it loops through all the top level items and
    sets a cookie saying expanded or contracted.

    If I click on item at a time there is no problem the cookie is set and it
    all works. But when the procedure is called that sets all the cookies at
    once it kills my session????

    my cookie names are all numbers, there aren't any strange characters so its
    a bit of a mystery.

    Appreciate any enlightenment.

    Steve


    "Steve Letford" <> wrote in message
    news:OzYSM%...
    > Thanks but I'm wondering why the session is ending. I'm not doing

    anything.
    > I'm just sitting watching the screen. My session timeout should be at 20
    > mins.
    >
    > If the aspnet worker process is recycling wouldn't I see the memory usage

    of
    > it going down each time as it recycles, this isn't happening. Which

    leaves
    > me a bit confused..
    >
    > Thanks for any more help.
    >
    > Steve
    >
    > "Marina" <> wrote in message
    > news:...
    > > The session_end can fire that often, if you had started a new session

    > every
    > > 3-4 minutes. Then as those sessions end, the event is fired.
    > >
    > > "Steve Letford" <> wrote in message
    > > news:...
    > > > Thanks for the reply,
    > > > But I checked my memory usage for the aspnet worker process and it

    > remains
    > > > high when the session ends. Does this mean that it hasn't recycled?
    > > >
    > > > Also, I've noticed that without doing anything, i.e. clicking any

    > buttons.
    > > > I have put a break point on my session_end and it fires every 3 or 4
    > > > minutes.
    > > >
    > > > Not too sure what is going on here?
    > > > Any ideas?
    > > >
    > > > Thanks for your help.
    > > >
    > > > Steve
    > > > "Ram" <> wrote in message
    > > > news:...
    > > > > If ASPNET worker process is recycled, your application is restarted.
    > > > > Then you will loose all your sessions also.
    > > > >
    > > > > "Steve Letford" <> wrote in message
    > > > news:<#>...
    > > > > > Hi,
    > > > > > I've just read the ms KB article on how sessions can die because

    of
    > > the
    > > > > > underscore in the machine name and don't think that it applies to

    > me.
    > > > I've
    > > > > > tried using the IP address of the server and have tested it

    locally
    > > > using
    > > > > > localhost and my sessions still die.
    > > > > >
    > > > > > It seems to happen on one particular page. It has some heavy db
    > > > activity
    > > > > > but my connections are pooled.
    > > > > >
    > > > > > It also seems to happen before any activity occurs once it has

    > started
    > > > to
    > > > > > fail then every postback to the same page will cause the session

    to
    > > die.
    > > > > >
    > > > > > Does anyone have any ideas. Also if the aspnet worker process is
    > > > recycled
    > > > > > would the memory process be set back to a low figure?
    > > > > >
    > > > > > Thanks for any help.
    > > > > >
    > > > > > Steve
    > > >
    > > >

    > >
    > >

    >
    >
    Steve Letford, Aug 6, 2003
    #5
  6. Steve Letford

    Natty Gur Guest

    Hi,

    1) Check this:
    The number and the size of the cookies on a client are restricted.
    Maximal 300 cookies can be stored on a client.
    If the 301st cookies should be stored, the least recently used cookie
    will be deleted.
    Maximal 20 cookies per server or domain can be stored on a client.
    If the server wants to store its 21st cookie, the least recently used
    cookie (from this server) will be deleted.

    Try to use other method then cookies. It you need this data on the
    server you can store it in ViewState for example.

    2)aspnet_wp or w3wp process can shut down just one application which
    "lives" in one AppDomain. if that’s happened the process memory usage
    wont shrink dramatically.

    Natty Gur, CTO
    Dao2Com Ltd.
    34th Elkalay st. Raanana
    Israel , 43000
    Phone Numbers:
    Office: +972-(0)9-7740261
    Fax: +972-(0)9-7740261
    Mobile: +972-(0)58-888377


    *** Sent via Developersdex http://www.developersdex.com ***
    Don't just participate in USENET...get rewarded for it!
    Natty Gur, Aug 6, 2003
    #6
  7. I think my cooke was getting too big, which may have been killing the
    session?


    "Steve Letford" <> wrote in message
    news:%...
    > Finally figured it out.
    > My page has a dynamically created javascript tree and I have a link that
    > allows all the items in the tree to expand or contract.
    > If this link is called then it loops through all the top level items and
    > sets a cookie saying expanded or contracted.
    >
    > If I click on item at a time there is no problem the cookie is set and it
    > all works. But when the procedure is called that sets all the cookies at
    > once it kills my session????
    >
    > my cookie names are all numbers, there aren't any strange characters so

    its
    > a bit of a mystery.
    >
    > Appreciate any enlightenment.
    >
    > Steve
    >
    >
    > "Steve Letford" <> wrote in message
    > news:OzYSM%...
    > > Thanks but I'm wondering why the session is ending. I'm not doing

    > anything.
    > > I'm just sitting watching the screen. My session timeout should be at

    20
    > > mins.
    > >
    > > If the aspnet worker process is recycling wouldn't I see the memory

    usage
    > of
    > > it going down each time as it recycles, this isn't happening. Which

    > leaves
    > > me a bit confused..
    > >
    > > Thanks for any more help.
    > >
    > > Steve
    > >
    > > "Marina" <> wrote in message
    > > news:...
    > > > The session_end can fire that often, if you had started a new session

    > > every
    > > > 3-4 minutes. Then as those sessions end, the event is fired.
    > > >
    > > > "Steve Letford" <> wrote in message
    > > > news:...
    > > > > Thanks for the reply,
    > > > > But I checked my memory usage for the aspnet worker process and it

    > > remains
    > > > > high when the session ends. Does this mean that it hasn't recycled?
    > > > >
    > > > > Also, I've noticed that without doing anything, i.e. clicking any

    > > buttons.
    > > > > I have put a break point on my session_end and it fires every 3 or 4
    > > > > minutes.
    > > > >
    > > > > Not too sure what is going on here?
    > > > > Any ideas?
    > > > >
    > > > > Thanks for your help.
    > > > >
    > > > > Steve
    > > > > "Ram" <> wrote in message
    > > > > news:...
    > > > > > If ASPNET worker process is recycled, your application is

    restarted.
    > > > > > Then you will loose all your sessions also.
    > > > > >
    > > > > > "Steve Letford" <> wrote in message
    > > > > news:<#>...
    > > > > > > Hi,
    > > > > > > I've just read the ms KB article on how sessions can die because

    > of
    > > > the
    > > > > > > underscore in the machine name and don't think that it applies

    to
    > > me.
    > > > > I've
    > > > > > > tried using the IP address of the server and have tested it

    > locally
    > > > > using
    > > > > > > localhost and my sessions still die.
    > > > > > >
    > > > > > > It seems to happen on one particular page. It has some heavy db
    > > > > activity
    > > > > > > but my connections are pooled.
    > > > > > >
    > > > > > > It also seems to happen before any activity occurs once it has

    > > started
    > > > > to
    > > > > > > fail then every postback to the same page will cause the session

    > to
    > > > die.
    > > > > > >
    > > > > > > Does anyone have any ideas. Also if the aspnet worker process

    is
    > > > > recycled
    > > > > > > would the memory process be set back to a low figure?
    > > > > > >
    > > > > > > Thanks for any help.
    > > > > > >
    > > > > > > Steve
    > > > >
    > > > >
    > > >
    > > >

    > >
    > >

    >
    >
    Steve Letford, Aug 6, 2003
    #7
  8. Steve Letford

    Natty Gur Guest

    Count the number of your tree leaf and figure it up ;-).

    Anyway cookies don’t use to manage many state items.

    Natty Gur, CTO
    Dao2Com Ltd.
    34th Elkalay st. Raanana
    Israel , 43000
    Phone Numbers:
    Office: +972-(0)9-7740261
    Fax: +972-(0)9-7740261
    Mobile: +972-(0)58-888377


    *** Sent via Developersdex http://www.developersdex.com ***
    Don't just participate in USENET...get rewarded for it!
    Natty Gur, Aug 6, 2003
    #8
  9. Steve Letford

    Ram Guest

    I am not sure about the memory usage. You can check the ASPNET worker
    process recycling in the APplication Log of Windows Event Viewer.
    Check those events where the source is ASP.NET. It will show some
    thing like this

    Event Type: Error
    Event Source: ASP.NET 1.0.3705.288
    Event Category: None
    Event ID: 1003
    Date: 8/6/2003
    Time: 5:33:44 AM
    User: N/A
    Computer: RAM
    Description:
    aspnet_wp.exe (PID: 2456) was recycled because it was suspected to be
    in a deadlocked state. It did not send any responses for pending
    requests in the last 180 seconds.


    "Steve Letford" <> wrote in message news:<OzYSM#>...
    > Thanks but I'm wondering why the session is ending. I'm not doing anything.
    > I'm just sitting watching the screen. My session timeout should be at 20
    > mins.
    >
    > If the aspnet worker process is recycling wouldn't I see the memory usage of
    > it going down each time as it recycles, this isn't happening. Which leaves
    > me a bit confused..
    >
    > Thanks for any more help.
    >
    > Steve
    >
    > "Marina" <> wrote in message
    > news:...
    > > The session_end can fire that often, if you had started a new session

    > every
    > > 3-4 minutes. Then as those sessions end, the event is fired.
    > >
    > > "Steve Letford" <> wrote in message
    > > news:...
    > > > Thanks for the reply,
    > > > But I checked my memory usage for the aspnet worker process and it

    > remains
    > > > high when the session ends. Does this mean that it hasn't recycled?
    > > >
    > > > Also, I've noticed that without doing anything, i.e. clicking any

    > buttons.
    > > > I have put a break point on my session_end and it fires every 3 or 4
    > > > minutes.
    > > >
    > > > Not too sure what is going on here?
    > > > Any ideas?
    > > >
    > > > Thanks for your help.
    > > >
    > > > Steve
    > > > "Ram" <> wrote in message
    > > > news:...
    > > > > If ASPNET worker process is recycled, your application is restarted.
    > > > > Then you will loose all your sessions also.
    > > > >
    > > > > "Steve Letford" <> wrote in message

    > news:<#>...
    > > > > > Hi,
    > > > > > I've just read the ms KB article on how sessions can die because of

    > the
    > > > > > underscore in the machine name and don't think that it applies to

    > me.
    > I've
    > > > > > tried using the IP address of the server and have tested it locally

    > using
    > > > > > localhost and my sessions still die.
    > > > > >
    > > > > > It seems to happen on one particular page. It has some heavy db

    > activity
    > > > > > but my connections are pooled.
    > > > > >
    > > > > > It also seems to happen before any activity occurs once it has

    > started
    > to
    > > > > > fail then every postback to the same page will cause the session to

    > die.
    > > > > >
    > > > > > Does anyone have any ideas. Also if the aspnet worker process is

    > recycled
    > > > > > would the memory process be set back to a low figure?
    > > > > >
    > > > > > Thanks for any help.
    > > > > >
    > > > > > Steve
    > > >
    > > >

    > >
    > >
    Ram, Aug 6, 2003
    #9
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. James Kimble
    Replies:
    36
    Views:
    1,101
    unbending
    Jan 26, 2005
  2. Bill Williams
    Replies:
    0
    Views:
    585
    Bill Williams
    Jun 2, 2005
  3. Twisted
    Replies:
    1
    Views:
    1,063
    Twisted
    Feb 24, 2006
  4. Robbe Morris [C# MVP]

    Re: Session keeps dropping

    Robbe Morris [C# MVP], Dec 1, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    444
    =?Utf-8?B?UGFycm90?=
    Dec 4, 2006
  5. lekonna
    Replies:
    2
    Views:
    132
    lekonna
    Apr 2, 2008
Loading...

Share This Page