The reason for the bug is that mysqtest as well as other client tools
running in test suite (mysqlbinlog, mysqldump) will first try to connect
whatever database has created shared memory with default base name
"MySQL" and use this. (Same effect could be seen on Unix if mtr would
not care to calculate "port" and "socket" parameter).
The fix ensures that all client tools and running in mtr use unique
per-database shared memory base parameters, so there is no possibility
to clash with already installed one. We use socket name for shared memory
base (it's known to be unique). This shared-memory-base is written to the
MTR config file to the [client] and [mysqld] sections. Fix made also made
sure all client tools understand and correctly handle --shared-memory-base.
Prior to this patch it was not the case for mysqltest, mysqlbinlog and
mysql_client_test.
All new connections done from mtr scripts via connect() will by default
set shared-memory-base. And finally, there is a possibility to force
shared memory or pipe connection and overwrite shared memory/pipe base name
from within mtr scripts via optional PIPE or SHM modifier. This functionality
was manually backported from 6.0
(original patch http://lists.mysql.com/commits/74749)
Improve test for shm on windows
mysql-test/include/windows.inc:
improve "skip message" and don't require a result file
mysql-test/r/shm.result:
Update result after adding more tests
mysql-test/t/shm-master.opt:
Add $MTR_BUILD_THREAD to get a unique shared memory base name
mysql-test/t/shm.test:
Run a bunch of more test to check shm
mysql-test/r/named_pipe.result:
New BitKeeper file ``mysql-test/r/named_pipe.result''
mysql-test/t/named_pipe-master.opt:
New BitKeeper file ``mysql-test/t/named_pipe-master.opt''
mysql-test/t/named_pipe.test:
New BitKeeper file ``mysql-test/t/named_pipe.test''