Temporary In-Memory MySQL Server

Temporary In-Memory MySQL Server

Second instance of MySQL server in memory:


One time only

Our in-memory server should not expose to network. The only communication should be socket. Therefore skip-networking.

Prepare mysqld_multi for work, but mysqld_multi was not polished enough, so I went for solution to write my init script.


To trick unit-tests into using my new MySQL server:

echo "pdo_mysql.default_socket=/tmp/mysql_temp.sock" >/etc/php5/fpm/conf.d/99-mysql_unittest_temp.ini



rm -f /etc/php5/fpm/conf.d/99-mysql_unittest_temp.ini
date 16. Mar 2013 | modified 29. Dec 2023
filename: MySQL » Temporary In-Memory Instance