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

Install a version of mysql-client that is compatible with mysql-server 5.6 #4680

Merged
merged 1 commit into from
Oct 3, 2019

Conversation

jfly
Copy link
Contributor

@jfly jfly commented Oct 3, 2019

Without this change, chef crashes when trying to apt-get install mysql-server-5.6. Here's a simulation of what happened using docker:

$ docker run -it ubuntu:14.04
root@9a93cac5210c:/# apt-get update
root@9a93cac5210c:/# apt-get install mysql-client
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  libdbd-mysql-perl libdbi-perl libmysqlclient18 libterm-readkey-perl
  mysql-client-5.5 mysql-client-core-5.5 mysql-common
Suggested packages:
  libclone-perl libmldbm-perl libnet-daemon-perl libplrpc-perl
  libsql-statement-perl
The following NEW packages will be installed:
  libdbd-mysql-perl libdbi-perl libmysqlclient18 libterm-readkey-perl
  mysql-client mysql-client-5.5 mysql-client-core-5.5 mysql-common
0 upgraded, 8 newly installed, 0 to remove and 1 not upgraded.
Need to get 3781 kB of archives.
After this operation, 43.8 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
...
root@9a93cac5210c:/# apt-get install mysql-server-5.6
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 mysql-server-5.6 : Depends: mysql-client-5.6 (>= 5.6.33-0ubuntu0.14.04.1) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

We didn't run into this problem previously because we didn't actually
explicitly install mysql-client for our staging server, instead it
would get installed as a transitive dependency of mysql-server-5.6. It
feels better to me to explicitly mention the version of mysql-client we
use, so I've gone ahead and done that here.

…r 5.6

Without this change, chef crashes when trying to `apt-get install mysql-server-5.6`. Here's a simulation of what happened using docker:

    $ docker run -it ubuntu:14.04
    root@9a93cac5210c:/# apt-get update
    root@9a93cac5210c:/# apt-get install mysql-client
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    The following extra packages will be installed:
      libdbd-mysql-perl libdbi-perl libmysqlclient18 libterm-readkey-perl
      mysql-client-5.5 mysql-client-core-5.5 mysql-common
    Suggested packages:
      libclone-perl libmldbm-perl libnet-daemon-perl libplrpc-perl
      libsql-statement-perl
    The following NEW packages will be installed:
      libdbd-mysql-perl libdbi-perl libmysqlclient18 libterm-readkey-perl
      mysql-client mysql-client-5.5 mysql-client-core-5.5 mysql-common
    0 upgraded, 8 newly installed, 0 to remove and 1 not upgraded.
    Need to get 3781 kB of archives.
    After this operation, 43.8 MB of additional disk space will be used.
    Do you want to continue? [Y/n] y
    ...
    root@9a93cac5210c:/# apt-get install mysql-server-5.6
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    Some packages could not be installed. This may mean that you have
    requested an impossible situation or if you are using the unstable
    distribution that some required packages have not yet been created
    or been moved out of Incoming.
    The following information may help to resolve the situation:

    The following packages have unmet dependencies:
     mysql-server-5.6 : Depends: mysql-client-5.6 (>= 5.6.33-0ubuntu0.14.04.1) but it is not going to be installed
    E: Unable to correct problems, you have held broken packages.

We didn't run into this problem previously because we didn't actually
explicitly install `mysql-client` for our staging server, instead it
would get installed as a transitive dependency of `mysql-server-5.6`. It
feels better to me to explicitly mention the version of mysql-client we
use, so I've gone ahead and done that here.
Copy link
Member

@jonatanklosko jonatanklosko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@jfly jfly merged commit 5fb2360 into thewca:master Oct 3, 2019
@jfly jfly deleted the separate-secrets-for-staging branch October 3, 2019 16:59
@jfly
Copy link
Contributor Author

jfly commented Oct 3, 2019

I'm spinning up a staging server now!

@jfly
Copy link
Contributor Author

jfly commented Oct 3, 2019

New staging server successfully deployed!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants