My idea was to tailor the configuration of my Mysql server by making use of the configuration directory it has and includes (via the !includedir /etc/mysql/conf.d/
directive at the end of /etc/mysql/my.cnf
):
/etc/mysql/conf.d
So I created a configuration file called /etc/mysql/conf.d/innodb.cnf
.
Now when I display the version via $ mysql --version
I see the following error:
error: Found option without preceding group in config file: /etc/mysql/conf.d/innodb.cnf at line: 3
Which is true, that file does not have such a group in the first line. I commented it intentionally out, here the first three lines:
$ head -n 3 /etc/mysql/conf.d/innodb.cnf
# [mysqld]
# my settings
innodb_read_io_threads=4
If I would not comment the group, then using service mysql start
on the command-line would put mysql in an endless start-up loop, it retries as often to start the mysql daemon which must fail then and retries again until I comment out the group again.
So now I'm left in a paradox situation. I could
either: have the file as is (the group commented out) and see the error
or: don't get the error but can't start mysql
Now I'm looking for options on how to deal with this situation.
I'm using Ubuntu 14.04 with the Kubuntu desktop and Mysql 5.5.