# Fatal Errors: Allowed memory size of 134217728 bytes exhausted

**URL:** <https://discourse.cakephp.org/t/fatal-errors-allowed-memory-size-of-134217728-bytes-exhausted/3145>\
**Category:** Uncategorized\
**Created:** [September 6, 2017, 3:06pm UTC](https://discourse.cakephp.org/t/fatal-errors-allowed-memory-size-of-134217728-bytes-exhausted/3145 "2017-09-06T15:06:58Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jon](https://avatars.discourse-cdn.com/v4/letter/j/3bc359/32.png) [@jon](https://discourse.cakephp.org/u/jon)\
**Post date:** [September 6, 2017, 3:06pm UTC](https://discourse.cakephp.org/t/fatal-errors-allowed-memory-size-of-134217728-bytes-exhausted/3145/1 "2017-09-06T15:06:58Z")

</div>

Hi,

I am using Cakephp 3.4, and I am having an issue getting past these fatal errors:

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 262144 bytes) in /var/www/html/Sequencer/vendor/cakephp/cakephp/src/ORM/Locator/TableLocator.php on line 238

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 262144 bytes) in /var/www/html/Sequencer/vendor/cakephp/cakephp/src/Error/BaseErrorHandler.php on line 81

These are not the only fatal errors that occur though. If I were to reload the page, other fatal errors appear:

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in /var/www/html/Sequencer/vendor/cakephp/cakephp/src/ORM/Locator/TableLocator.php on line 183

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in /var/www/html/Sequencer/vendor/cakephp/cakephp/src/Utility/Hash.php on line 61

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 262144 bytes) in /var/www/html/Sequencer/vendor/cakephp/cakephp/src/Core/Configure.php on line 126

After isolating each line of code, I found that the issue occurs when I use loadModel(‘Users’); in my controller and when I have the namespace App\Model\Table in the Users Table model.

Can anyone help me with this issue?

---

<div class="post-metadata">

**Author:** ![donnidani](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.cakephp.org/donnidani/32/744_2.png) [@donnidani](https://discourse.cakephp.org/u/donnidani)\
**Post date:** [September 6, 2017, 7:56pm UTC](https://discourse.cakephp.org/t/fatal-errors-allowed-memory-size-of-134217728-bytes-exhausted/3145/2 "2017-09-06T19:56:11Z")

</div>

hope this stackoverflow could help you :

> <https://stackoverflow.com/questions/36999406/allowed-memory-size-of-134217728-bytes-exhausted-tried-to-allocate-42-bytes>
