28 April 2009

check your my.cnf with "mysqld --help --verbose"

On the Drizzle-discuss mailing list, Baron just pointed out that MySQL has a means to validate its config file (/etc/my.cnf), similar to "apachectl configtest".

mysqld --help --verbose

Somehow, I never knew that...

Oh, and yes, this means I am following Drizzle. In fact, I'm trying to devote at least a few hours each day to reading the source and finding things to fix. In a weird way, it feels good to be writing C++ again!

7 comments:

Swany said...

I have found this very useful in the past to determine what path mysqld was searching through to find my.cnf:

mysqld --help --verbose|grep cnf

:)

Arjen Lentz said...

Yep the OurDelta builds has that (since 5.0.77-d8) as an option in the startup script, so you can do /etc/init.d/mysqld configtest
Peter Lieverdink put the patch in some months back.

Shlomi N. said...

Hi,

Have just posted a related post on this yesterday. Apparently, and sadly, mysqld --verbose --help and SHOW GLOBAL STATUS do not agree on naming and values conventions.
See: Variables ambiguities in names and values

Anonymous said...

And "mysqladmin variables" will show you exactly which configuration your mysql is running with.

Marc Richter said...

At least in Ubuntu (MySQL version 5.0.51a) this don't work. I entered the line "stupid_value=true" into the my.cnf and issued "mysqld --help --verbose". It doesn't tell anything about an non-existing option.

Alex said...

my sql projects and my sql online live interactive training at http://bit.ly/wXKHod

Todaydownload.com said...

These facts are really interesting. Few of them were well known for me but many of them were brand new for me too!
I will print this one out and show to my friends because they will be definitely interested in that. Thanks!
MySQL