This forum is no longer active. Please post your questions to our new community site

modifications required for running mysql tests

Subscribe to modifications required for running mysql tests 2 post(s), 2 voice(s)

 
Avatar jean 10 post(s)

Folks

Sharing with you the following troubles :

playing with the rubystack 1.0 to run the mysql.org non regression tests (shipped under <installdir>/mysql/mysql-test

tests execution can not proceed :

mysql-test-run script is running the mysql binaries with option—no-defaults which is not compatible with the binaries delivered into the rubystack 1.0 <installdir>/mysql/bin
indeed these binaries are redirecting to a wrapper shell that launches the mysql binary .bin with option—defaults-file with config file
=> as tests run mysql binaries with no default and mysql binaries are called with default option that fails
=> to have tests executed, solution is to link the mysql binaries to their .bin directly without any option
=> this workaround is applicable when want to run the mysql tests : meaning outside testing the conf file used through wrapper needs to be kept
cd /opt/rubystack-1.0/mysql/mysql-test

more mysql-test-run
...
sub collect_mysqld_features () { my $found_variable_list_start= 0;

#
  1. Execute “mysqld—no-defaults—help—verbose” to get a
  2. list of all features and settings # my $list= `$exe_mysqld—no-defaults—verbose—help`;
    ...

cd /opt/rubystack-1.0/mysql/bin

./mysqld -no-defaults—help—verbose
./mysqld.bin: unknown option ‘
-no-defaults’

ls -alt mysqld
lrwxrwxrwx 1 root root 7 Jan 21 18:39 mysqld -> wrapper

more wrapper #!/bin/sh
exec $0.bin—defaults-file=/opt/rubystack-1.0/mysql/my.cnf ”$@”

workaround to apply : THIS HAS TO BE DONE FOR ALL *.bin files under /opt/rubystack-1.0/mysql/bin

  1. /bin/rm -rf mysqld
  2. ln -s mysqld.bin mysqld
  3. ls -alt mysqld
    lrwxrwxrwx 1 root root 9 Jan 23 14:42 mysqld -> mysqld.bin

./mysqld—no-defaults—verbose—help
./mysqld Ver 5.0.45 for pc-linux-gnu on i686 (MySQL Community Server (GPL))
Copyright© 2000 MySQL AB, by Monty and others
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL license
...

rgds,
Jean

 
Avatar Daniel Lopez Administrator 140 post(s)

Correct, thank you for sharing a way of working around the wrappers. Unfortunately, the wrappers are required however for the stacks to be fully relocatable/self contained (for example so they can find the socket file in non-default locations)