Php – Webserver running very slow

apache-2.2htmlhttpdPHPweb-server

I am going to attempt to post all relevant information to my problem so I don't get downvoted. Any help/guidance will be much appreciated.

2 days ago, my website: http://ianon.info , http://ianon.info/pet_support/login2b.php

started to run VERY slowly. I have apache installed on my virtual private server and it is CENTOS. I do not know even how to begin to address the slowness of my website.

I know it is not JUST a PHP problem because html sites on the server take a VERY long time to load. I have restarted my apache several times and it still runs very slow.

When I ping it, I get:

64 bytes from ip-50-62-78-126.ip.secureserver.net (50.62.78.126): icmp_seq=1 ttl=64 time=0.025 ms
64 bytes from ip-50-62-78-126.ip.secureserver.net (50.62.78.126): icmp_seq=2 ttl=64 time=0.028 ms
64 bytes from ip-50-62-78-126.ip.secureserver.net (50.62.78.126): icmp_seq=3 ttl=64 time=0.031 ms
64 bytes from ip-50-62-78-126.ip.secureserver.net (50.62.78.126): icmp_seq=4 ttl=64 time=0.038 ms

When I traceroute I get:

traceroute to ianon.info (50.62.78.126), 30 hops max, 60 byte packets
1  ip-50-62-78-126.ip.secureserver.net (50.62.78.126)  0.022 ms  0.008 ms  0.008 ms

I don't think it is a memory issue because it appears that I have free memory:

$: free -m
         total       used       free     shared    buffers     cached
Mem:          1024        436        587          0          0          0
-/+ buffers/cache:        436        587
Swap:            0          0          0

Best Answer

A lot of the javascript modules you're trying to load is not loading. Mainly Bootstrap it look like.

I would recommend using bootstrapcdn and linking your javascript module to load from there instead of your own server.

Check this out: https://www.bootstrapcdn.com/legacy/

A good way to troubleshoot this issue is to load the site in Chrome and use F12 to get to the developer mode and look at the console or Network tab to see what's not loading or the loadtime for specific things and see how to improve it from there.

A good Chrome extension for optimization is called "Page Load Time", it'll display how long each page load time breaking down to the Request, Response, and DOM.