Debugging has become really slow ... Why and how can I fix this?

Discussion in 'ASP .Net' started by Dean R. Henderson, Oct 18, 2003.

  1. I have a project built for ASP.NET that recently started running really slow
    in debug mode (it takes about 10 seconds or more to step from one line of
    code to the next).

    This just started recently and only impacts one ASP.NET project. I have
    some other ASP.NET projects that I can step thru with the debugger with
    almost instant response. I also have some Windows Forms projects that work
    normally.

    I am running Visual Studio 2003 and using VB as my language on a Windows
    2000 Server (having Service Pack 3) with Sql Server 2000 (having Service
    Pack 3).

    I added a function to create an Excel workbook from data in my Sql Server
    around the time the slowdown surfaced, but I have removed this code and the
    Excel reference in the project, but this did not change the slowdown
    problem.

    Does anyone have any idea what could be causing this slowdown and how to
    correct it ... Thanks, Dean
     
    Dean R. Henderson, Oct 18, 2003
    #1
    1. Advertising

  2. Hi Dean,

    Thank you for using Microsoft MSDN managed newsgroup.

    It is difficult to give a specific answer to such a performance issue.
    Thank you for your undestanding. In ASP.NET, Debug mode degrades
    performance significantly.

    Based on my research and experience, the following aritcle is useful to
    you. Please refer to it carefully.

    Performance Tuning Tips
    http://samples.gotdotnet.com/quickstart/aspplus/doc/perftuning.aspx
    "...
    Any programming model has its common performance pitfalls, and ASP.NET is
    no exception. This section describes some of the ways in which you can
    avoid performance bottlenecks in your code.
    ..."

    I hope it helps.

    Best regards,

    Jacob Yang
    Microsoft Online Partner Support
    Get Secure! ¨C www.microsoft.com/security
    This posting is provided "as is" with no warranties and confers no rights.
     
    Jacob Yang [MSFT], Oct 20, 2003
    #2
    1. Advertising

  3. Hi Jacob,

    Thank you for the article on performance tips.

    My problem is not degraded performance when browsing pages in a project. My
    problem is the performance of debug mode itself.

    I have several ASP.NET projects and in all but one of these projects, debug
    mode allows me to step thru my code with almost instant response. But, one
    of my ASP.NET projects just recently started having a problem with how long
    it takes to step thru my code. The problem I am having is that it takes
    over 10 seconds to step from one line of code to another or to move from one
    breakpoint to another. Until just recently, this project was able to step
    thru code or move from one breakpoint to another almost instantly.

    For other projects on this computer system, I do not have any delay when
    stepping thru code for those projects or moving from one breakpoint to
    another.

    For the ASP.NET project having this debug performance issue, there has been
    no corresponding performance change for access to various pages in this
    project during normal browsing.

    I have been using the Visual Studio debugger for several years and have
    found it is an incredibly powerful tool for use when debugging code, but
    when it takes over 10 seconds to step thru each line of code or move from
    one breakpoint to another, the debugging process becomes almost useless and
    very frustrating.

    I suspect that I made some change to configuration or included some
    conflicting components to the impacted project that has recently introduced
    this debug mode performance problem in a way that is only impacting this one
    project and not others, but I have not been able to figure out how to fix
    the debug mode performance problem.

    I am hoping to isolate exactly what I have done to introduce this debug mode
    performance problem so that I can avoid having this same problem in other
    projects I work on.

    Thanks for any suggestions you can provide in regard to configuration or any
    other tips that might help resolve this debug mode performance problem.

    Thanks,

    Dean

    "Jacob Yang [MSFT]" <> wrote in message
    news:...
    > Hi Dean,
    >
    > Thank you for using Microsoft MSDN managed newsgroup.
    >
    > It is difficult to give a specific answer to such a performance issue.
    > Thank you for your undestanding. In ASP.NET, Debug mode degrades
    > performance significantly.
    >
    > Based on my research and experience, the following aritcle is useful to
    > you. Please refer to it carefully.
    >
    > Performance Tuning Tips
    > http://samples.gotdotnet.com/quickstart/aspplus/doc/perftuning.aspx
    > "...
    > Any programming model has its common performance pitfalls, and ASP.NET is
    > no exception. This section describes some of the ways in which you can
    > avoid performance bottlenecks in your code.
    > .."
    >
    > I hope it helps.
    >
    > Best regards,
    >
    > Jacob Yang
    > Microsoft Online Partner Support
    > Get Secure! (C www.microsoft.com/security
    > This posting is provided "as is" with no warranties and confers no rights.
    >
     
    Dean R. Henderson, Oct 20, 2003
    #3
  4. Do you have a lot of watch variables set up? If you have a lot of these it
    takes VS time to grab the values to display...

    +++ Rick ---

    --

    Rick Strahl
    West Wind Technologies
    http://www.west-wind.com/
    http://www.west-wind.com/wwHelp
    ----------------------------------
    Making waves on the Web


    "Dean R. Henderson" <> wrote in message
    news:#...
    > Hi Jacob,
    >
    > Thank you for the article on performance tips.
    >
    > My problem is not degraded performance when browsing pages in a project.

    My
    > problem is the performance of debug mode itself.
    >
    > I have several ASP.NET projects and in all but one of these projects,

    debug
    > mode allows me to step thru my code with almost instant response. But,

    one
    > of my ASP.NET projects just recently started having a problem with how

    long
    > it takes to step thru my code. The problem I am having is that it takes
    > over 10 seconds to step from one line of code to another or to move from

    one
    > breakpoint to another. Until just recently, this project was able to step
    > thru code or move from one breakpoint to another almost instantly.
    >
    > For other projects on this computer system, I do not have any delay when
    > stepping thru code for those projects or moving from one breakpoint to
    > another.
    >
    > For the ASP.NET project having this debug performance issue, there has

    been
    > no corresponding performance change for access to various pages in this
    > project during normal browsing.
    >
    > I have been using the Visual Studio debugger for several years and have
    > found it is an incredibly powerful tool for use when debugging code, but
    > when it takes over 10 seconds to step thru each line of code or move from
    > one breakpoint to another, the debugging process becomes almost useless

    and
    > very frustrating.
    >
    > I suspect that I made some change to configuration or included some
    > conflicting components to the impacted project that has recently

    introduced
    > this debug mode performance problem in a way that is only impacting this

    one
    > project and not others, but I have not been able to figure out how to fix
    > the debug mode performance problem.
    >
    > I am hoping to isolate exactly what I have done to introduce this debug

    mode
    > performance problem so that I can avoid having this same problem in other
    > projects I work on.
    >
    > Thanks for any suggestions you can provide in regard to configuration or

    any
    > other tips that might help resolve this debug mode performance problem.
    >
    > Thanks,
    >
    > Dean
    >
    > "Jacob Yang [MSFT]" <> wrote in message
    > news:...
    > > Hi Dean,
    > >
    > > Thank you for using Microsoft MSDN managed newsgroup.
    > >
    > > It is difficult to give a specific answer to such a performance issue.
    > > Thank you for your undestanding. In ASP.NET, Debug mode degrades
    > > performance significantly.
    > >
    > > Based on my research and experience, the following aritcle is useful to
    > > you. Please refer to it carefully.
    > >
    > > Performance Tuning Tips
    > > http://samples.gotdotnet.com/quickstart/aspplus/doc/perftuning.aspx
    > > "...
    > > Any programming model has its common performance pitfalls, and ASP.NET

    is
    > > no exception. This section describes some of the ways in which you can
    > > avoid performance bottlenecks in your code.
    > > .."
    > >
    > > I hope it helps.
    > >
    > > Best regards,
    > >
    > > Jacob Yang
    > > Microsoft Online Partner Support
    > > Get Secure! (C www.microsoft.com/security
    > > This posting is provided "as is" with no warranties and confers no

    rights.
    > >

    >
    >
     
    Rick Strahl [MVP], Oct 20, 2003
    #4
  5. Hi Dean,

    Firstly I want to thank Rick's great help in this issue, please refer to
    his response carefully.

    In addition, have you installed any third party antivirus products such as
    Norton or Macfee. There are some reports regarding the performance issue
    caused by these third party products. Please try to uninstall them and test
    this issue again.

    I hope it helps.

    Best regards,

    Jacob Yang
    Microsoft Online Partner Support
    Get Secure! ¨C www.microsoft.com/security
    This posting is provided "as is" with no warranties and confers no rights.
     
    Jacob Yang [MSFT], Oct 21, 2003
    #5
  6. Hi Rick,

    Thanks for the suggestion.

    Per your suggestion, I did have several watch variables, but removing them
    did not change the debug mode performance ... Before and After removing the
    variables, I have found it is pretty consistent in that it takes about 14
    seconds after doing a step or resume command before the next step or
    breakpoint is reached or the application resumes running.

    Per a suggestion from Jacob Yang, I disabled Norton Anti-Virus, but this did
    not improve the debug mode performance either.

    I have recently setup another computer I can use to access this ASP.NET
    project and I have found this computer does not have any delay during debug
    mode for this ASP.NET project ... For now, that is providing me a way to do
    any debugging I need to get done.

    Since this other computer does not have the same problem, it would seem to
    be something in the configuration of the computer with the problem. The
    system with the problem is running Windows 2000 Server as well as hosting
    the IIS Web and SQL 2000 Database, while the system without the problem is
    running Windows XP Pro and accessing the Web and Database over a Fast
    Ethernet connection.

    Thanks again for your suggestion and any other thoughts you might have
    regarding this problem ... Take care,

    Dean

    "Rick Strahl [MVP]" <> wrote in message
    news:...
    > Do you have a lot of watch variables set up? If you have a lot of these it
    > takes VS time to grab the values to display...
    >
    > +++ Rick ---
    >
    > --
    >
    > Rick Strahl
    > West Wind Technologies
    > http://www.west-wind.com/
    > http://www.west-wind.com/wwHelp
    > ----------------------------------
    > Making waves on the Web
    >
    >
    > "Dean R. Henderson" <> wrote in message
    > news:#...
    > > Hi Jacob,
    > >
    > > Thank you for the article on performance tips.
    > >
    > > My problem is not degraded performance when browsing pages in a project.

    > My
    > > problem is the performance of debug mode itself.
    > >
    > > I have several ASP.NET projects and in all but one of these projects,

    > debug
    > > mode allows me to step thru my code with almost instant response. But,

    > one
    > > of my ASP.NET projects just recently started having a problem with how

    > long
    > > it takes to step thru my code. The problem I am having is that it takes
    > > over 10 seconds to step from one line of code to another or to move from

    > one
    > > breakpoint to another. Until just recently, this project was able to

    step
    > > thru code or move from one breakpoint to another almost instantly.
    > >
    > > For other projects on this computer system, I do not have any delay when
    > > stepping thru code for those projects or moving from one breakpoint to
    > > another.
    > >
    > > For the ASP.NET project having this debug performance issue, there has

    > been
    > > no corresponding performance change for access to various pages in this
    > > project during normal browsing.
    > >
    > > I have been using the Visual Studio debugger for several years and have
    > > found it is an incredibly powerful tool for use when debugging code, but
    > > when it takes over 10 seconds to step thru each line of code or move

    from
    > > one breakpoint to another, the debugging process becomes almost useless

    > and
    > > very frustrating.
    > >
    > > I suspect that I made some change to configuration or included some
    > > conflicting components to the impacted project that has recently

    > introduced
    > > this debug mode performance problem in a way that is only impacting this

    > one
    > > project and not others, but I have not been able to figure out how to

    fix
    > > the debug mode performance problem.
    > >
    > > I am hoping to isolate exactly what I have done to introduce this debug

    > mode
    > > performance problem so that I can avoid having this same problem in

    other
    > > projects I work on.
    > >
    > > Thanks for any suggestions you can provide in regard to configuration or

    > any
    > > other tips that might help resolve this debug mode performance problem.
    > >
    > > Thanks,
    > >
    > > Dean
    > >
    > > "Jacob Yang [MSFT]" <> wrote in message
    > > news:...
    > > > Hi Dean,
    > > >
    > > > Thank you for using Microsoft MSDN managed newsgroup.
    > > >
    > > > It is difficult to give a specific answer to such a performance issue.
    > > > Thank you for your undestanding. In ASP.NET, Debug mode degrades
    > > > performance significantly.
    > > >
    > > > Based on my research and experience, the following aritcle is useful

    to
    > > > you. Please refer to it carefully.
    > > >
    > > > Performance Tuning Tips
    > > > http://samples.gotdotnet.com/quickstart/aspplus/doc/perftuning.aspx
    > > > "...
    > > > Any programming model has its common performance pitfalls, and ASP.NET

    > is
    > > > no exception. This section describes some of the ways in which you can
    > > > avoid performance bottlenecks in your code.
    > > > .."
    > > >
    > > > I hope it helps.
    > > >
    > > > Best regards,
    > > >
    > > > Jacob Yang
    > > > Microsoft Online Partner Support
    > > > Get Secure! (C www.microsoft.com/security
    > > > This posting is provided "as is" with no warranties and confers no

    > rights.
    > > >

    > >
    > >

    >
    >
     
    Dean R. Henderson, Oct 21, 2003
    #6
  7. Hi Jacob,

    Thanks for the suggestion.

    Per your suggestion, I disabled Norton Anti-Virus, but this did not improve
    the debug mode performance.

    Per a suggestion from Rick Strahl, I did have several watch variables, but
    removing them did not change the debug mode performance ... Before and After
    removing the variables, I have found it is pretty consistent in that it
    takes about 14 seconds after doing a step or resume command before the next
    step or breakpoint is reached or the application resumes running.

    I have recently setup another computer I can use to access this ASP.NET
    project and I have found this computer does not have any delay during debug
    mode for this ASP.NET project ... For now, that is providing me a way to do
    any debugging I need to get done.

    Since this other computer does not have the same problem, it would seem to
    be something in the configuration of the computer with the problem. The
    system with the problem is running Windows 2000 Server as well as hosting
    the IIS Web and SQL 2000 Database, while the system without the problem is
    running Windows XP Pro and accessing the Web and Database over a Fast
    Ethernet connection.

    Thanks again for your suggestion and any other thoughts you might have
    regarding this problem ... Take care,

    Dean

    "Jacob Yang [MSFT]" <> wrote in message
    news:z#...
    > Hi Dean,
    >
    > Firstly I want to thank Rick's great help in this issue, please refer to
    > his response carefully.
    >
    > In addition, have you installed any third party antivirus products such as
    > Norton or Macfee. There are some reports regarding the performance issue
    > caused by these third party products. Please try to uninstall them and

    test
    > this issue again.
    >
    > I hope it helps.
    >
    > Best regards,
    >
    > Jacob Yang
    > Microsoft Online Partner Support
    > Get Secure! (C www.microsoft.com/security
    > This posting is provided "as is" with no warranties and confers no rights.
    >
     
    Dean R. Henderson, Oct 21, 2003
    #7
  8. Hi Dean,

    Based on my research and experience, please try the following steps on your
    side.

    1. Please delete the ASPNET account using Computer Management.

    a) Select Control Panel->Administrative Tools->Computer Management->Local
    Users and Groups->Users
    b) In the right pane, right click the ASPNET account and select "Delete"

    2. Please refer to the following Knowledge Base article carefully to repair
    IIS mapping.

    <http://support.microsoft.com/default.aspx?scid=kb;en-us;306005>

    3. Please restart IIS.

    a) Select Start->Run...
    b) Type the command "iisreset".

    4. Test this issue again.

    I hope it helps.

    Best regards,

    Jacob Yang
    Microsoft Online Partner Support
    Get Secure! ¨C www.microsoft.com/security
    This posting is provided "as is" with no warranties and confers no rights.
     
    Jacob Yang [MSFT], Oct 22, 2003
    #8
  9. Hi Jacob,

    The Windows 2000 server hosting my web and SQL Server is an Active Directory
    Domain Controller, so I am using a Domain account of ASPUSER because the
    built-in local ASPNET account does not work. There is a knowledge base
    article on how this must be setup, so I deleted the ASPUSER account and
    added it back in. It took quite a while to get everything back to normal
    (at least, almost everything ... Still have one glitch).

    This did not correct my debug mode performance on the Windows 2000 Server
    .... I was just trying to debug the glitch that I found after deleting the
    ASPUSER account ... This is a problem where an Excel WorkSheet.PageSetup
    object is now failing on the Orientation property:

    "<error: an exception of type: {
    System.Runtime.InteropServices.COMException } occurred>"

    It is taking 15-20 seconds everytime I try to step thru the code, go to a
    breakpoint or resume the application.

    Since I have another computer I can use to debug this problem with almost
    instant debug mode response, I hope to find out what is causing this new
    problem and will just have to put the debug mode performance problem on the
    back shelf for now.

    Best Regards,

    Dean R. Henderson

    "Jacob Yang [MSFT]" <> wrote in message
    news:...
    > Hi Dean,
    >
    > Based on my research and experience, please try the following steps on

    your
    > side.
    >
    > 1. Please delete the ASPNET account using Computer Management.
    >
    > a) Select Control Panel->Administrative Tools->Computer Management->Local
    > Users and Groups->Users
    > b) In the right pane, right click the ASPNET account and select "Delete"
    >
    > 2. Please refer to the following Knowledge Base article carefully to

    repair
    > IIS mapping.
    >
    > <http://support.microsoft.com/default.aspx?scid=kb;en-us;306005>
    >
    > 3. Please restart IIS.
    >
    > a) Select Start->Run...
    > b) Type the command "iisreset".
    >
    > 4. Test this issue again.
    >
    > I hope it helps.
    >
    > Best regards,
    >
    > Jacob Yang
    > Microsoft Online Partner Support
    > Get Secure! (C www.microsoft.com/security
    > This posting is provided "as is" with no warranties and confers no rights.
    >
     
    Dean R. Henderson, Oct 24, 2003
    #9
  10. Hi Dean,

    I have done more research regarding this issue.

    As I understand, you are trying to do the Server-Side Automation of Office.
    Unfortunately, Microsoft does not currently recommend, and does not
    support, Automation of Microsoft Office applications from any unattended,
    non-interactive client application or component (including ASP, DCOM, and
    NT Services), because Office may exhibit unstable behavior and/or deadlock
    when run in this environment.

    Please refer to the following Knowledge Base article for the detailed
    information regarding this issue.

    INFO: Considerations for Server-Side Automation of Office
    http://support.microsoft.com/default.aspx?scid=kb;en-us;257757
    "...
    This article discusses the complications that developers may face, offers
    alternatives to Automation that can speed performance, and suggests ways to
    configure Office if server-side Automation is unavoidable. Developers
    should be aware, however, that the suggestions provided below are for
    informational purposes only. Microsoft does not recommend or support
    server-side Automation of Office.
    ..."

    If I have misunderstood your concern, please feel free to let me know.

    Best regards,

    Jacob Yang
    Microsoft Online Partner Support
    Get Secure! ¨C www.microsoft.com/security
    This posting is provided "as is" with no warranties and confers no rights.
     
    Jacob Yang [MSFT], Oct 24, 2003
    #10
    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. Replies:
    3
    Views:
    3,087
  2. Xah Lee
    Replies:
    22
    Views:
    1,185
    Tim Roberts
    Mar 21, 2006
  3. Xah Lee
    Replies:
    23
    Views:
    1,129
    Tim Roberts
    Mar 21, 2006
  4. Mr. SweatyFinger
    Replies:
    2
    Views:
    2,226
    Smokey Grindel
    Dec 2, 2006
  5. Xah Lee
    Replies:
    21
    Views:
    852
    Tim Roberts
    Mar 21, 2006
Loading...

Share This Page