I just migrated a website from a host to another. And in one day, my error_log got up to 70GB. How to stop this?

  • 2
    You should check exactly what is causing this. It is unfortunately impossible to pin point something with the info given. I should also note that you should speak to your new host as well as it seems that this issue only happened after moving to a new host Feb 25, 2015 at 17:08
  • 4
    You would stop your error log by fixing the errors, without any details of what they are, nothing can be done to help within a WordPress context.
    – Tom J Nowell
    Feb 25, 2015 at 17:24
  • 70GB in one day is nuts, so there's unusual going on which you should fix. However, you can also configure logrotate to split (and discard) log files when they reach a certain size. thegeekstuff.com/2010/07/logrotate-examples Feb 26, 2015 at 6:42

1 Answer 1


Most important thing here would be to figure out what's causing the errors as opposed to just hiding them. 70 GB file might be tough to open, so you can use tail to open up the last several lines of it tail -f error.log and see what's going on. Maybe it's a quick fix.

If it's filling up with notices and things you're okay with you might have debugging turned on? Turn it off in wp-config:

define( 'WP_DEBUG', false );

// don't generate log
define( 'WP_DEBUG_LOG', false );

// don't display errors
define( 'WP_DEBUG_DISPLAY', false );
@ini_set( 'display_errors', false );
  • It seems I have to define tmp path in wp-config.php, and since my web host doesn't have a tmp directory set up, I will have to contact them. Thanks for the help!
    – aerish
    Feb 27, 2015 at 15:56

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