[chef] Re: MySQL-cookbook: Instance restart at every chef-client run


Chronological Thread 
  • From: Yoshi Spendiff < >
  • To: chef < >
  • Subject: [chef] Re: MySQL-cookbook: Instance restart at every chef-client run
  • Date: Thu, 27 Aug 2015 12:31:43 -0700

The :create action calls create_stop_system_service which stops the service
https://github.com/chef-cookbooks/mysql/blob/v6.1.0/libraries/provider_mysql_service_sysvinit.rb

The guard that was on that service action was removed with the 6.0.31 release
https://github.com/chef-cookbooks/mysql/commit/a6f1eb25db4f158406ef01d6a948771dd6313eec

You might want to try 6.0.30 for now which contains the guard on the create action (set a version lock in metadata.rb like depends 'mysql', '6.0.30')
https://github.com/chef-cookbooks/mysql/blob/v6.0.30/libraries/provider_mysql_service_sysvinit.rb

Either that or put together a combination of guards and notifications to do the checking yourself, but that's pretty hacky. Probably better to lock to a version that works for now and raise an issue for that cookbook here: https://github.com/chef-cookbooks/mysql/issues

On Thu, Aug 27, 2015 at 7:20 AM, Tobias Unsleber < " target="_blank"> > wrote:
Hi,

I'm using the mysql-cookbook(Version 6.1)
to install mysql-servers:

with this statement in the recipe:

mysql_service 'default' do
  bind_address node["mysql"]["bind-address"]
  initial_root_password "mysql_root_password"
  action [:create, :start]
end

The effect is, that the instance mysql-default is restarted
at every chef run, which is very bad for me. (Chef version 12)

This is the output of chef-client:

http://fpaste.org/260111/85053144/

Is this the intended behaviour, or did I
just use it in a wrong way?

--
Tobias Unsleber
INLINE  Internet Online Dienste GmbH
Kaiserstr. 80
76133 Karlsruhe

Tel +49 721 9668245, FAX +49 721 9668211

HRB 107453, Sitz Karlsruhe, Registergericht: Mannheim
Geschäftsführer: Dr. Andreas Werner, Dr. Armin Zundel



--
Yoshi Spendiff
Ops Engineer
Indochino
Mobile: +1 778 952 2025



Archive powered by MHonArc 2.6.16.

§