Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

i have an ubuntu network machine which has release of 10.04.1 LTS Lucid. on this system i have apache, postgresql and django. for some app. development i have to install php and php-curl... due to being on network, i have exported wmvare machine to internet and firstly i have upgraded system and then install php5 packages on it.

After all replacing it with its old place, i have considered that the new system query is some slow according to another.

Old system query time : 140 ms

New system query time : 9.11 s

i have checked /etc/network interface and it seems there is no problem. i have checked /etc/resolv.conf and it seems ok i have checked /etc/nsswitch.conf and only host section is different from old one which old system has hosts: files mdns4_minimal [NOTFOUND=return] dns mdns4

and then i have checked time host -t A and i got

real 0m0.355s
user 0m0.010s
sys  0m0.020s

and i have checked apache2 HostnameLookups :

find /etc/apache2/ -type f | xargs grep -i HostnameLookups 

it returned :

/etc/apache2/apache2.conf:# HostnameLookups: Log the names of clients or just their IP addresses
/etc/apache2/apache2.conf:HostnameLookups Off 

and now what can i have to check for boosting my system as before?

share|improve this question
up vote 1 down vote accepted

Use the method: Control and Conquer.

Stop one process and see its impact on the given time. If no change, continue so long that such a change come.

I would start with Django, then with Apache and then with PHP.

So first find out what may cause the problem.

It is apparent that some of your code is in old standards and after upgrading some language, probably PHP or Python, the things changed.

I would like to see what process take most memory in your system. So what process is causing the 9.11s delay?

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.