Title: admin.php tries to increase memory_limit
Last modified: August 19, 2016

---

# admin.php tries to increase memory_limit

 *  Resolved [helpy](https://wordpress.org/support/users/helpy/)
 * (@helpy)
 * [16 years ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/)
 * In my server logs there is the following error:
 * [Thu Jun 03 13:14:08 2010] [error] [client 79.208.***.***] ALERT – script tried
   to increase memory_limit to 268435456 bytes which is above the allowed value (
   attacker ‘79.208.***.***’, file ‘/is/htdocs/wp*******_**********/example.com/
   www/wp-admin/admin.php’, line 91), referer: [http://example.com/wp-admin/index.php](http://example.com/wp-admin/index.php)
 * Is there a way to avoid this?
    cu, guido

Viewing 11 replies - 1 through 11 (of 11 total)

 *  Moderator [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [16 years ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/#post-1522455)
 * IIRC, admin.php does that when you’re running upgrades, but I could be wrong…
   What were you doing when that happened?
 *  Thread Starter [helpy](https://wordpress.org/support/users/helpy/)
 * (@helpy)
 * [16 years ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/#post-1522506)
 * When I refresh the dashboard, there will be 5 (five) entries in the server log
   with the mentioned error message.
 *  Moderator [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [16 years ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/#post-1522728)
 * I poked around but I can’t repro that.
 * What is your memory limit on that server?
 *  Thread Starter [helpy](https://wordpress.org/support/users/helpy/)
 * (@helpy)
 * [16 years ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/#post-1522755)
 * The memory limit (listed in phpinfo()) is 128 MByte.
 * And some more information:
 * – PHP Version 5.2.12
    – Apache/2.2 – WP 3.0 RC2 (was the same with RC1) – Multisite
   is ON … using subdomains (1 main blog, 1 blog on a sub domain) – Buddypress …
   and some other Plugins
 *  Moderator [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [16 years ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/#post-1522761)
 * It may be a plugin that’s causing that error.
 *  Thread Starter [helpy](https://wordpress.org/support/users/helpy/)
 * (@helpy)
 * [16 years ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/#post-1522791)
 * OK! I disabled all plugins (except buddypress) … it did not change anything!
 * Then I searched the code of wordpress and all installed plugins!
 * 1. admin.php – line 90 + 91:
 * if ( current_user_can( ‘manage_options’ ) )
    @ini_set( ‘memory_limit’, apply_filters(‘
   admin_memory_limit’, ‘256M’ ) );
 * Nowhere else in the code the tag ‘admin_memory_limit’ is used!
    This means, the
   function apply_filters will return the value ‘256M’ … … if I interpret this code
   correctly???
 * cu,
    guido
 *  Moderator [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [16 years ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/#post-1522797)
 * That looks like a correct interpretation, but I’ll have to sit and read the whole
   check and ifs to see if there’s a reason that gets called every time you run 
   admin.php.
 * This is now out of my depth, sorry 🙁
 *  Thread Starter [helpy](https://wordpress.org/support/users/helpy/)
 * (@helpy)
 * [16 years ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/#post-1522799)
 * Thank you for your time!
 * Solution, I do not like: ignore the “error” message in the server logs
 * cu, guido
 *  [Carlos Mundi](https://wordpress.org/support/users/carlos-mundi/)
 * (@carlos-mundi)
 * [15 years, 10 months ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/#post-1522837)
 * I must have forgotten to hit the “post” button last night. Apologies to those
   I referred to this thread before I actually posted. 🙂
 * I believe I am seeing the same thing. Any access — just landing on the home page—
   tries to eat 256MB.
 * Ubuntu 9.04 x64 512MB VPS
    Cherokee 1.0.5 MySQL 5.3.17 PHP 5.2.10 / Suhosin
 * phpinfo(): /etc/php5/cgi/php.ini with memory_limit=64MB
    wp-config.php: define(‘
   WP_MEMORY_LIMIT’, ’64M’);
 * Note that regardless of how low I set memory limits (simultaneously in php.ini
   and wp-config.php) my server log indicates that wp-admin.php is trying to grab
   256M, as described by Helpy earlier in this thread.
 * Symptoms are intense disk thrashing from a single pageload, leading to failed
   and partially rendered pages and server timeouts. Unusable.
 * I tried very hard to follow the directions to install WP3, but maybe I did something
   wrong. Any ideas about what I should check?
 * Or is it just a fact of life that WP really needs 256MB to be happy even with
   no plugins?
 * Thanks,
    Carlos
 *  [Carlos Mundi](https://wordpress.org/support/users/carlos-mundi/)
 * (@carlos-mundi)
 * [15 years, 10 months ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/#post-1522838)
 * OK, I think I’ve made some progress.
 * It now appears that the server logs complaining about an “attacker” trying to
   allocate 256MB and this being more than the php limit are only _correlated_ with
   disk thrashing but not actually _causation_.
 * My VPS recently bumped my RAM from 360MB to 512MB, but I was still running with
   a 360MB swap. I increased my swap to 512MB and
    1. the log messages still appear; but
    2. thrashing has stopped.
    3. I think this makes sense. Until I had WP going, everythign I had going on probably
       fit in 360MB of RAM most of teh time. So swapping, when even needed, was probably
       minimal. But now I have PHP grabbing up to 256MB. With only 360MB of swap, you
       can imagine the bottleneck. I don’t have enough data to say this was definitely
       the cause of the thrashing, but the data I do have is consistent with this theory.
       I will monitor this for a few hours to see.
    4. _So, yes, I did do something stupid._
    5. Thanks,
        Carlos
 *  [carbontwelve](https://wordpress.org/support/users/carbontwelve/)
 * (@carbontwelve)
 * [15 years, 3 months ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/#post-1522868)
 * The way to fix this is open your admin.php file within the wp-admin directory
   and search for 256M. I believe its on line 96. Change this to the maximum allowed
   memory limit as declared within your php settings and then save.
 * The error is kicked up when wordpress attempts to increase the maximum memory
   limit for php. To be honest 256MB per php process is a HUGE amount of memory,
   I have happily used wordpress with a limit of 32MB and it has kept on ticking
   over fine.

Viewing 11 replies - 1 through 11 (of 11 total)

The topic ‘admin.php tries to increase memory_limit’ is closed to new replies.

## Tags

 * [memory_limit](https://wordpress.org/support/topic-tag/memory_limit/)

 * In: [Alpha/Beta/RC](https://wordpress.org/support/forum/alphabeta/)
 * 11 replies
 * 4 participants
 * Last reply from: [carbontwelve](https://wordpress.org/support/users/carbontwelve/)
 * Last activity: [15 years, 3 months ago](https://wordpress.org/support/topic/adminphp-tries-to-increase-memory_limit/#post-1522868)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
