title: ASP.NET Session persistance on AWS EC2
body: <p>I've tried to use Amazon Web Services EC2 to test my IIS/ASP.NET application I'm developing and I've got the login working but the ASP.NET Session doesn't seem to maintain on reload of a page or on moving to another page.</p>
  
  <p>Page_Load code from my Login Form page (the session gets set correctly until I either move page or refresh the LoginForm page)</p>
  
  <pre><code>protected void Page_Load(object sender, EventArgs e)
              {
                      if(Page.IsPostBack)
                      {
                              NameValueCollection nvc = Request.Form;
  
                              string username = nvc["username"];
                              string password = nvc["password"];
                              Hydra.WebService1SoapClient client = new Hydra.WebService1SoapClient();
  
                              string sid = client.LoginSession(username, password);
  
                              if (sid != "Incorrect details")
                                      HttpContext.Current.Session["loggedin"] = true;
                              else
                                      HttpContext.Current.Session["loggedin"] = false;
                      }
              }
  </code></pre>
  
  <p>Below is from my display page to show the session data.</p>
  
  <pre><code>      &lt;% if (HttpContext.Current.Session["loggedin"] == null || (bool)HttpContext.Current.Session["loggedin"] == false)
                 { %&gt;
              &lt;a class="menu" href="register.php"&gt;Create Account&lt;/a&gt;
              &lt;% } else { %&gt;
              &lt;a class="menu" href="hd.php"&gt;Dashboard&lt;/a&gt;&amp;nbsp;&lt;a class="menu" href="ticketlist.php"&gt;Tickets&lt;/a&gt; &lt;a class="menu" href="admin/index.php"&gt;Admin&lt;/a&gt;
              &lt;% } %&gt;
  
              Value: &lt;% Response.Write("" + HttpContext.Current.Session["loggedin"] + " &lt;br /&gt; SID? " + HttpContext.Current.Session.SessionID);  %&gt;
  </code></pre>
  
  <p>I've tested this on my local IIS system and it works correctly (the session is persistant). </p>
  
  <p>My question then is:
  Does something on AWS not like InProc session state storage or is there another reason for the problem?</p>