# Lightly used system with poor first use performance



## plumbob (May 9, 2012)

I have a box set up with FreeBSD 9.0, on a P4 3GHz, 0.5GB RAM.  It is used to host a small website using the AMP framework as well as being a private FTP hub and CVS repository for my own use.  The computer gets 1-10 hits per day on the web server and I use it daily for FTP or CVS.  However, the first few uses per day have absolutely atrocious response time.  It doesn't seem to matter what the task is, an SSH connection, SQL query through JDBC, webpage request to Apache, etc.  It will take the system upwards of 45 seconds to respond, even on a LAN connection for those first few requests.

After the system has handled a few requests and been actively used for perhaps fifteen minutes it runs like a dream with no problems at all.

Processor usage never tops 50%, there is always ~200MB of RAM free, the page file is empty.  I'm really at a loss as to what is going on and I'm hoping someone out there might be able to send me down the right path.

Thanks.


----------



## Deleted member 2077 (May 9, 2012)

Hard to say, but my guess is maybe someone has a big @reboot job in their crontab?

If not, try checking newest logs in /var/log while this in happening to see if that gives any hints.

Lastly, another guess might be something to do with power management?


----------



## ondra_knezour (May 9, 2012)

Maybe idle HDD must be powered up prior to response?


----------



## plumbob (May 9, 2012)

Is there a .conf file somewhere or something similar where I might adjust power management setting and the like?  Any suggestions better than just setting up a dummy cron job to keep the HDD alive would be welcomed.


----------



## SirDice (May 10, 2012)

Maybe it's more network related, a bad switch perhaps. How is everything connected?


----------



## wblock@ (May 10, 2012)

Another suspect in the "it's slow but shouldn't be" category is DNS.  The long pause while it tries to look up an address and times out does that.  If DNS is a problem, there's typically that long delay during startup where sendmail is trying a lookup.


----------

