[wp-hackers] Database Maintenance and Canonical Plug-ins

Jeremy Clarke jer at simianuprising.com
Fri Jun 18 13:37:23 UTC 2010

Like others I think your idea is okay but your solution is actually much
more specific to your needs than you think it is.

As far as revisions go I think they are the biggest issue with database size
in WordPress at the moment. Before they were added in core my databases
rarely got over 20mb but since their addition even moderately-sized sites
invariably skyrocket to over 100mb of database, making it near-impossible to
manage them with common tools like PHPMyAdmin and complicate all processes
related to backing up, migrating and maintaining development copies.

Personally I think everyone should be carefully considering how many
revisions they want to store for each post, rather than storing them all.
Usually the revision you want happened recently (due to some error on your
part or network error on the system's part), so you don't need that
revisions from 15 saves ago. There are plugins that limit the number but it
is much easier to use the constant:

        if (!defined('WP_POST_REVISIONS')) define('WP_POST_REVISIONS', 5);

Everyone should add this in their wp-config.php, it makes a HUGE difference.

IMHO the number of revisions should be an option in the SETTINGS > WRITING
screen, and there should be a default that is not infinity.

Jeremy Clarke | http://jeremyclarke.org
Code and Design | http://globalvoicesonline.org

More information about the wp-hackers mailing list