...

View Full Version : Please help troubleshoot site slowness



michael190s
01-20-2012, 09:36 PM
I have a web site which is written in PHP + Zend + JQuery.

The landing page takes 1.6 - 2 sec while it loads very little data from the DB, so no heavy DB queries.

I see in FireBug that the main request takes 1.5 or 2 seconds, while the rest of the scripts/images/csss are loaded after this

site hosted on hostmonster, shared hosting.

how can I troubleshoot it at what level I have a delay?

I can't publish the site's URL, but I will PM it to you so you can check it in FireBug

I'll buy you a beer if you could help me :) seriously

Thank you very much

tangoforce
01-20-2012, 10:08 PM
While it's not drawing much from the DB it doesn't mean that the server itself is capable of generating the page any quicker. It could have several thousand queries per second going through the DB and the CPU usage could be high. On shared hosts anything can happen.

michael190s
01-21-2012, 12:21 AM
Ok, here is what I see in FireBug

(Also I set site protection using .htaccess .htpasswd maybe this might be the problem?)

+915ms Request start time since the beginning
Request phases start and elapsed time relative to the request start:
0 265ms Blocking
+265ms 0 DNS Lookup
+265ms 0 Connecting
+265ms 0 Sending
+265ms 94ms Waiting
+359ms 0 Receiving
Event timing relative to the request start:
+664ms DOMContentLoaded
+2.05s load

GET mydomain.com mydomain.com 0
GET mydomain.com 200 OK mydomain.com 31.1 KB 74.220.215.56:80
1.11s
GET jquery.autocomplete.css 304 Not Modified mydomain.com 797 B 74.220.215.56:80
265ms
GET jquery.fancybox-1.3.4.css 304 Not Modified mydomain.com 8.3 KB 74.220.215.56:80
265ms
GET style.css 304 Not Modified mydomain.com 14.2 KB 74.220.215.56:80
281ms
GET custom.css 304 Not Modified mydomain.com 20.4 KB 74.220.215.56:80
281ms
GET jqtransform.css 304 Not Modified mydomain.com 8.5 KB 74.220.215.56:80
296ms
GET main.js 304 Not Modified mydomain.com 184.4 KB 74.220.215.56:80
343ms
GET jquery.autocomplete.min.js 304 Not Modified mydomain.com 14.2 KB 74.220.215.56:80
359ms
GET jquery.fancybox-1.3.4.js 304 Not Modified mydomain.com 27.6 KB 74.220.215.56:80
406ms
GET jquery.jqtransform.js 304 Not Modified mydomain.com 13.4 KB 74.220.215.56:80
406ms
GET cufon-yui.js 304 Not Modified mydomain.com 17.8 KB 74.220.215.56:80
406ms
GET Futura_500.font.js 304 Not Modified mydomain.com 46.8 KB 74.220.215.56:80
406ms
GET _badge.jpg 304 Not Modified mydomain.com 31.9 KB 74.220.215.56:80
94ms
GET like.php?href=http...nt=arial&height=21 200 OK facebook.com 6.1 KB 69.63.181.15:80
140ms
GET top_shadow.png 304 Not Modified mydomain.com 299 B 74.220.215.56:80
125ms
GET free_sign.png 304 Not Modified mydomain.com 3 KB 74.220.215.56:80
140ms
HeadersCache
Response Headersview source
Connection Keep-Alive
Date Fri, 20 Jan 2012 22:44:58 GMT
Etag "4e9c0d8-bdd-4b62fd7bc4280"
Keep-Alive timeout=10, max=28
Server Apache
Request Headersview source
Accept image/png,image/*;q=0.8,*/*;q=0.5
Accept-Charset ISO-8859-1,utf-8;q=0.7,*;q=0.7
Accept-Encoding gzip, deflate
Accept-Language en-us,en;q=0.5
Authorization Basic ZGVtbzpkZW1vMTIz
Cache-Control max-age=0
Connection keep-alive
Cookie PHPSESSID=9n6uqjfrpqa9rpnrj2oppe2s63
Host mydomain.com
If-Modified-Since Tue, 10 Jan 2012 17:28:26 GMT
If-None-Match "4e9c0d8-bdd-4b62fd7bc4280"
Referer mydomain.com
User-Agent Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.24) Gecko/20111103 Firefox/3.6.24 (.NET CLR 3.5.30729) WebMoney Advisor
Response Headers From Cache
Accept-Ranges bytes
Content-Length 3037
Content-Type image/png
Date Fri, 20 Jan 2012 22:44:58 GMT
Etag "4e9c0d8-bdd-4b62fd7bc4280"
Last-Modified Tue, 10 Jan 2012 17:28:26 GMT
Server Apache


