When I live my magento store site the database size was 2.xx MB after one week when i take my database backup its size increase up-to 8.xx MB and browsing speed also reduced please any one tell me that why Database size is increasing automatically while i am not adding any new products in it and how to reduce it size to minimum

  • Its because your database stores various other things, like items in customer's shopping cart, New orders, New customers etc. For speed optimziation, give this a try google.com/#q=magento+store+optimization cheers :-)
    – echoashu
    Oct 1 '14 at 10:12
  • Make sure you've set up a cron entry to execute cron.sh or cron.php, then go into system config and setup log cleaning. 2MB a week probably is your log_ tables filling up and nothing set up to clean them out. Oct 2 '14 at 2:02
  • Besides manual/automatic log cleaning, you may want to have a look at the core URL rewrite bug and see if this is the problem. If your core_url_rewrite table grows conspicuously after each reindex, this is most probably the problem.
    – Simon
    Oct 2 '14 at 6:48
  • but i have set some 301 permanent redirects url if i clean core URl rewrite table then how my custom url will works? Oct 2 '14 at 8:13
  • @AdnanKashifJoyia you do not necessarily need to clean the table. So that the table does not grow further, you need to fix the bug as described in the other question.
    – Simon
    Oct 2 '14 at 9:11

A lot of various logs and events are stored in database tables for every visitor and a few other actions causing the database to grow over time even with no action on your part. These tables regularly be cleaned up without causing any harm. The following SQL enables you to empty these tables manually. Magento also has built in functionality to clean the logs which you enable at System >> Configuration >> Advanced >> System >> Log Cleaning.

truncate dataflow_batch_export;
truncate dataflow_batch_import;
truncate log_customer;
truncate log_quote;
truncate log_summary;
truncate log_summary_type;
truncate log_url;
truncate log_url_info;
truncate log_visitor;
truncate log_visitor_info;
truncate log_visitor_online;
truncate report_viewed_product_index;
truncate report_compared_product_index;
truncate report_event;

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.