No Code Attached Yet
avatar bellu
bellu
31 May 2023

Steps to reproduce the issue

Create a new article and save it.

Expected result

A new article in the CMS.

Actual result

Save failed with the following error: Storage engine MEMORY is disabled (Table creation is disallowed).
My website on Google Cloud raises this error every time, that i try to save an article in the backend.

I found that the Indexer is trying to use a table with engine MEMORY, but on Google Cloud this kind of engine is not allowed.

administrator/components/com_finder/src/Indexer/Indexer.php

990: $db->setQuery('ALTER TABLE ' . $db->quoteName('#__finder_tokens') . ' ENGINE = MEMORY');
994: $db->setQuery('ALTER TABLE ' . $db->quoteName('#__finder_tokens_aggregate') . ' ENGINE = MEMORY');

administrator/components/com_finder/sql/install.mysql.sql

360: ENGINE=MEMORY DEFAULT CHARSET=utf8mb4 DEFAULT COLLATE=utf8mb4_unicode_ci;
379: ENGINE=MEMORY DEFAULT CHARSET=utf8mb4 DEFAULT COLLATE=utf8mb4_unicode_ci;

System information (as much as possible)

Joomla 4.3.2
Hosting Google Cloud

Additional comments

I think should be provided a fallback, like InnoDB engine, in case that the memory engine is not allowed.

avatar bellu bellu - open - 31 May 2023
avatar joomla-cms-bot joomla-cms-bot - change - 31 May 2023
Labels Added: No Code Attached Yet
avatar joomla-cms-bot joomla-cms-bot - labeled - 31 May 2023
avatar bellu bellu - change - 31 May 2023
Title
Joomla 4.3.3 - Storage Engine memory disabled issue
Joomla 4.3.2 - Storage Engine memory disabled issue
avatar bellu bellu - edited - 31 May 2023
avatar richard67
richard67 - comment - 1 Jun 2023

@bellu Thanks for reporting this issue. Unfortunately this is a known issue with certain kinds of replicated DB clusters, see issue #40368 .

With Joomla 4.3.2 a fix has been released which prevents the indexer from crashing in this case, see PR #40373 . This works when the database is created and Joomla was installed on a not replicated database and later replication is added or if the database later is transferred to a replicated cluster.

But if you want to run the Joomla installation already on the cluster, this is not enough. You have to change the "installation/sql/mysql/extensions.sql" file here https://github.com/joomla/joomla-cms/blob/4.3-dev/installation/sql/mysql/extensions.sql#L607 and here https://github.com/joomla/joomla-cms/blob/4.3-dev/installation/sql/mysql/extensions.sql#L628 by replacing the ENGINE=MEMORY by ENGINE=InnoDB. Then the installation should succeed and the indexer should work.

The administrator/components/com_finder/sql/install.mysql.sqlis not really relevant, it would only be used when com_finder is not installed so it would have been discovered with a discovery installation, which never can happen on Joomla 4.

We have to live with this workaround until we can in a future version (maybe 5 or 6) can change the engine to InnoDB for new installations. Doing it within a minor or patch release could be considered as a backwards compatibility (b/c) break.

Please report back if that workaround works for you so we can close this issue. Thanks in advance.

avatar richard67 richard67 - change - 1 Jun 2023
Labels Added: Information Required
avatar richard67 richard67 - labeled - 1 Jun 2023
avatar brianteeman brianteeman - change - 12 Aug 2023
Status New Closed
Closed_Date 0000-00-00 00:00:00 2023-08-12 21:52:19
Closed_By brianteeman
avatar brianteeman brianteeman - close - 12 Aug 2023
avatar brianteeman
brianteeman - comment - 12 Aug 2023

Closing as the reported issue was answered and the op did not reply

avatar brianteeman brianteeman - change - 12 Aug 2023
Labels Removed: Information Required
avatar brianteeman brianteeman - unlabeled - 12 Aug 2023

Add a Comment

Login with GitHub to post a comment