Skip Navigation

This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 -
- 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 -

Supporter timezone: Asia/Ho_Chi_Minh (GMT+07:00)

Tagged: 

This topic contains 7 replies, has 3 voices.

Last updated by Long Nguyen 1 year, 9 months ago.

Assisted by: Long Nguyen.

Author Posts
August 11, 2023 at 8:34 am #14186733

lucaM-71

Greetings,

we get a 500 error on:
hidden link
when we switch to English view.
hidden link

Attached are the logs, indicating a fatal error related to running out of PHP memory.

We've already tried increasing all the memory-related values, stretching them massively (wp_memory_limit, etc.).
However, the error persists because more and more memory is being used.

Can you help us?

Thank you.

August 11, 2023 at 8:35 am #14186763

lucaM-71

These are the errors we get:

[10-Aug-2023 08:45:48 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 20480 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/pomo/mo.php on line 285
[10-Aug-2023 08:45:48 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 65536 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-content/plugins/litespeed-cache/src/core.cls.php on line 572
[10-Aug-2023 08:45:48 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 266240 bytes) in Unknown on line 0
[10-Aug-2023 08:48:14 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 20480 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/pomo/mo.php on line 285
[10-Aug-2023 08:48:14 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 266240 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/functions.php on line 5349
[10-Aug-2023 08:48:14 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 249856 bytes) in Unknown on line 0
[10-Aug-2023 08:49:16 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 262144 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-content/plugins/wpml-string-translation/classes/MO/LoadedMODictionary.php on line 42
[10-Aug-2023 08:49:16 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 262144 bytes) in Unknown on line 0
[10-Aug-2023 08:49:16 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 249856 bytes) in Unknown on line 0
[10-Aug-2023 08:53:16 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 262144 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-content/plugins/wpml-string-translation/classes/MO/LoadedMODictionary.php on line 42
[10-Aug-2023 08:53:16 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 262144 bytes) in Unknown on line 0
[10-Aug-2023 08:53:16 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 249856 bytes) in Unknown on line 0
[10-Aug-2023 08:53:28 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 20480 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/pomo/mo.php on line 328
[10-Aug-2023 08:53:28 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 266240 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/functions.php on line 5349
[10-Aug-2023 08:53:28 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 249856 bytes) in Unknown on line 0
[10-Aug-2023 08:54:05 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 20480 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/pomo/translations.php on line 290
[10-Aug-2023 08:54:05 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 229376 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/functions.php on line 5349
[10-Aug-2023 08:54:05 UTC] PHP Fatal error: Unknown: Cannot use output buffering in output buffering display handlers in Unknown on line 0
[10-Aug-2023 08:55:35 UTC] PHP Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'wp_ob_end_flush_all' not found or invalid function name in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/class-wp-hook.php on line 310
[10-Aug-2023 08:55:36 UTC] PHP Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'wp_ob_end_flush_all' not found or invalid function name in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/class-wp-hook.php on line 310
[10-Aug-2023 08:55:37 UTC] PHP Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'wp_ob_end_flush_all' not found or invalid function name in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/class-wp-hook.php on line 310
[10-Aug-2023 08:55:39 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 20480 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/pomo/translations.php on line 288
[10-Aug-2023 08:55:39 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 65536 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/class-wp-fatal-error-handler.php on line 154
[10-Aug-2023 08:55:39 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 249856 bytes) in Unknown on line 0
[10-Aug-2023 08:56:01 UTC] PHP Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'wp_ob_end_flush_all' not found or invalid function name in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/class-wp-hook.php on line 310
[10-Aug-2023 08:56:02 UTC] PHP Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'wp_ob_end_flush_all' not found or invalid function name in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/class-wp-hook.php on line 310
[10-Aug-2023 08:59:05 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 20480 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/pomo/mo.php on line 328
[10-Aug-2023 08:59:05 UTC] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 229376 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/functions.php on line 5349
[10-Aug-2023 08:59:05 UTC] PHP Fatal error: Unknown: Cannot use output buffering in output buffering display handlers in Unknown on line 0
[10-Aug-2023 08:59:28 UTC] PHP Fatal error: Allowed memory size of 1073741824 bytes exhausted (tried to allocate 20480 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/pomo/translations.php on line 288
[10-Aug-2023 08:59:28 UTC] PHP Fatal error: Allowed memory size of 1073741824 bytes exhausted (tried to allocate 65536 bytes) in Unknown on line 0
[10-Aug-2023 08:59:28 UTC] PHP Fatal error: Allowed memory size of 1073741824 bytes exhausted (tried to allocate 249856 bytes) in Unknown on line 0
[10-Aug-2023 08:59:35 UTC] PHP Fatal error: Allowed memory size of 1073741824 bytes exhausted (tried to allocate 262144 bytes) in /home/oufhgtnihv/domains/divashoesfirenze.com/public_html/wp-includes/plugin.php on line 205
[10-Aug-2023 08:59:35 UTC] PHP Fatal error: Allowed memory size of 1073741824 bytes exhausted (tried to allocate 262144 bytes) in Unknown on line 0
[10-Aug-2023 08:59:35 UTC] PHP Fatal error: Allowed memory size of 1073741824 bytes exhausted (tried to allocate 229376 bytes) in Unknown on line 0

August 11, 2023 at 8:36 am #14186765

lucaM-71

We also want to point out that in French the problem does not occur

August 11, 2023 at 9:44 pm #14190895

Mihai Apetrei
WPML Supporter since 03/2018

Languages: English (English )

Timezone: Europe/Bucharest (GMT+03:00)

Hi there.

Before this ticket gets assigned to one of my colleagues, I will try to help.

The "allowed memory exhausted" error is usually related to server/hosting settings so they (the hosting support) might be the only ones who can fix it.

However, there are a good amount of existing tickets related to this exact error with recommendations and solutions from our team.

I created this custom search URL below - can you please take a look at the tickets showing up and see if the solution that worked for the customers works for you, too?

Please let me know how that goes.

- hidden link

PS: Also, please make sure your server environment meets our minimum requirements as described here (this might be already in place, as you mentioned):
https://wpml.org/home/minimum-requirements/

Kind regards,
Mihai Apetrei

August 12, 2023 at 1:43 pm #14191735

lucaM-71

Good evening
the problem exists,
we had already tested what was reported before contacting you.
For the sake of scrupulousness, we also deactivated the installed plugins one at a time, but it didn't resolve it.

The strange thing is that the French translation is fine
instead the English one freezes.

We are sorry to ask for your intervention but we believe that wpml is a good tool but it eats up a lot of resources and makes our site unstable.

If you could verify the origin of the problem, would you give us a solution?

looking forward to your prompt reply
Best regards
Luke Marchi

August 14, 2023 at 7:24 am #14194927

Long Nguyen
WPML Supporter since 02/2022

Languages: English (English )

Timezone: Asia/Ho_Chi_Minh (GMT+07:00)

Hi Luca,

Thank you for contacting WPML support, I'd be happy to help you with this issue.

Please try some troubleshooting steps below and see if it helps:

1. Update WPML plugins to the new version (WPML 4.6.5, String Translation 3.2.7). Refer to the documentation https://wpml.org/faq/install-wpml/#checking-for-updates

2. Go to WPML > String Translation > Disable two options:
- Track where strings appear on the site
- Look for strings while pages are rendered
and click on the button "Remove strings" to remove untranslated strings by domain.

3. Enable a minimal environment as below:
- Disable all plugins except WPML plugins and WooCommerce.
- Switch to a standard theme of WordPress.
❌ IMPORTANT: Please backup your database and website before proceeding ❌
You can use this plugin to create the backup: https://wordpress.org/plugins/duplicator/

Look forward to your reply.
Thanks

August 14, 2023 at 7:58 am #14195423

lucaM-71

Hello,

Upon reviewing the log once again, we have identified the following issue:

PHP Fatal error: Out of memory (allocated 1524641792) (tried to allocate 262144 bytes) in /home/*********/domains/divashoesfirenze.com/public_html/wp-content/plugins/sitepress-multilingual-cms/sitepress.class.php on line 3452

To address this problem, we have temporarily resolved it by commenting out line 3452 in the sitepress.class.php file located within the /sitepress-multilingual-cms/ directory. Here's the updated code snippet:

/**
* @return WPML_Locale
*/
public function get_wpml_locale() {
return $this->locale_utils;
}

function locale_filter( $default ) {

if ( ! $this->get_settings() ) {
return $default;
}

//return $this->locale_utils->locale(); <-- line 3452 (commented out)
}

However, in order to prevent potential issues in future updates, we would appreciate clarification on the purpose of this function and whether it's possible to disable the associated option within the plugin settings.

Thank you for your assistance.

August 14, 2023 at 9:20 am #14196209

Long Nguyen
WPML Supporter since 02/2022

Languages: English (English )

Timezone: Asia/Ho_Chi_Minh (GMT+07:00)

Hi,

I think there could be a specific issue on your site. Please try to copy your live site to a staging site, un-comment the code and check the issue there. If it persists, I would like to request temporary access (wp-admin and FTP) to your staging site to take a better look at the issue. Your next reply is set to private to share the info.

❌ IMPORTANT: Please backup your database and website before proceeding ❌
You can use this plugin to create the backup: https://wordpress.org/plugins/duplicator/
✙ I would need your permission to de-activate and re-activate Plugins and the Theme to change configurations on the site if needed. This is also a reason the backup is critical.

Look forward to your reply.
Thanks

The topic ‘[Closed] fatal error related to running out of PHP memory’ is closed to new replies.