jailing MySQL error [SOLVED]
dsc.fbsd.other at gmail.com
Mon Jan 3 13:21:37 UTC 2011
SOLVED ! But the problem was in another place.
Host world and kernel were build with src r215329 (patched with
head-v28-v2.patch from Martin Matuska), but ezjail buildworld was made using
more recent sources with no patch (in fact I was trying to apply the same
patch to more recent sources, but it doesn't work ... but that's another
Mysql seems to have problems in this case (kernel and world based on
different versions of src). But other stuff work just fine.
So, first I've made a jail (standard steps from the handbook) using the same
src r215329 (patched for zfs v28). Mysql works fine under this jail.
After this step, I've updated the ezjail basejail (ezjail-admin update -i).
Now, Mysql works just fine under ezjail too.
Thanks for your time and help.
From: Miroslav Lachman [mailto:000.fbsd at quip.cz]
Sent: Sunday, January 02, 2011 9:32 PM
To: dsc fbsd.other
Cc: freebsd-jail at freebsd.org
Subject: Re: jailing MySQL error
dsc fbsd.other wrote:
> My steps:
> 1. Ezjail-admin onestart j009_mysql2
> 2. Ezjail-admin console j009_mysql2
> 3. Cd /usr/ports/database/mysql55-server&& make install clean
> 4. cp /usr/local/share/mysql/my-innodb-heavy-4G.cnf
> /usr/local/etc/my.cnf (modified socket file path to
> /var/db/mysql/mysql.sock, in both client and server lines)
> 5. chown -R mysql:mysql ... for ... /tmp /var/tmp /var/db/mysql
> 6. mysql_enable="YES" in jail rc.conf
> 7. /usr/local/etc/rc.d/mysql-server start
> 8. ...and NOTHING ... mysql-server scripts starts
> /usr/local/bin/mysql_install_db (creates mysql and test folders in
> /var/db/mysql ... but nothing else ... it's just running)
I am running mysql in a couple of jails without any additional tweaks.
I don't know why you are using chown on /tmp /var/tmp and /var/db/mysql.
Did you created /var/db/mysql manualy?
Can you just try clean install without any tweaks without modifying my.cnf
and just start it by:
mysql_enable="YES" in jail rc.conf
MySQL daemon should run in jail with standard configuration.
More information about the freebsd-jail