Huge amounts of locale queries clogging up drupal to 40 MB per request I got an email today from my hosting company stating that they had to kill some processes of my site because it was using too much memory. Looking at the process table they provided, there were 10 processes of 40 MB, while my limit is 256 MB.

This poses me with two problems to solve.

1: Each page request drupal creates a process which uses 40MB of memory (which is of course killed again after the page is loaded). I've installed Devel and saw that each page makes around 900!! queries to the DB, most of which are from locale. All of them like this one:

   0.28270 locale P A E

   SELECT s.lid, t.translation, s.version 
       FROM locales_source s 
       LEFT JOIN locales_target t ON s.lid = t.lid AND t.language = :language 
       WHERE s.source = :source AND s.context = :context AND s.textgroup = 'default'
   default


How can I reduce this?

2: Apparently some1 put in 10 page requests at the exact same time (elapsed time of each process was equal). Is there something I can do about this?

If you need any more information please ask. Thanks in advance.
Does your site use a caching system like Boost? Try installing the Drupal boost module and see if it helps. It is a static page caching system and needs to access the database only once.