EDIT3
Boulevard theme was the culprit indeed. An update notifier service runs on every page request for logged in user (one would hope only for admins), which, for some reason takes #10 seconds of limbo-nothing-happening before page all of a sudden loads. This of course affects the logged in user in both admin and public facing screens. Removed the file and voila, snappy page loads all around.
rant: entire day wasted, loss & gain with 3rd party software, arggghhh ;-)
EDIT2
Not MySQL either, Boulevard theme seems to be the culprit. How to workaround, I am not sure. Client paid for the theme and wants to use it, but administering the site is a nightmare; i.e. waiting forever for admin screens to load...
EDIT
Ok, I confirmed that initial http request arrives instantly at the firewall, logged in or not. However, there is then a 10+ second lagtime before further activity occurs at the firewall layer. I assume that WP sends along the session cookie and then, for reasons TBD, there is a delay in verifying that remote user is logged in.
I'll check MySQL now, assumed with low cpu/memory usage that this would not be a resources issue, but maybe it's a slow query at play...
ORIGINAL
What is the deal here?
new to WP, performance is fine when not logged in; however, 10+ seconds to load public or admin screens otherwise.
linux top shows nothing spectacular happening (no spiked cpu, memory usage), so what exactly is WP doing during these 10 pointless seconds? arggghhh ;-)
ajax requests are snappy, so something is happening with normal synchronous http requests that is making WP dog slow (hard to get much done waiting for screens to load, worse than waiting for an application to compile, at least something useful is being done while you wait!)
My semi-workaround is to have Chrome browser window opened, not logged into WP. There are I can view public pages instantly. Then, in Firefox slog away playing the waiting game logged into admin panel ;-(
Clues appreciated, WP impresses (look & feel) but not so much in this respect, madness...
Some Wordpress plugin that implement a cache, turn off cache for a user who is logged in. Wordpress is also known for using a lot a memory. It can slow down the global performance of your web server.
You can monitor the memory used by Wordpress for each page, using Memory Viewer
UPDATE: I just found this piece of code in update-notifier.php
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_TIMEOUT, 1);
$cache = curl_exec($ch);
curl_close($ch);
TIMEOUT was set to 10 (I guess seconds), edited to 1 sec as above and now while logged in everything works fine...10 seconds is just to big value
Related
I am not really sure how to google this, so I thought I could ask here.
I have the same image, posted on a page twice, will that slow down the execution time or will it remain the same since I am using the same resource?
The browser should be able to cache the image the first time it is requested from the source server. Most of the popular browsers should have this implemented. It should not have to load it twice, just once on the initial request to the server and then using the cached version the second time.
This also assumes the end user has the browser caching enabled. If that is turned off (even if the browser supports it), then it will make that extra request for the image since the cache is not there to pull from.
Im running a magento store with varnish.
When browsing my page for the first time (in 24 hours or so), the first page load is extremely slow (10 sec).
After that if i click links n stuff everything is fine... its only the first contact.
Here i got a chrome console screenshot of the network:
http://skc.5e5.de/q.jpg
Does someone have an idea what the reason could be?
That is because your non-cached is too slow and it is warming (likely you are on $20-50/mth servers), Varnish will not help you, unless your non-cached is 2-3s Google will penalise you and most visitors will abandon their carts. Hosting for Magento should be 1% of revenue, anything less and it will not work, technology can only take you so far, the rest is actually doing it correctly, and that needs the hosting budget.
I have noticed that when my internet connection is a bit slower all my wp sites take up to five minutes to load Google Chrome when I am logged in. The version of google chrome I am using is 17.0.963.83.
When I logout the site loads fine again. The dashboard also loads fine when I am logged in and I know it's not a problem with my theme because the same thing happens applies when I apply the default twenty eleven theme.
I have set up a dummy subscriber user so you can test it yourself (to see the difference between the logged in states you need a slow connection though :p)
h2euro.org/wp-admin
u: testuser
p: test
Does anybody have an idea why this is happening?
When logged in, it loads "aloha.js", which is almost a megabyte. Found using Chrome's dev tools, 'network' pane.
I use the Kohana3's Profiler class and its profiler/stats template to time my website. In a very clean page (no AJAX, no jQuery etc, only load a template and show some text message, no database access), it shows the request time is 0.070682 s("Requests" item in the "profiler/stats" template). Then I use two microtime() to time the duration from the first line of the index.php to the last line of index.php, it shows almost very fast result. (0.12622809410095 s). Very nice result.
But if i time the request time from the browser's point of view, it's totally different. I use Firefox + Temper data add-on, it shows the duration of the request is 3.345sec! And I noticed that from the time I click the link to enter the website (firefox starts the animated loading icon), to when the browser finish its work(the icon animation stops), it really takes 3-4 seconds!!
In my another website which is built with WikkaWiki, the time measured by Temper Data is only 2190ms - 2432ms, including several access to mysql database.
I tried a clean installation of kohana, and the default plain hello-world page also loads 3025ms.
All the website i mentioned here are tested in the same "localhost" PC, same setting. Actually they are just hosted in different directories in the same machine. Only Database module is enabled in the bootstrap.php for kohana website.
I'm wondering why the kohana website's overall response is such slow while the php code execution time is just 0.126 second?? Are there anything I should look into?
==Edit for additional information ==
Test result on standard phpinfo() page is 1100-1200ms (Temper data)
Profiler shows you execution time from Kohana initialization to Profiler render call. So, its not a full Kohana time. Some kind of actions (Kohana::shutdown_handler(), Session::_destroy() etc) may take a long time.
Since your post confirms Kohana is finishing in a 1/10th of a second and less, it's probably something else:
Have you tested something else other than Kohana? It sounds like the server is at fault, but you can't be sure unless you compare the response times with something else. Try a HTML and pure PHP page.
The firefox profiler could be taking external media into consideration. So if you have a slow connection and you load Google Analytics, then that could be another problem.
Maybe there is something related with this issue: Firefox and Chrome slow on localhost; known fix doesn't work on Windows 7
Although the issue happens in Windows 7, maybe it can help...
An issue has started recently, within Chrome and reportedly Firefox, pages would be loading fine and browsing would be as normal and then suddenly then a page would fail to load (continuing to spin as if loading). The page that fails is often not the same.
If I refresh the page or try to goto another page on the domain within the same browser, the browser doesn't even try to resolve the name or make a connection, and is then unable to load the page.
Swapping to another browser and I am back to browsing the domain normally again, while the original browser(in most cases Chrome) will not load the pages until a restart.
This has happened with 3 different people on 3 different machines in both Chrome and Firefox.
The domain that it is running off has allot of ajax calls within certain pages, I am not sure if the server is tripping out due to the number of requests from the one client...I am not sure.
I am not sure if this is a server, client or script functionality issue, as I can not personally reproduce it. I can do little to debug or work out what is causing this or how to fix it...
As you can see I am not sure of allot with this problem :) so I am throwing it out to stack-overflow in the hope that someone may have had similar experiences or have any directions I could look towards.
Cheers,
Brendan
If the page is making many requests in a short time, your firewall (router) may block it. I've noticed this behavior on my own router, and had to set it to a less restrictive level to make things work.