Speeding up Web Apps

Posted on 2006-06-21
Last Modified: 2008-03-03
Hi Guys,

I have a c# .net web application using IIS6, SQL2005, MapXtreme and (ASP front end).

It is running extremely slow.  I have optimised my code as much as possible, I have put IIS on the same machine as SQL Server and i have installed extra network cards into the Web server / SQL server and created a MAC Bridge.

I can't give too many details on the application as it is a work project and there are confidentiality issues.  Does anyone know or have any suggestions as to what i can do in order to try and find out:

A) why it is running so slow

B) what i can do to speed it up.

Bearing in mind i cannot give out much more detail than this, I am making it worth 500 points for whoever can give advice, suggestions, hints or tips in order for me to speed the thing up
Question by:NAORC
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
  • 2
  • +2

Author Comment

ID: 16951388
Dont know whether or not it makes a difference, but a select few machines have fast responce times and the app works fine, but on most its real slow.  I have looked at too many settings to name and had no joy..

Expert Comment

ID: 16951819
A sure fire way to speed up an ASP app that is sluggish is to implement page caching.  This feature of is very helpful and very customizable.

Good luck.

Expert Comment

ID: 16952145
i think reading large nb of data from databases slowes a lot ur application. u can apply Maintenance Plan to ur db. it might help.
also try to optimize ur queries.
also try to use as much as u can client side scripts as vbscripts, javascripts to minimize going to the server.

that s the most i can tell u since  i dont know execlty what ur app do.

good luck

Space-Age Communications Transitions to DevOps

ViaSat, a global provider of satellite and wireless communications, securely connects businesses, governments, and organizations to the Internet. Learn how ViaSat’s Network Solutions Engineer, drove the transition from a traditional network support to a DevOps-centric model.


Accepted Solution

lostcarpark earned 500 total points
ID: 16952528
Hmmm, this sounds familiar. Do you have a lot of viewstate information in your app? You can find out by using the "View Source" command in your browser. There will be a block of binary data near the top of your page source. If there is more than a couple of lines of data, it can seriously affect performance, particularly on slower networks.

I have an app with a lot of UserControls that are hidden when not required, and I ran into a very similar problem. The solution I found was to move the viewstate from the client to the server and store it in the Session. This can be achieved quite neatly by changing the base class of your pages to one that inherits from the standard one, but replaces the methods that save and retrieve the viewstate with ones that sasve to the Session.

You can find more about this here:

Hope this is helpful to you.


Author Comment

ID: 16952709

Yeah, i think thats quite a bit....

Expert Comment

ID: 16952763
It is quite large but not abnormally large.

I'd give some other things a try before implementing a custom view state for your app.  

Expert Comment

ID: 16952773
A good way to test would be perform some similar logic on a code behind without adding any controls on your ASPX page.  This will keep the View State small and also allow you to run your logic and do a latency test.

Expert Comment

ID: 16954610
In my opinion your viewstate is tiny. That is definitely not the issue.

First you need to find out where the app is running slow. Is it the code? Are your SQL queries slowing down the website?

Create a couple of static html pages and see how fast they load.

Also you could use SQL Server profiler to monitor the activity between your app and the database server. See if any queries are taking too long to execute.

Use stored procedures if you are not already doing so.

Create some indexes to optimize your queries.

In the web.config file disable debug.

Make sure your select queries return only the columns your are actually using.

How is you CPU usage when the app is running.
Is it nearly 100% and if yes check to see which processes are using that much cpu and also check your memory usage.

Check the memory usage when the app is running.

Do some timing on you code blocks and see how fast they execute.

I hope this helps.

Expert Comment

ID: 16956173
I agree that ViewState is not excessive (I wouldn't go so far as to say "tiny", but I've seen ones that run to several hundred K), so something else must be the issue. You mentioned that it runs okay on higher spec PCs, but the problem mainly occurs on older, slower machines. This would suggest that the problem is at least partly on the client side. Are you using any 3rd party controls that have a large JavaScript element? This would be relying quite heavily on the client PC and contributing to the problem.

Author Comment

ID: 16958823
All answers appreciated.  We are working on implimenting some answers now.  if and when one works, point will be awarded.  thanks in advance for patience experts, but this is a lot of code we need to work on.

Author Comment

ID: 17008752
Sorry guys, please bear with us... we've hit some dificulties.

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

"In order to have an organized way for empathy mapping, we rely on a psychological model and trying to model it in a simple way, so we will split the board to three section for each persona and a scenario and try to see what those personas would Do,…
Color can increase conversions, create feelings of warmth or even incite people to get behind a cause. If you want your website to really impact site visitors, then it is vital to consider the impact color has on them.
Viewers will get an overview of the benefits and risks of using Bitcoin to accept payments. What Bitcoin is: Legality: Risks: Benefits: Which businesses are best suited?: Other things you should know: How to get started:
The is a quite short video tutorial. In this video, I'm going to show you how to create self-host WordPress blog with free hosting service.

735 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question