Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document or maybe change default config for collation and charset in global.ini.php #22721

Open
mikkeschiren opened this issue Oct 28, 2024 · 5 comments
Labels
To Triage An issue awaiting triage by a Matomo core team member

Comments

@mikkeschiren
Copy link
Contributor

As default, Matomo is installed with charset utf8 (which usually means utf8mb3), but the recommended charset is utf8mb4.

For collation, the comment in default config says "Matomo should work correctly without this setting but we recommend to have a collation set" - but as of 5.1.2, this is needed to be set.

Should the default charset be changed to utf8mb4, and collation be set to utf8mb4_unicode_ci? Or maybe just update the comments in global.ini.php ?

@mikkeschiren mikkeschiren added the To Triage An issue awaiting triage by a Matomo core team member label Oct 28, 2024
@mikkeschiren
Copy link
Contributor Author

I do realize that many still run Matomo on a non recommended charset - so it is challenge per se..

@sgiehl
Copy link
Member

sgiehl commented Oct 29, 2024

@mikkeschiren The default in config is utf8, as that should be supported by all supported database versions. During the installation we are trying to look up available charsets and if utf8m4 is available, this value will be set to the local config and used instead of utf8

@mikkeschiren
Copy link
Contributor Author

Yes, but should we update the comments in the global ini file? Because it is not entirly correct now.

@mikkeschiren
Copy link
Contributor Author

Are there really any of the supported databases that doesn't support utf8m4?

@sgiehl
Copy link
Member

sgiehl commented Oct 29, 2024

officially we still support MySQL 5.5, which might not have supported utf8mb4 in the beginning.
But we might drop support for older MySQL releases in the next major version, so we might be able to update the config value then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
To Triage An issue awaiting triage by a Matomo core team member
Projects
None yet
Development

No branches or pull requests

3 participants
@mikkeschiren @sgiehl and others