• Resolved govisola

    (@govisola)


    Dear Support Team,

    I am contacting you regarding an issue I am experiencing with my WordPress site, specifically with the memory limit settings reported by phpinfo() and WooCommerce.

    The phpinfo() report on my website indicates that the memory limit, post max size, and upload max filesize are all correctly set to 256M.

    However, when I check the status report in WooCommerce, it shows that these same settings are set to 1024M:

    • memory_limit: 1024M
    • post_max_size: 1024M
    • upload_max_filesize: 1024M

    I have already contacted IONOS support regarding this discrepancy, but they have not been able to assist me in resolving the issue.

    Steps Taken:

    1. Updated php.ini: I have confirmed that my php.ini file has the following settings:
      • memory_limit = 256M;
      • post_max_size = 256M;
      • safe_mode = off;
      • upload_max_filesize = 256M
    2. Checked .htaccess and wp-config.php: I have ensured there are no overriding settings in my .htaccess file or wp-config.php file.
    3. Cleared Cache: I have cleared all caches, including those managed by W3 Total Cache.
    4. Verified Plugin Interference: I have checked to see if any plugins might override these settings, but the issue persists.

    Could you help me understand why there is a discrepancy between the settings reported by phpinfo() and WooCommerce? Specifically, why does WooCommerce report 1024M when the php.ini and phpinfo() indicate 256M?

    Could you please help me identify the root cause of this issue and suggest any potential solutions to ensure the settings are consistent across my site?

    Thank you in advance for your support.

    Best regards,

    The page I need help with: [log in to see the link]

