- From: <
>
- To:
- Subject: [chef] MySQL cookbook and custom innodb settings
- Date: Wed, 26 Dec 2012 18:50:07 -0800 (PST)
Hi,
I'm using the opscode database and MySQL cookbooks, but I'm running into a
problem when using custom settings for innodb "tunables" such as
:innodb_log_file_size. The mysql cookbook installs the mysql-server package
before generating my.cnf. This is reasonable as some package managers might
not
react well to config files being in place before packages are installed.
Unfortunately, at least on Ubuntu 12.04, the mysql-server package starts the
mysql service as soon as it is installed. This causes binary log files to be
generated with the default configuration parameters. When chef generates my
desired my.cnf and tries to restart the mysql service, it fails because
/var/lib/mysql/ib_logfile0 and /var/lib/mysql/ib_logfile1 already exist and
are
incompatible with the new settings.
This is really only a problem for the first run, but I'd really like to find a
better solution. So far, I have been running chef until it fails, manually
removing the logfiles, restarting mysql, and starting another run. What's a
better way? Is there an idiomatic way to do this with Chef? (I'm new to Chef,
but I have been using Puppet for about a year now).
Any advice would be appreciated.
Thanks!
-Mike
P.S. FWIW, I'm primarily using chef-solo for these projects, so there's no
chef
server available.
- [chef] MySQL cookbook and custom innodb settings, mike.english, 12/26/2012
Archive powered by MHonArc 2.6.16.