PHP Code: 
mysql_query("DELETE FROM `dle_post` LIMIT 1"); 
You are running a script every single minute to delete one topic. This doesn't make sense. Put it on a 5 minute cron script and change the LIMIT to 5 which will be far more efficient on the server.

You should really order them as well by time. Yes it should remove older posts first but you want to make sure. I don't use DLE so don't know the name of the time column but you'll need something like this

PHP Code: 
mysql_query("DELETE FROM `dle_post` ORDER BY time ASC LIMIT 5"); 
the time needs to be changed to whatever the time column is called. Another thing you could do to prevent posts which are ranked high in Google from being removed which could seriously affect your traffic is to only DELETE posts with views lower than eg 20.

PHP Code: 
mysql_query("DELETE FROM `dle_post` WHERE views < 20 ORDER BY time ASC LIMIT 5"); 
Again you need to check the correct name for the views column.
Mr Happy Reviewed by Mr Happy on . DLE Huge database deleting outdated post problem Hi, I am using DLe on my website and the sql database is now 6GB with more than 1 million posts. I am having a problem when trying to delete outdated posts or when trying to delete about 100 posts at once the server keep sending "INTERNAL ERROR" message.. and i cant do anything.. I can only delete posts if i want to do 1 by 1 which will take me for ever to do. Anyone know any alternative for it? What i was thinking is if any script than exist than i can run and it will delete 1 Rating: 5