Viewing 15 replies - 1 through 15 (of 23 total)
  • Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @govisola

    This is indeed an unusual situation. The discrepancy between the settings displayed by phpinfo() and WooCommerce may be due to a server-level configuration that overrides your php.ini settings.

    While you’ve already checked your .htaccess and wp-config.php files, there might be other configuration files that are overriding your settings. For example, it’s possible that your web host could be using a user.ini file or a server-level php.ini file that is superseding your local php.ini settings.

    I would recommend contacting IONOS support again and specifically asking them to check for any server-level configurations or user.ini files that might be overriding your local settings.

    Another thing you could try is to add the following line to your wp-config.php file. This will explicitly set the WordPress memory limit to 256M.

    define('WP_MEMORY_LIMIT', '256M');

    Please try these and let us know if the issue persists. We’re here to help you resolve this as quickly as possible.

    Thread Starter govisola

    (@govisola)

    Hi @shameemreza

    Thank you for your reply. I contacted them and am hoping for their response.

    While waiting, I wanted to ask if downgrading to 256 MB makes sense. I read that having 1 GB could cause security issues and even make the server slower. In fact, in the last few weeks after upgrading to 1 GB, I encountered problems loading the website intermittently during the day. I experienced “500” class errors with this message:

    “Internal Server Error
    The server encountered an internal error or misconfiguration and was unable to complete your request.
    Please contact the server administrator at to inform them of the time this error occurred, and the actions you performed just before this error.
    More information about this error may be available in the server error log.”

    So, I thought to downgrade to 256 MB because IONOS told me at that time that there were no problems with their server.

    Plugin Support ckadenge (woo-hc)

    (@ckadenge)

    Hi there @govisola,

    Thanks again for getting back to us.

    It can be frustrating to experience intermittent website loading issues. The “500” class errors you’re encountering are usually related to server configuration, not necessarily the amount of memory.

    Downgrading from 1 GB to 256 MB might not solve the issue and could potentially affect your website’s performance, especially if it’s resource-intensive. It’s a common misconception that having more memory can cause security issues or slow down the server. In fact, more memory allows your server to handle more simultaneous requests, which usually leads to improved performance.

    If IONOS confirmed there were no server issues, the problem might be within your website’s configuration or the plugins/themes you’re using. I’d recommend checking the server error logs for more details about the “500” errors. This could help identify if a specific plugin or theme is causing the issue.

    I hope this helps.

    Thread Starter govisola

    (@govisola)

    Hi @ckadenge

    thanks for your response. Hmm if you say that downgrading from 1 GB to 256 MB might not solve the issue and could potentially affect my website’s performance, I will ask ionos to leave things as they are at 1GB.

    After that I will check the error logs.

    Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @govisola

    Yes, maintaining 1GB memory is a good decision as it will allow your server to handle more requests efficiently.

    However, checking the error logs is indeed the next best step. It will provide more specific information about the “500” class errors you’re experiencing. This information can help you or your developer identify the root cause of the issue, which could be a specific plugin, theme, or configuration setting.

    If you need further assistance in interpreting the error logs or if you have any more questions, please don’t hesitate to contact your hosting provider.

    I hope this provides some clarity. Please let us know if you have any other questions!

    Thread Starter govisola

    (@govisola)

    Hi @shameemreza

    ok, thank you, that’s very nice of you. I will now try my best to find an easy way to check the server log (I made it in the past but I forgot it) and then I will share with you my questions regarding the interpretation of the errors. It might take days, though.

    Have a great day.

    Thread Starter govisola

    (@govisola)

    Hi @shameemreza

    I have the error logs. Should I upload the text on github and share the link with you?

    I am looking forward to hearing from you.

    Best

    Plugin Support Zubair Zahid (woo-hc)

    (@doublezed2)

    Hello govisola,

    Thank you for your reply.

    Yes, that would be helpful.
    You can can paste the error logs in https://gist.github.com.
    After that, you can paste the Gist link here in your reply.

    Have a great day!

    Best regards.

    Thread Starter govisola

    (@govisola)

    Hello @doublezed2

    here the error logs

    There are errors from last year, I think you can ignore them (last year I had errors but I solved them). You can check the errors of today. It seems that the problem is something related to woocommerce.

    Thank you in advance.

    I am looking forward to hearing from you.

    Best

    Hey, @govisola!

    Thanks for sharing the error logs.

    The error you’re seeing indicates that the woocommerce_rest_api_option_permissions hook has been deprecated since WooCommerce version 6.3.0. This means that this hook is no longer supported and doesn’t have a direct replacement.

    So you need to find out what is using this deprecated hook.

    Do you have any custom code on the website?

    I suggest running a conflict test to see if the issue persists.

    To test, you’ll first want to change the theme on your site to Storefront, then check to see if the issue is still present. If that resolves the issue, you’ll want to get in touch with your theme’s developer and see if they have an update or fix for you.

    If changing the theme doesn’t help, you’ll want to deactivate all plugins except for WooCommerce and take a look. If that fixes the problem, re-enable the other plugins one by one (gradually), checking after each, to see where the issue is coming from.

    — Be sure you have a good backup in place of your full site and database. You can ask your host for backup functionality or you can consider using a service like Jetpack. If something goes wrong, you will be able to restore it.

    — Also, you can consider using a plugin like Health Check & Troubleshooting. This is a plugin developed by the WordPress community and it is helpful to disable plugins without affecting your current site visitors.

    — It is important to consider as well a staging functionality in case you would not like to touch your production site (you can ask your host if they offer this service), or you can use WP Staging for quickly spinning up a new test site.

    You can find more about this in this guide.

    Please let us know about your findings.

    Have a wonderful day!

    Thread Starter govisola

    (@govisola)

    Hi @carolm29

    thank you for your response.

    I asked the AI and it told me to find what is using “woocommerce_rest_api_option_permissions”. I found out that the hook “woocommerce_rest_api_option_permissions” is inside the file “class-wc-payments.php” (inside woocommerce payments > includes) and in “Options.php” (inside woocommerce > src > Admin > API).

    The AI simply told me to go inside those files, and delete the lines “woocommerce_rest_api_option_permissions”

    Can I do like that?

    • This reply was modified 4 months, 1 week ago by govisola.
    Plugin Support omarfpg a11n

    (@omarfpg)

    Hi @govisola,

    I asked the AI and it told me to find what is using “woocommerce_rest_api_option_permissions”. I found out that the hook “woocommerce_rest_api_option_permissions” is inside the file “class-wc-payments.php” (inside woocommerce payments > includes) and in “Options.php” (inside woocommerce > src > Admin > API).

    The team is already aware of this issue: https://github.com/Automattic/woocommerce-payments/issues/7864

    At the time being, we can’t give you an estimate for when the team will look into or fix the issue, as bug reports are prioritized based on a few criteria. Please subscribe to the GitHub issue if you’d like to receive updates.

    The AI simply told me to go inside those files, and delete the lines “woocommerce_rest_api_option_permissions”

    I wouldn’t suggest that, as this may cause the plugin to break its functionality. For the time being you can safely leave it as is (deprecated means it’s outdated and it’ll be removed in the future, however it still works. Our dev team should address this with a replacement, though).

    I hope this helps so far!
    -OP

    Thread Starter govisola

    (@govisola)

    Thank you @omarfpg for your response. Ok, I will leave it as it is and hope that the dev team will remove it anytime soon. I’m happy we know better why it happens and that will be fixed by the team. I see that the issue on GitHub started in 2023.

    Have a nice day.

    Thread Starter govisola

    (@govisola)

    *even though it’s not fun that my website from time to time during the day cannot be loaded for a couple of minutes I wish to solve this problem. However, the method suggested by @carolm29 is too complicated for an issue created by a plugin. I mean he said “you need to find out what is using this deprecated hook.” and I found out: is woocommerce. An @omarfpg replied that is indeed a wooccomerce problem. Are we sure there is nothing else to do except that long method of carol or waiting? And if it is a plugin problem, why I feel like I am one of them to experience the problem? Even in the GitHub topic, there are only 8 participants.

    • This reply was modified 4 months, 1 week ago by govisola.
    Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @govisola

    As my colleague @omarfpg mentioned, the issue lies within the WooPayments plugin itself and our development team is currently aware of it and working towards a solution. It’s not a common issue and it seems to be affecting a limited number of users, which might explain the small number of participants on the GitHub topic.

    The method suggested by @carolm29 is a general troubleshooting step to identify whether the issue is caused by a conflict with another plugin or theme. However, since we have identified that the problem is within WooPayments, this step might not be necessary in your case.

    As for why you might be one of the few experiencing this problem, it could be due to a specific combination of settings or plugins on your site that are not common to all users.

    I understand that waiting for a fix is not ideal, especially when your website experiences downtime. However, we highly recommend not to delete the lines of code related to the deprecated hook as suggested by the AI, as it may lead to other unforeseen issues.

    In the meantime, you may consider setting up a staging site to test any updates before applying them to your live site. This can help to minimize any potential disruptions to your site’s operation.

    I hope this provides some clarity. Please let us know if you have any other questions!

Viewing 15 replies - 1 through 15 (of 23 total)
  • You must be logged in to reply to this topic.