Description:
mysqld --help and mysqld --help --verbose fail in multiple conditions:
- ran by root user and --user not specified
- log-bin specified and directory unreachable or file cannot be created (permission denied, not existing, etc)
How to repeat:
run mysqld --help:
flute:~ midom$ mysqld --help
070514 18:07:28 [Warning] Can't create test file /usr/local/mysql-max-5.1-bk-20060217/var/flute.lower-test
070514 18:07:28 [Warning] Can't create test file /usr/local/mysql-max-5.1-bk-20060217/var/flute.lower-test
mysqld: Can't change dir to '/usr/local/mysql-max-5.1-bk-20060217/var/' (Errcode: 13)
070514 18:07:28 [Warning] No argument was provided to --log-bin, and --log-bin-index was not used; so replication may break when this MySQL server acts as a master and has his hostname changed!! Please use '--log-bin=/usr/local/mysql-max-5.1-bk-20060217/var/flute-bin' to avoid this problem.
mysqld: File '/usr/local/mysql-max-5.1-bk-20060217/var/flute-bin.index' not found (Errcode: 13)
070514 18:07:28 [ERROR] Aborting
070514 18:07:28 [Note] mysqld: Shutdown complete
Suggested fix:
..