Problem not yet solved
I thought the problem was solved by freeing up this memory by switching off amavis, but again the server came to a stand still today.
Having had a look at the syslog as below it keeps reporting problems of memory. At the time of these problems, apache stops responding for a good 20 minutes and I can't event get in through SSH, it just hangs.
I've looked at the charts from munin and although the load does go high at this time, i'm assuming that that is caused by by the lack of memory. I'll try and attach the graphs below.
If you wouldn't mind helping me sort this out it would be much appreciated.