HoLmS
HoLmS

Reputation: 41

Puppetlabs MySQL unable to install previous build of MySQL

Using puppet module puppetlabs/mysql we faced with issue when we can’t select to install MySQL build (8.0.19-1ubuntu18.04) different from the Latest or its build number (for today latest is 8.0.20-1ubuntu18.04) Requested packages are present in Official Repo

Repo config:

apt::source { 'mysql':
location => 'http://repo.mysql.com/apt/ubuntu/',
release  => $::lsbdistcodename,
repos    => 'mysql-8.0',

  key    => {
  id     => 'A4A9406876FCBD3C456770C88C718D3B5072E1F5',
  server => 'hkp://keyserver.ubuntu.com:80',
},
include  => {
  src => false,
  deb => true,
},
}
Apt::Source['mysql'] ~> Class['apt::update'] -> Class['::mysql::server']

MySQL declaration manifest:

$root_pw = 'Str0ng$q1P@$$'
class { '::mysql::server':
  package_name            => 'mysql-server',
  package_ensure          => '8.0.18-1ubuntu18.04',
  root_password           => $root_pw,
  remove_default_accounts => false,
  create_root_my_cnf      => true,
}

Error message:

Error: Could not update: Execution of '/usr/bin/apt-get -q -y -o DPkg::Options::=--force-confold --force-yes install mysql-server=8.0.18-1ubuntu18.04' returned 100: Reading package lists...
Building dependency tree...
Reading state information...
W: --force-yes is deprecated, use one of the options starting with --allow instead.
E: Version '8.0.18-1ubuntu18.04' for 'mysql-server' was not found
Error: /Stage[main]/Mysql::Server::Install/Package[mysql-server]/ensure: change from 'purged' to '8.0.18-1ubuntu18.04' failed: Could not update: Execution of '/usr/bin/apt-get -q -y -o DPkg::Options::=--force-confold --force-yes install mysql-server=8.0.18-1ubuntu18.04' returned 100: Reading package lists...
Building dependency tree...
Reading state information...
W: --force-yes is deprecated, use one of the options starting with --allow instead.
E: Version '8.0.18-1ubuntu18.04' for 'mysql-server' was not found

Upvotes: 1

Views: 134

Answers (0)

Related Questions