I want to set the max_allowed_packet
setting for mysql (5.1.31
) which is running on Solaris 10.
Unfortunately mysql does not seem to read the my.cfg
. I tried to place it in /etc/mycfg
, /opt/mysql/mysql/data/my.cfg
and in /opt/mysql/mysql/support-files/my.cfg
.
At each of these locations, the max_allowed_packet
does not get set when i check with:
`select @@max_allowed_packet;`
When I start mysqld as such it does set the setting:
# su mysql
$ mysqld --defaults-file=/etc/my.cfg
This are the contents of my.cfg:
[mysqld]
max_allowed_packet = 50M
How can i make mysql read the config when i start it with the SMF tools?
OpenCSW provides MySQL-5.0 for Solaris, and the my.cnf file is in /etc/opt/csw/mysql5/my.cnf.
Are you having trouble setting the max_allowed_packet for the client or the server process? Ideally, they should match and setting it in one place and not the other can have interesting side effects.
The exact location of the file would depend on which distribution of mysql you are running (SUN, Solaris freeware, MySQL, Home Grown, etc).
Also, I'm assuming that you're restarting the mysql daemon between changes to the configuration file and that you've got SMF figured out.