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

When checking for correct Unicode, minimum MySQL version is incorrect #2509

Closed
ddb4github opened this issue Mar 13, 2019 · 7 comments
Closed
Labels
bug Undesired behaviour resolved A fixed issue
Milestone

Comments

@ddb4github
Copy link
Contributor

  1. Under: install/install.php?data={"Step":"2","Eula":true}
    Recommended value are 'utf8_general_ci' and 'utf8'
    image

  2. Under: install/install.php?data={"Step":"8","Eula":true}
    Recommended(Warning Required) are changed to 'utf8mb4_unicode_ci' and 'utf8mb4'
    image

@ddb4github
Copy link
Contributor Author

After change to:
[mysqld]
character_set_server = utf8mb4
collation_server = utf8mb4_unicode_ci

Step#2 still show "recommended" with 'utf8_general_ci', and final step warning is removed:
image

image

@cigamit
Copy link
Member

cigamit commented Mar 13, 2019

This is a good point. In general, utf8 is fine for most localities except China which some forms require the utf8mb4. You might want to consider utf8mb4 as it only add one additional character. The 'mb4' is a bit misleading. However, we could do better on the language here as it's not catastrophic with that rare occasion of the very few languages that break the utf8 barrier.

@netniV
Copy link
Member

netniV commented Mar 13, 2019

There was a reason we switched over to mb4 rather than just plain utf8 and I agree as I think it was for those extended Unicode characters that are 4-byte in length (such as china already mentioned). It was also to be more consistent on some of the SQL statements because there were issues (see #1034 and #1707)

Now, the reason you are seeing utf8 and not utf8mb4 in the recommendations list is I think because of your MySQL version being less than 5.6. Unfortunately, the text at the top of the page has (currently) no variation based on the version of MySQL so assumes the default value of utf8mb4_unicode_Ci.

There is also a reason for using the unicode over general too and that was to do with properly sorting text fields if I remember rightly. The problem is, it was a year ago we decided to implement that change for 1.2 and I can't totally recall all the reasons, only that it was the minimum to make things work for everyone.

@netniV
Copy link
Member

netniV commented Mar 13, 2019

It was also because we had some strange errors reported where SQL statements would fail for no apparently reason and it ended up being down to the collation and a mismatch between what was being used by Cacti and plugins.

@cigamit
Copy link
Member

cigamit commented Mar 15, 2019

That's odd, it appears that maybe utf8mb4 is supported in MariaDB5.5. We should mark that as a bug.

@cigamit cigamit added the bug Undesired behaviour label Mar 15, 2019
@cigamit cigamit added this to the v1.2.3 milestone Mar 15, 2019
@netniV
Copy link
Member

netniV commented Mar 15, 2019

It was only from 5.5.3 that utf8mb4 was first introduced I think. So, we should probably be more specific on the version checks. We should probably raise the minimum MySQL level to match that.

cigamit added a commit that referenced this issue Mar 16, 2019
Installer is not consistent between MySQL Settings checking and final step Warning
@cigamit cigamit added the resolved A fixed issue label Mar 16, 2019
@cigamit
Copy link
Member

cigamit commented Mar 16, 2019

Resolved. STRONGLY recommending 5.5.3+

@cigamit cigamit closed this as completed Mar 16, 2019
@netniV netniV changed the title Installer is not consistent between MySQL Settings checking and final step Warning When checking for correct Unicode, minimum MySQL version is incorrect Mar 30, 2019
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Undesired behaviour resolved A fixed issue
Projects
None yet
Development

No branches or pull requests

3 participants