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

feat: mysql_upgrade is not needed when the version greater than 8.0.16 #65835

Closed
wants to merge 1 commit into from

Conversation

ayhanaltunkaynak
Copy link

@github-actions github-actions bot added mysql triage Triage is needed labels May 3, 2024
@github-actions github-actions bot requested a review from javsalgar May 3, 2024 13:13
@carrodher carrodher added verify Execute verification workflow for these changes in-progress labels May 3, 2024
@github-actions github-actions bot removed the triage Triage is needed label May 3, 2024
@github-actions github-actions bot removed the request for review from javsalgar May 3, 2024 13:30
@github-actions github-actions bot requested a review from jotamartos May 3, 2024 13:30
@jotamartos
Copy link
Contributor

Hi @ayhanaltunkaynak,

Thanks for your contribution. I just reviewed the current logic and it looks good to me, it doesn't require changes. It works this way:

if version > 8.x.x OR version > 8.0.x OR version >= 8.0.16
then stop and start MySQL
else start MySQL and run the upgrade command

The condition is true with all versions equal or higher than 8.0.16. The else block is run when using a lower version.

Is there something I'm missing? Did you run into any issue when using the container?

Thanks

@ayhanaltunkaynak
Copy link
Author

Hi @ayhanaltunkaynak,

Thanks for your contribution. I just reviewed the current logic and it looks good to me, it doesn't require changes. It works this way:

if version > 8.x.x OR version > 8.0.x OR version >= 8.0.16
then stop and start MySQL
else start MySQL and run the upgrade command

The condition is true with all versions equal or higher than 8.0.16. The else block is run when using a lower version.

Is there something I'm missing? Did you run into any issue when using the container?

Thanks

When the version is equal to or greater than 8.0.16, the current code stops the MySQL and starts it by the "--upgrade=FORCE" option. To me, it is not true. The if block should be <= 8.0.16. Thanks

@jotamartos
Copy link
Contributor

With your changes, the script will try to use mysql_upgrade in versions higher than 8.0.16 and that's not supported anymore according to the documentation you shared.

Apart from that, the upgrade flag is a valid one when performing an upgrade as you can see here.

I'm going to close this PR as this change will break the upgrade process but please do not hesitate to create a new one updating the upgrade process if required.

@ayhanaltunkaynak
Copy link
Author

A message has been received stating that a server upgrade from '8.0.36' to '8.0.36' has begun. Consequently, MySQL is restarting. While we thought that this code block was the issue, we have discovered that the problem may be something else. We are currently investigating the matter in more detail.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
mysql solved verify Execute verification workflow for these changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants