I want to use a socket (mysql) in multiple jails. Using nullfs to mount it in each jail where you want to use it does not work (bug in nullfs?). Using a hardlink (if the jails reside on the same FS) works. I hope this info safes a little bit of time in case someone tries to do the same.

The hostname MySQL sees in such a connection is “localhost”. Maybe this is obvious to one or another, but because jails don’t have a 127.0.0.1 it was not obvious to me.

Add to del.icio.us - Digg this article

2 Responses to “Hint: using sockets across jails”  

  1. 1 Martin

    I use unix2tcp (http://ahriman.bucharest.roedu.net/unix2tcp/) to use sockets in different file systems.
    Using TCP certainly causes overhead, but IMO it is worth it since you can use the different IPs/hostnames for MySQL access control.

  2. 2 netchild

    Hi,

    what’s the benefit of using unix2tcp instead of the MySQL build-in TCP support?

    Bye,
    Alexander.

Leave a Reply