I'm having problem with one of my Rails applications, that runs on 365MB VPS, which seems to be not very much. When there are more than 3-5 users at the same time it runs out of memory and starts to use swap, which is f****** slow.
As I look into
top, I can see that there are many spawned instances of mysql (much more than Rails processes). Is this normal?
How do you recommend to scale down application for low memory enviromnent?
I'm using Ubuntu 9.04, Apache2.2 with mod passenger, MySQL 5.075 and Ruby 1.8.7
edit: After your suggestions, I upgraded VPS to 540MB, which for now seems to suffice. However, I'm just a poor student, so I can't pump too much money in some project I'm doing mostly for myself, untill it starts to pay back at least something.