473,320 Members | 1,876 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Load Balancing and PostBack - form post lost

I am having an issue where doing a PostBack in ASP.NET is
losing the form information. This is happening in a NLB
environment with two servers using Application Center

When a user selects an item from a DropDownList and then
clicks a submit button, the Click event on the button
redirects them to the value of the selected item. This
works fine if you are on Webserver1 and the button click
PostBacks to Webserver1. If you are on Webserver1 and
the load balance submits back to Webserver2, the page
reloads and the Button click event never fires. This
happens site wide and affects utilities such as
submitting a textbox search and other form posting
events. The web site was running fine without this error
for almost a year.

Here is some sample code that will cause the problem ...

Protected WithEvents lstAgentTools As _
System.Web.UI.WebControls.DropDownList
Protected WithEvents btnAgentTools As _
System.Web.UI.WebControls.Button

Private Sub Page_Load(ByVal sender As _
System.Object, ByVal e As System.EventArgs) _
Handles MyBase.Load
'Put user code to initialize the page here
End Sub

Private Sub Button1_Click(ByVal sender As _
System.Object, ByVal e As System.EventArgs) _
Handles Button1.Click
Response.Redirect
(DropDownList1.SelectedItem.Value)
End Sub
Things I've Tried:
1)Taken the steps in KB 313091 (multiple times) and
ensured that the machine key is the same on both servers.
2)In machine.config, I set <pages
enableViewStateMac="false" /> This has solved the
problem, but I do not feel comfortable with opening a
security hole. I would like to have
enableViewStateMac="true" and still be able to post from
server to server. I'm assuming that somewhere between
Webserver1 and Webserver2 the ViewState appears to be
tampered with, thus the server just drops the form state
information.

The Setup:
Compiled in VS.NET 2002
..NET Framework 1.1.4322 (also happened on 1.0.3705)
Microsoft Application Center 2000 Standard v. 1.00.0780
Web Servers:
Windows 2000, Service Pack 4 (same problem happening
before SP4)
P3, 1.4 GHz

Nov 18 '05 #1
1 2446
sagey
1
Hello Jeffrey,

Did you ever resolve this issue? as i am having exactly the same issue as you have described. i've read the same knowledge base articles as you and it still doesn't work.

my email is sagey79@hotmail.com if you can let me know how you resolved this


I am having an issue where doing a PostBack in ASP.NET is
losing the form information. This is happening in a NLB
environment with two servers using Application Center

When a user selects an item from a DropDownList and then
clicks a submit button, the Click event on the button
redirects them to the value of the selected item. This
works fine if you are on Webserver1 and the button click
PostBacks to Webserver1. If you are on Webserver1 and
the load balance submits back to Webserver2, the page
reloads and the Button click event never fires. This
happens site wide and affects utilities such as
submitting a textbox search and other form posting
events. The web site was running fine without this error
for almost a year.

Here is some sample code that will cause the problem ...

Protected WithEvents lstAgentTools As _
System.Web.UI.WebControls.DropDownList
Protected WithEvents btnAgentTools As _
System.Web.UI.WebControls.Button

Private Sub Page_Load(ByVal sender As _
System.Object, ByVal e As System.EventArgs) _
Handles MyBase.Load
'Put user code to initialize the page here
End Sub

Private Sub Button1_Click(ByVal sender As _
System.Object, ByVal e As System.EventArgs) _
Handles Button1.Click
Response.Redirect
(DropDownList1.SelectedItem.Value)
End Sub


Things I've Tried:
1)Taken the steps in KB 313091 (multiple times) and
ensured that the machine key is the same on both servers.
2)In machine.config, I set <pages
enableViewStateMac="false" /> This has solved the
problem, but I do not feel comfortable with opening a
security hole. I would like to have
enableViewStateMac="true" and still be able to post from
server to server. I'm assuming that somewhere between
Webserver1 and Webserver2 the ViewState appears to be
tampered with, thus the server just drops the form state
information.

The Setup:
Compiled in VS.NET 2002
..NET Framework 1.1.4322 (also happened on 1.0.3705)
Microsoft Application Center 2000 Standard v. 1.00.0780
Web Servers:
Windows 2000, Service Pack 4 (same problem happening
before SP4)
P3, 1.4 GHz
May 3 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Max | last post by:
Frankly, i need session variables to persist regardless of load balancing. My hoster says save them in files, yuk. Are there any other thoughts The problem is that the session variables are lost...
2
by: yagish | last post by:
Hi Techies, Am really new with the Oracle 9i Forms and am searching for a way to perform Load Balancing in Oracle 9i Forms Application. Its not a J2EE application, so cannot go the OC4J way. I...
3
by: Shabam | last post by:
When a web application becomes overloaded with traffic, one can offload it by load balancing and clustering the front end web servers. What happens when the back-end MSSQL database becomes...
10
by: GeekBoy | last post by:
Okay, I have two identical web servers running Windows 2003 web server. I have an ASP.NET application which runs great on one of them. Dedicated IP address, behind our firewall, etc. Everyone's...
6
by: Andrew Robinson | last post by:
I am running two servers with a hardware network load balancing device. I know that to share session information between the two servers I need to implement some type of SQL based session...
2
by: RahulBose | last post by:
I am trying to implement Load Balancing but facing some problems: A Web farm usually consists of 2 or more computers, orchestrated by some form of load balancing. Consider my scenario: 1. I...
0
by: ors.public.email | last post by:
Hi, My company has recently experienced an issue when posting back aspx pages across multiple servers that were being load balanced. In a nutshell, the problem involved initially loading the...
4
by: nemesis.saurabh | last post by:
hi, i am stuck up on this problem. In a load balanced scenario the post back is not happening i.e. when a control on the web form is clicked, the post back does not occur at the server and...
1
by: m.a | last post by:
Hello, I am looking for a hosting solution for my asp.net application. I found that some ISP stated that session states are not preserved in a load balancing system. As I know, if the asp.net is...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.