Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3215102
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T15:08:19+00:00 2026-05-17T15:08:19+00:00

Per a question I posted yesterday , our website’s DNS structure has changed to

  • 0

Per a question I posted yesterday, our website’s DNS structure has changed to round-robin DNS which literally swaps back and and forth between two production servers. Our web.config for both prod servers has:

  • <sessionState mode="SQLServer" ... > pointing to the same shared DB
  • A machineKey on each server that is consistent between the two (this was the main point of my post yesterday).
  • [update] The same domain in the <forms domain=".mydomain.com" ... > tag

When we use the login feature on the site, the login actually makes a web service request to a 3rd website that authenticates a user. If the resulting response says it was a successful login, then we use FormsAuthentication to log the user in:

FormsAuthentication.SetAuthCookie(strUserID, true);

Our issue is that on some pages we see we are logged in, others we’re not. Is this something indicative of either us not completing a final step to share session between two prod servers or could our SQL server session DB be broken?

Thanks in advance

UPDATE:
Our code to determine if the user is logged in is quite basic:

HttpContext.Current.User.Identity.IsAuthenticated

UPDATE 2:

When I hit prod1.mysite.com (or prod2.mysite.com) I get a cookie called "ASP.NET_SessionId" but when I hit the live public URL, http://www.mysite.com, I don’t get this cookie. Is this part of the problem?

RESOLUTION:

It turns out that everything we did here was all correct and that our live site which uses Akamai was being cached in various states due to Akamai’s cache configuration. Sharing your logged in state between servers has been confirmed to work.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T15:08:19+00:00Added an answer on May 17, 2026 at 3:08 pm

    One thing you could do is use the Firebug add-on for Firefox to ensure that the authentication cookie is being sent to the browser as expected after logging in although as you are seeing that you are logged in on some pages I would expect this to be the case.
    Another thing to check would be that the domain is set correctly for the authentication cookie and that it is valid for all pages on your website.
    This is typically set in you web.config in the forms tags, example below and should be same on each server in the web farm.

    <authentication mode="Forms">
        <forms name="yourAuthCookie" loginUrl="/login.aspx" protection="All" path="/" domain="mydomain.com" timeout="30"/>
    </authentication>
    

    If this is all correct then it is possible that session is not being shared correctly between your servers although the settings that your have described in your question appear to cover what is needed.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

As per my previous question , I have a working animation which fades in
All, I'm working on a SharePoint project, but this isn't a SharePoint-specific question per-se.
Relating to another question I asked yesterday with regards to logging I was introduced
This question was posted on some site. I didnt find right answers there, so
As per the original question , The end result is a rounded-rect png in
sorry if this has already been posted but I've been through umpteen posts on
In my last question I posted some sample code on how I was trying
Per man pages, snprintf is returning number of bytes written from glibc version 2.2
Per this helpful article I have confirmed I have a connection pool leak in
Per the Java documentation, the hash code for a String object is computed as:

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.