I’ve already contacted help, looked into, and so forth…
The issue: I had previously hosted a Wiki based via Mediawiki on a Shared Hosting plan. Pages could load in about 3-4 seconds, sometimes less.
I’ve since switched to a VPS - For both my files and and database. My website now takes 5-13 seconds to load any given page, and on rare occasion 4-5 seconds, for no definite reason.
First of all: I contacted support and explained my issue. A couple of days later, I got a reply with an analysis saying citing specific files as being the source of this issue (Files that loaded perfectly fine from the shared hosting), and was told I should make sure they were correctly configured & such. The files in question were a 900 byte cS file, a 400 byte JavaScript file, and two 3.4 kb images. These files ‘ate’ nearly 4-6 seconds of load time.
What’s strange about this:
- Every test I ran a test myself, different images on the page would delay, while others would load nearly instantly. For instance, sometimes a 5 Kb file would take 5 seconds, while a 10 Kb image would load instantly, or two identical images would have a significant difference in load time. Removing an image causes the next image down the line to load slowly.
- As mentioned, once again, these load times did not occur on the shared hosting plan.
Secondly: It took a bit of convincing to convince the person I was speaking with that the issue did not lay within the files, but that the files are loading slower than before. They did another test, and said that the load time improved. This was a fluke; the next test I ran was just as slow as before. After some back and forth conversation, I asked the employee to run a test on another website running out of a Dreamhost VPS, and test it against my site. Though they didn’t give me their results, here’s what I got with my own test:
My site:
- 100-150 mb page. (Main Page)
- 30 or so requests.
- My SQL VPS with 300 mb of memory
- File transfer VPS with 300 mb of memory
- Running latest dev version of Mediawiki
- Traffic: Virtually none.
- Load time: 7.23 seconds.
The ‘other’ site:
- About 2 kb sized pages
- Lots of requests everywhere, some to google for JQuery, some from itself, some from other sites like Twitter, Facebook and various others
- About 1.8 gb memory for SQL and file system
- Runs custom software
- Traffic: 11-20k unique visitors per month
- Load time: 1.74 seconds.
I was then told that my site is running slow because I’m using A software package (Mediawiki) and ‘their’ site runs fast because they’re using homemade software (Which still doesn’t account for the fact that images and other normal files load so slowly)
So, if Mediawiki’s to blame, then why does the following test say that the main Mediawiki site, which receives far more traffic and delivers larger pages loads this quickly?:
It just doesn’t make any sense. Sure, the Wikimedia foundation probably has much more powerful servers in terms of memory and such, but in proportion, my site with 0 external traffic on a daily basis and 300 MB for each the database and file system paired with smaller pages should load just as quickly, correct?
…And it’s not just official Wikimedia projects with pages larger than mine that load quickly:
More than enough evidence that it’s not Mediawiki’s fault.
Does this sound familiar or…? The issue here is not only the fact that the VPS is dog-slow, but the fact that it runs slower than the shared plan.