0

I'm getting an error when I try to open one of my dashboard pages in my wordpress script

The error message is as follows:

Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 72 bytes) in
    /home2/liquifac/public_html/grandviewbiz.com/wp-includes/wp-db.php on line 2413

I asked around and was told I have to increase the memory_limit to something higher than 256M, so I changed it to 512M and still the same problem.

So could you please tell me how to fix this and what should I do?

Petter Friberg
  • 21,252
  • 9
  • 60
  • 109
Achraf Yo
  • 11
  • 1
  • 4
  • Show the code that causes the error. – Sloan Thrasher Apr 14 '17 at 17:58
  • 3
    He does say it's in the WP dashboard, so there is no code to show. It could be caused by any number of plugins / theme / activity combinations. – Phill Healey Apr 14 '17 at 18:08
  • Off topic? More like duplicate of a protected answer: https://stackoverflow.com/questions/21680244/fatal-error-allowed-memory-size-of-268435456-bytes-exhausted-tried-to-allocate – ppostma1 Sep 18 '17 at 15:42

2 Answers2

1

Ok so this is basically WordPress saying that you don't have enough memory available to the dashboard / admin area. So here's a few things to try:

  1. Open your WP-config.php file in your site root and add the following

    define( 'WP_MEMORY_LIMIT', '512M' ); define( 'WP_MAX-MEMORY_LIMIT', '512M' );

  2. Disable all plugins and see if the issue goes away. If it does, start reáctivating plugins 1 by 1 until the issue returns. The plugin you activated last is the one pushing your system to its limits, although it may not be the single cause of the issue.

  3. Change your theme to one of the include WordPress default themes, to eliminate your theme as a cause.

  4. Increase the memory available to your site via the php.ini file.

  5. Increase system memory via your hosting control panel if available. Alternatively contact your hosting provider. They may even be able to help you identify the memory hog.

Ps. The front end of your website (grandviewbiz.com) is giving 500 errors. This should be showing up errors in your system error log. Speak to your web hosts if you don't have direct access to the log files. The logs should also help you narrow down the possible causes. If you work through these you WILL find the problem. It may simply be that you are on a crappy &/or low spec server that simple doesn't have enough memory to meet your sites needs.

Phill Healey
  • 3,084
  • 2
  • 33
  • 67
0

I have found the solution. The problem was caused by iThemes Security plugin. I turned it off and the errors have gone.

Nisse Engström
  • 4,738
  • 23
  • 27
  • 42
Achraf Yo
  • 11
  • 1
  • 4
  • 3
    Does showing the links to your websites add something useful to your answer? Be careful because it is easy to consider this as spam. – Steve Jul 03 '17 at 19:59
  • Thats not really a solution, it's just running away from the problem. You still have an underlying memory issue. – Phill Healey Jan 23 '20 at 11:35