Now there's your problem. Upgrade your RAM to 3gb or more. OS's now a days recommend that you have at least 2gb of RAM just to make your OS work properly. You are relying on virtual memory to run applications and that is really a bad thing.
It is either that or you have a memory leak in which case you still need to upgrade the RAM.