环境:
Vagrant(VirtualBox)
Ubuntu 14
-Puppetlabs-mysql(https://github.com/puppetlabs/puppetlabs-mysql)
问题:
使用puppetlabs-mysql(版本3.6.1)我正在尝试安装mySQL 5.6.23,但它似乎是安装5.5.4。
我尝试设置属性'确保'至' 5.6'但它给了我这个错误:
Error: Could not update: Execution of '/usr/bin/apt-get -q -y -o DPkg::Options::=--force-confold --force-yes install mysql-server=5.6' returned 100: Reading package lists...
==> default: Building dependency tree...
==> default: Reading state information...
==> default: E: Version '5.6' for 'mysql-server' was not found
==> default:
==> default: Error: /Stage[main]/Mysql::Server::Install/Package[mysql-server]/ensure: change from purged to 5.6 failed: Could not update: Execution of '/usr/bin/apt-get -q -y -o DPkg::Options::=--force-confold --force-yes install mysql-server=5.6' returned 100: Reading package lists...
==> default: Building dependency tree...
==> default: Reading state information...
==> default: E: Version '5.6' for 'mysql-server' was not found
==> default:
如何安装5.6.23?
答案 0 :(得分:4)
而不是ensure
,请使用package_name
。这对我有用:
class { '::mysql::server':
package_name => 'mysql-server-5.6'
}
如果正在安装mysql-client
的版本不正确,请同时添加:
class { '::mysql::client':
package_name => 'mysql-client-5.6'
}