I'm more into the LAMP stack, but I've been asked to work on a site that is running Windows and IIS 2008. I'm a beginner with IIS, so please be patient with me on this, and please ask me to provide more information if that is needed to determine. I read the answer here (Slow first page load on asp.net site), but it seems like if I go to the site with one browser it takes long to load the first page, then fast on all other pages, then if I open up another browser, it's the same thing, so it's not something that is saved on the server, but per session? Is there a way to have the application running at all times? Right now it is taking 12 to 15 seconds for the first page to load. I have access to the WebControlCenter and FTP.
Page A loads very fast; Page B loads very slowly and does some CPU-intensive things on the web server. I noticed that if someone is loading Page B, then Page A also loads slowly - for ALL users. What is the standard practice for making sure this doesn't happen? If multiple users are loading Page B at the same time then Page A is ridiculously slow. Is there an IIS setting, web.config setting, or hardware configuration I could use to make sure that the fast-loading pages aren't bogged down by other pages that need more time to load?
The below SQL query is running extremely slow. Im using this query on other tables and its processing about 5 rows per second. The below version is running 1 row every 10 seconds when @SQLNew is executed.
There's a web app I've been assigned to, which is running very slow. It is a site that sells products so it is database driven, however even pages that do not query the database are loading very slow. The pages use master pages, and the code is in VB.NETI checked with fiddler and the time it takes to load basic (non database driven) pages are about 5.5 seconds on average.
What are some tools that can help me determine the cause of the slow speeds, and any recommendations as to how to speed it up, or potential issues that could cause it?UpdateSo I messed around with the code piece by piece as I wasn't getting anywhere with these tools. As soon as I remove master pages, and I include the same code that's on the master pages in the .aspx page itself, the speed improves drastically (approximately 5 times faster load times).What might cause the master pages to cause load times to slow down so much?
My web app connects to my database server which is on my lan. It is usually very quick but once in a while the connection is extremely slow and has even causing errors by timing out. The server only has 1 gb of memory so I'm going to upgrade to at least 4 gb.
I am using AUtomapper which I am very impressed with however, I have a complex object with many nested collections. I'm using Telerik OpenAccess and it returns the 1400 records fast but when I pass it to Automapper and it slows to a ridiculous crawl. Here is my code for reference:
i have created one windows application in c# .net and its working fine in windows xp, but when i try to install the setup in windows 7 or vista,the setup never runs.. should i have to write some code for it.
One of my peer wrote a query based on multiple tables using joins. One of the table is in a different database The query was taking much time
1. Create an SP 2. Create a temp table and copy all records from the external db 3. Avoid using Left Join as much as possible and use Inner Join 4. Create and use indexes 5. Remove tables/columns that are not necessary
In this scenario, I would like to suggest to use Covering Index, but how can it be created for multiple tables and a temp table?
I'm new in using C# in ASP.net My code is causing Internet Explorer to run slow and return error message asking to stop running this script.
When I use the "Select *...", it return about 700 rows of records and it cause the error.
When I use another SQL "Select NOC0854....", filtering some records, it return about 300 rows of records and no error message appear.
How I can improve my code so that I can retrieve all records from my table? I think 700 rows of records doesn't seem a lot, maybe my code is not correct?
Code: //cmd.CommandText = "Select * from PTH3759"; cmd.CommandText = "SELECT NOC0854 from PTH3759 WHERE HID0019 >= TO_DATE('11/01/2014','MM/DD/YYYY') AND HID0019 <= TO_DATE('11/28/2014','MM/DD/YYYY')"; cmd.CommandType = CommandType.Text; OracleDataReader dr = cmd.ExecuteReader(); if (dr.HasRows) { GridView1.DataSource = cmd.ExecuteReader(); GridView1.DataBind(); }
I have developed an application that interacts with IBM ClearQuest. The problem is that when I run everything locally, such as, run the webservice local and then ASP page local everything is at the speed I expect. When I post the webservice (precompiled) to the server and run the web page through the server, the call to the webmethod takes at least 10x the amount of time it should. I dont know why this is happening. I made a console application that has the function in question and execute it on the server and locally and they both return the same amounts of time (roughly) its just when I move to executing via the webmethod everything grinds to a snails pace. Any ideas? This happens every time not just on the first call.
WebMethod:
Public Function RetrieveQueryResults(ByRef cqSession As ClearQuestOleServer.Session, _ ByVal sqlStmt As String) As List(Of SearchResultsSingleIssue) Dim numCols As Integer, status As Integer, columnIdx As Integer Dim numRows As Integer Dim rowContents As String = "" Dim colValue As New Object Dim colLabel As New Object Dim allitems As New List(Of SearchResultsSingleIssue) Dim results As New SearchResultsSingleIssue Dim cqResultSet As ClearQuestOleServer.OAdResultset cqResultSet = cqSession.BuildSQLQuery(sqlStmt) cqResultSet.Execute() ' Get the number of columns returned by the query. numRows = 0 numCols = cqResultSet.GetNumberOfColumns status = cqResultSet.MoveNext ' Collect query results. Do While status = AD_SUCCESS results = New SearchResultsSingleIssue numRows = numRows + 1 For columnIdx = 1 To numCols colLabel = cqResultSet.GetColumnLabel(columnIdx) colValue = cqResultSet.GetColumnValue(columnIdx) 'Make sure that we dont pass along a null reference If colValue = Nothing Then colValue = "" End If Select Case colLabel Case "ID" results.IssueID = colValue Case "HEADLINE" results.Headline = colValue Case "NAME" results.State = colValue Case "OE_CONTACT" results.OEContact = colValue Case "DESCRIPTION" results.Further_Description = colValue Case "PRODUCT_NAME" results.Product_Name = colValue Case "FUNCTIONAL_AREA" results.Functional_Area = colValue Case "SUBTOPIC" results.Subtopic = colValue Case "FOUND_VERSION" results.Found_In = colValue Case "SCHEDULED_VERSION" results.Scheduled_For = colValue Case "SYMPTOMS" results.Symptoms = colValue Case "AFFECTED_SYSTEMS" results.Affected_System_Types = colValue Case "ISSUE_TYPE" results.Issue_Type = colValue Case "ASSIGNED_TO" results.Assigned_Developer = colValue Case "TESTED_BY" results.Assigned_Tester = colValue Case "BUILT_VERSION" results.Built_In = colValue Case "TESTED_VERSION" results.Tested_In = colValue Case "NOTES_LOG" results.Notes_Log = colValue Case "CUSTOMER_SEVERITY" results.Severity = colValue Case "PRIORITY" results.Priority = colValue End Select Next columnIdx ' Add the query row result to the compiled list of all rows. allitems.Add(results) status = cqResultSet.MoveNext Loop Return allitems End Function
Currently we are running an application build in VB6,ASP,Commerce Server2000 and Sql Server 2000. This application is running in Windows 2000 server.Now we are planning to migrate Windows server 2000 to Windows 2008.Will this application run in Windows 2008 or do we need to upgrade this application to dotnet and Sql 2008?
I recently upgraded to Windows 7 Ultimate on my work computer. Before this debugging a website in Visual Web Developer 2008 was really fast - the page loaded up like a normal website would.
Since I've upgraded to Windows 7 the page loads like normal but gets stuck for about 30 seconds at the end of the load - this is slowing me down as I normally need to use the FireBug tool as soon as the page has loaded.
Having real trouble using my local host to test sites. It runs extremely slow! Sometimes up to a minute to load a page. I'm using firefox and the sites i'm testing run fine on other developers in my office local machines/ on the production server.
I've gone through the normal things :-
Disabled IPv6 Not running in debug mood Put the site in the highest app pool (High Isolated) on IIS 6.Taking of firewalls etc.The problem only seems to occur when hitting pages which contain some form of .net code in the code-behind.
Appreciate that this a little bit of a vague topic / stab in the dark but would appreciate any sort of advice - it's horrible waiting a minute each refresh to try out a change!
Does anybody see any problem running an APS.Net 2.0 application on more than one browser windows at the same time concurrently? Users are accessing the application with IE and they do Control+N and access the same application in another windows and use both windows concurrently. Would there be any issue coming from session or anything such that I need to be concerned?
I have a really weird problem that I've been investigating for at least one week now. I deliver a website hosting both ASP classic and .NET 3.5 content in IIS6 on a Windows 2003 server environment with MySQL db backend. The solution has been installed on several servers (some hosted in WMWare) with no problems. On one specific server, also hosted in WMWare, the user experience great performance issues on the website. The problems are most seen when using database resources and is not limited to either .net or asp classic, but I am still not sure that the problem is only related to database calls.
Following components are involved:
IIS6 .NET FW 3.5 MyODBC 3.51 / 5.1 MySQL 4.x
Code executed on the server using all resources above runs smoothly when the IIS is not involved. The website shows times up to 2 minutes to execute code that takes 2 seconds outside the IIS. The exact same code is executed. Using profiling tools, I've seen that the great loss comes within calls to unmanaged code, for example when System.Data.ODBC namespace to calls into myodbc.dll.
The tricky part is: If at least one console user is logged in to the server, the performace problems are not seen anymore. When the user logs out, the problem appears again.I have tried to reinstall all components above, tried different versions of MyODBC, tried different website authentication methods, tried to run website under administrator privilegies, installed various MS KB's with no success.
1)My Windows services application folder is MyWInservice
2)Executable .exe i.e. “myServices .exe“ file located under MyWInservice \myServicesinDebug
3)I have RUN bat file C:WINDOWSMicrosoft.NETFrameworkv2.0.50727InstallUtil.exe /u "myServices.exe" C:WINDOWSMicrosoft.NETFrameworkv2.0.50727InstallUtil.exe "myServices.exe"
4)After running InstallUtil, myServices.InstallLog and myServices.InstallStategenerated under .. binDebug folder.
5)Upon pressing F5, I still get the same error. Error is:
Windows Service Start Failure,Cannot start service from the command line or a debugger. A Windows Service must first be installed (using installutil.exe) and then started with the ServerExplorer, Windows Services Administrative tool or the NET START command.
Hello all. I created a class that runs fine when using it with web forms, however when i create a Windows service and try to run it I recieve a NullReference error. Im not sure what else to do since the class works fine.Here is a snippet.
The service
public partial class Service1 : ServiceBase { //Timer object Timer RunTime; QBridge bridge_object = new QBridge() double test_interval = 40000; //test value public Service1() { InitializeComponent(); } protected override void OnStart(string[] args) { //Send email notification that intakes were pushed //bridge_object.SendNotification(bridge_object.service_startedtext); RunTime = new Timer(30000); //set the elapsed event RunTime.Elapsed += new ElapsedEventHandler(RunTime_Elapsed); //RunTime.Interval = SetInterval(); //calculated interval RunTime.Interval = test_interval; // test interval RunTime.Enbled = true; //set timer to true //QBridge bridge_object = new QBridge(); //bridge_object.SendNotification("start"); //SendNotification("start"); } protected override void OnStop() { RunTime.Enabled = false; RunTime.Dispose(); try { bridge_object.SendNotification("stop"); } catch (NullReferenceException nre) { System.Windows.Forms.MessageBox.Show("Error " + nre); } catch (Exception er) { System.Windows.Forms.MessageBox.Show("Error " + er); } //SendNotification("end"); } //Included this to test locally. works fine when just calling the method protected void RunTime_Elapsed(object source, ElapsedEventArgs e) { //SendNotification("run"); try { bridge_object.SendNotification(run); } catch (NullReferenceException nre) { System.Windows.Forms.MessageBox.Show("Error " + nre); } catch (Exception er) { System.Windows.Forms.MessageBox.Show("Error " + er); } } public void SendNotification(string email_text) { MailMessage initial = new MailMessage(); initial.Bcc.Add(new MailAddress("")); initial.From = new MailAddress(""); initial.Subject = "Web notification"; initial.IsBodyHtml = true; initial.Body = email_text; SmtpClient mailClient = new SmtpClient("192.168.1.1"); try { mailClient.Send(initial); } catch (Exception ex) { } } } Class using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Net.Mail; using System.IO; using System.Configuration; using System.Data.SqlClient; using System.Data; namespace Intake { public class QBridge { SqlConnection con = new SqlConnection(ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString); private string login_error; public QBridge() { } public void SendNotification(string email_text) { MailMessage initial = new MailMessage(); initial.Bcc.Add(new MailAddress("")); initial.From = new MailAddress(""); initial.Subject = "Web notification"; initial.IsBodyHtml = true; initial.Body = email_text; SmtpClient mailClient = new SmtpClient("192.168.1.1"); try { mailClient.Send(initial); } catch (Exception ex) { } } } }
I have created three basic websites using VS2010 and they are working fine when invidually run from visual studio. But in order to get the full functionality of the websites, they have to be run simultaneously. There are iframes inside one contaning pages from other website.
What is the way it can be done? Is hosting the only solution to it? If so please tell me how to host them in IIS7( i am currently running on windows 7 release candidate)
I want to implement client certificate in IIS 7.5 in windows 7. As per my knowladge I need to setup server certificate first for IIS. But I could not figure out how to do that.
I wasnt sure where this question best belongs, in the end I figured this was the best place...
Say I have a utility dll that i might use in either a windows console application or in an asp.net web application - how can I programatically find whether it is running on web or windows, from within the dll?
I feel like this is something I should know by now, maybe some property of AppDomain.CurrentDomain, or Environment, but I just can't find it.
The reason I'm asking is because I'm playing around with nHibernate for asp and I seem to need different session handling when running in asp.net, compared to when i'm running integration tests. So if someone knows how i can solve this without programatically checking the context of the application, then that'd be great too.
We have an web application which has been working fine on XP but which fails on Windows 7.I have a page where I'm executing several procedures on server-side and then must execute a vbscript function on client-side which I'm registering from my server code.The problem is after postback completed vbScript function is not executed at all.... even a simple "Alert" statement is not executed but only using Windows 7.... same code works fine on windows XP...
I am running a web application in vs-2008 on windows 2003 server.While execution of .net application, I am getting an error as"Unable to start debugging on the web server. Unable to connect to the web server. Verify that web server is running and that incoming HTTP requests are not blocked by firewall."