This article provides a patch for the known Magento Commerce 2.2.5 issue related to getting the 503 error on store front, with "Unable to send the cookie. Maximum number of cookies would be exceeded." error message in logs.
Customers get 503 error when navigating the store front. In the
var/log/exception.log file the following error message is written "Unable to send the cookie. Maximum number of cookies would be exceeded."
The issue occurs because Magento default cookies limit is set to 50, and if client's browser hits the limit, Magento throws an exception. The solution provided in the patch increases the cookie limit to 200.
The patch is attached to this article. To download it, scroll down to the end of the article and click the file name, or click the following link:
Compatible Magento versions:
The patch was created for:
- Magento Commerce 2.2.5
The patch is also compatible (but might not solve the issue) with the following Magento versions and editions:
- Magento Commerce, Magento Commerce Cloud
How to apply the patch
We strongly recommend applying and testing the patch on the Integration/Staging environment, before applying it Production. We also recommend to have a recent backup before any manipulations.
How to apply this patch for Magento Commerce Cloud
(replace the patch name with a particular one)
- If you do not have a directory named
m2-hotfixesin the project root, please create one.
- Copy the
MDVA-12304_EE_2.2.5_v1.composer.patchfile(s) to the
Add, commit, and push your code changes:
git add -A && git commit -m "Apply
MDVA-12304_EE_2.2.5_v1patch" && git push origin
How to apply this patch for Magento Commerce
- Upload the patch to your Magento root directory.
- Run the following SSH command:
(If the above command does not work, try using
patch -p1 <
- For the changes to be reflected, refresh the cache in the Admin under System > Cache Management.