0

I'm running a LAMP stack on an Amazon EC2 micro instance with 616 MB of memory. This seems sufficient to be able to run a few small websites with Apache, MySQL and PHP. I have one Wordpress site installed and anytime I interact with it I see huge amounts of disk reads and writes which Amazon tracks and charges for. There is one MySQL database that is 2MB in size so it should easily be able to keep that in memory. Running free -t shows:

             total       used       free     shared    buffers     cached
Mem:        616408     529360      87048          0       4572      88908
-/+ buffers/cache:     435880     180528
Swap:            0          0          0
Total:      616408     529360      87048

Does this mean there is no swap space allocated on my box? Running iotop for the last 24 hours the largest IO percent wise is kswapd0 which I've learned is the swap management process. The largest IO disk reads are from named -u named followed by httpd and mysqld. The largest IO disk writers are [jbd2/xvda1-8] followed by mysqld. What is going on here? Are the tens of thousands of IO requests coming from thrashing or is MySQL maybe not behaving correctly?

  • 2
    You do not have any swap, so no, swap isn't causing any I/O. – depquid Dec 11 '13 at 19:29
  • Ok thanks. So would you suspect MySQL then? Or httpd (Apache)? – Joe M Dec 12 '13 at 17:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.