GET _step1pic.jpg 304 Not Modified mydomain.com 15.6 KB 74.220.215.56:80
140ms
GET _step2pic.jpg 304 Not Modified mydomain.com 17.8 KB 74.220.215.56:80
156ms
GET _step3pic.jpg 304 Not Modified mydomain.com 14.6 KB 74.220.215.56:80
172ms
GET steps_shadow.jpg 304 Not Modified mydomain.com 5.4 KB 74.220.215.56:80
203ms
GET bottom_shadow.png 304 Not Modified mydomain.com 315 B 74.220.215.56:80
219ms
GET ga.js 304 Not Modified google-analytics.com 13 KB 74.125.225.128:80
109ms
GET bg.jpg 304 Not Modified mydomain.com 3.7 KB 74.220.215.56:80
110ms
GET logo.png 304 Not Modified mydomain.com 26.9 KB 74.220.215.56:80
125ms
GET side_shadow.png 304 Not Modified mydomain.com 155 B 74.220.215.56:80
125ms
GET form_area_bg.png 304 Not Modified mydomain.com 87.2 KB 74.220.215.56:80
141ms
GET form_bg.png 304 Not Modified mydomain.com 34.9 KB 74.220.215.56:80
157ms
GET psaxno_bg.png 304 Not Modified mydomain.com 3.9 KB 74.220.215.56:80
172ms
GET select_bg.png 304 Not Modified mydomain.com 1.3 KB 74.220.215.56:80
219ms
GET vrisketai_bg.png 304 Not Modified mydomain.com 2.6 KB 74.220.215.56:80
235ms
GET search.png 304 Not Modified mydomain.com 5.8 KB 74.220.215.56:80
328ms
GET show_arrow.png 304 Not Modified mydomain.com 2.1 KB 74.220.215.56:80
297ms
GET steps_bg.jpg 304 Not Modified mydomain.com 3.7 KB 74.220.215.56:80
313ms
GET steps_title.jpg 304 Not Modified mydomain.com 45.9 KB 74.220.215.56:80
328ms
GET step1title.png 304 Not Modified mydomain.com 2.5 KB 74.220.215.56:80
344ms
GET step2title.png 304 Not Modified mydomain.com 3.1 KB 74.220.215.56:80
344ms
GET step3title.png 304 Not Modified mydomain.com 3.2 KB 74.220.215.56:80
391ms
GET r_u_title.png 304 Not Modified mydomain.com 2.1 KB 74.220.215.56:80
406ms
GET speciality_title.png 304 Not Modified mydomain.com 2.9 KB 74.220.215.56:80
422ms
GET arrow_right.png 304 Not Modified mydomain.com 986 B 74.220.215.56:80
422ms
GET insurance_title.png 304 Not Modified mydomain.com 3.3 KB 74.220.215.56:80
437ms
GET q_a_title.png 304 Not Modified mydomain.com 2.9 KB 74.220.215.56:80
453ms
GET futurastd-book-webfont.woff 304 Not Modified mydomain.com 21.5 KB 74.220.215.56:80
172ms
GET futurastd-heavy-webfont.woff 304 Not Modified mydomain.com 22.2 KB 74.220.215.56:80
187ms
GET dropdown_arrow.png 304 Not Modified mydomain.com 1.7 KB 74.220.215.56:80
484ms
GET YYZrixQZaWZ.js 200 OK static.ak.fbcdn.net 49.3 KB
154ms
GET qmP6DVX8EqF.css 200 OK static.ak.fbcdn.net 3.8 KB
167ms
47 requests 833.4 KB (796.2 KB from cache)
2.93s (onload: 2.96s)

--------------------------------------------------------------------------------------------------------------------------

47 requests 833.4 KB (796.2 KB from cache)
2.46s (onload: 2.56s)

tangoforce
01-21-2012, 12:39 AM
Not much else I can say, you've not even acknowledged my last reply but just carried on posting more stuff which isn't really going to help.

michael190s
01-22-2012, 04:09 PM
Not much else I can say, you've not even acknowledged my last reply but just carried on posting more stuff which isn't really going to help.

tangoforce, there are no other users working with my site at this moment. I think hostmonster provides enough resources to run not very complicated PHP/MySQL site in a single user mode :)

tangoforce
01-22-2012, 06:12 PM
You *think* but have no real idea. My previous post still stands - I reckon its the server you are on.

Seeing as you haven't provided us anything else of any use (such as source code, a log of SQL queries your code is running per script call etc) then thats all any one here can say to you - the server.

Posting more stuff about your http calls and headers is pointless as it only tells us whats happened and nothing much else of any use. Your opening post clearly states your script reads very little information from the database so that being the case, your server is either under heavy use or the internet connection its on is at its maximum capacity (easily confused with a strained server).

Comprende?



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum