MySQL and "my.cnf" file(s)

General discussion on Zend Server for IBM System i
Post Reply
hyahagi
Posts: 3
Joined: Mon Jun 21, 2010 7:24 am

MySQL and "my.cnf" file(s)

Post by hyahagi » Mon Jun 21, 2010 7:59 am

Hello,

I'm using IBM i 7.1 and have installed ZendServer-5.0.1-PHP5.3-IBM-i-Windows-Installation.zip.
I also installed MySQL which is bundled with the ZendServer.

I encountered the same problem as described at viewtopic.php?f=77&t=6719. I created new job description based on old one which came with ZendCore to circumvent the problem. But when I start ZMYSQL subsystem, directives in "my.cnf" seem like ignored.

To configure an application, I need to edit "my.cnf". As far as I've found, there are four "my.cnf" files at "/etc", "/tmp/ZendCoreMySql", "/usr/local/mysql/bin", "/usr/local/mysql-5.1.43-i5os-power-64bit/bin".

Which "my.cnf" file will MySQL use?

FYI. if I start MySQL from QP2TERM by running /usr/local/mysql/bin/mysqld_safe script, MYSQL uses directives in /etc/my.cnf. But I don't want to run MYSQL in interactive subsystem.

Thank you for your help in advance.

H.Yahagi.

hyahagi
Posts: 3
Joined: Mon Jun 21, 2010 7:24 am

Re: MySQL and "my.cnf" file(s)

Post by hyahagi » Tue Jun 29, 2010 2:21 am

Hello,

We solved the problem.
Some tweaks are required which I didn't notice or are not documented.

- STRSBS ZMYSQL/ZMYSQL invokes "/usr/local/mysql/bin/mysql.sh", not "/usr/local/mysql/bin/mysqld_safe".
- /usr/local/mysql/bin/mysql.sh sees only "/usr/local/mysql/bin/my.cnf", "/etc/my.cnf" has no effect.
- It is necessary to remove public write authority from "/usr/local/mysql/bin/my.cnf".

Zend is reviewing this issue and may update this topic.

hyahagi

zend_i5
Posts: 158
Joined: Mon Mar 23, 2009 5:22 pm

Re: MySQL and "my.cnf" file(s)

Post by zend_i5 » Sun Jul 04, 2010 2:09 pm

Thank you for you feedback. MySql provided by Zend Server installation is using my.cnf in /usr/local/mysql/bin directory.
Why did you have to remove public authorization from my.cnf file?

hyahagi
Posts: 3
Joined: Mon Jun 21, 2010 7:24 am

Re: MySQL and "my.cnf" file(s)

Post by hyahagi » Tue Jul 06, 2010 12:58 am

Hi,

> Why did you have to remove public authorization from my.cnf file?

See http://dev.mysql.com/doc/refman/5.1/en/ ... files.html. It states that,

Note
On Unix platforms, MySQL ignores configuration files that are world-writable. This is intentional as a security measure.

hyahagi.

Post Reply