Bug #50940 mtr doesn't work with cygwin 1.7
Submitted: 5 Feb 2010 11:11 Modified: 3 Mar 2010 9:23
Reporter: Georgi Kodinov Email Updates:
Status: Can't repeat Impact on me:
None 
Category:Tools: MTR / mysql-test-run Severity:S7 (Test Cases)
Version:5.1, 6.0-codebase OS:Microsoft Windows (Windows XP, cygwin 1.7)
Assigned to: Bjørn Munch CPU Architecture:Any

[5 Feb 2010 11:11] Georgi Kodinov
Description:
mtr doesn't work with the current cygwin (1.7).
Here's what I get on failing tests : 
$ perl mysql-test-run.pl suite/rpl/t/rpl_trigger.test
Logging: mysql-test-run.pl  suite/rpl/t/rpl_trigger.test
MySQL Version 5.1.45
Checking supported features...
 - skipping ndbcluster, mysqld not compiled with ndbcluster
 - SSL connections supported
 - binaries are debug compiled
Collecting tests...
 - adding combinations for rpl
vardir: Z:/test-compile-win-5.1-bugteam/mysql-test/var
Checking leftover processes...
Removing old var directory...
Creating var directory 'Z:/test-compile-win-5.1-bugteam/mysql-test/var'...
Installing system database...
Using server port 1181

==============================================================================

TEST                                      RESULT   TIME (ms)
------------------------------------------------------------

worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 13000..13009
rpl.rpl_trigger                          [ skipped ]  No innodb support
cygpath: unknown option -- y
Usage: cygpath (-d|-m|-u|-w|-t TYPE) [-f FILE] [OPTION]... NAME...
       cygpath [-c HANDLE]
       cygpath [-ADHOPSW]
       cygpath [-F ID]
Convert Unix and Windows format paths, or output system path information

Output type options:
  -d, --dos             print DOS (short) form of NAMEs (C:\PROGRA~1\)
  -m, --mixed           like --windows, but with regular slashes (C:/WINNT)
  -M, --mode            report on mode of file (binmode or textmode)
  -u, --unix            (default) print Unix form of NAMEs (/cygdrive/c/winnt)
  -w, --windows         print Windows form of NAMEs (C:\WINNT)
  -t, --type TYPE       print TYPE form: 'dos', 'mixed', 'unix', or 'windows'
Path conversion options:
  -a, --absolute        output absolute path
  -l, --long-name       print Windows long form of NAMEs (with -w, -m only)
  -p, --path            NAME is a PATH list (i.e., '/bin:/usr/bin')
  -s, --short-name      print DOS (short) form of NAMEs (with -w, -m only)
  -C, --codepage CP     print DOS, Windows, or mixed pathname in Windows
                        codepage CP.  CP can be a numeric codepage identifier,
                        or one of the reserved words ANSI, OEM, or UTF8.
                        If this option is missing, cygpath defaults to the
                        character set defined by the current locale.
System information:
  -A, --allusers        use `All Users' instead of current user for -D, -O, -P
  -D, --desktop         output `Desktop' directory and exit
  -H, --homeroot        output `Profiles' directory (home root) and exit
  -O, --mydocs          output `My Documents' directory and exit
  -P, --smprograms      output Start Menu `Programs' directory and exit
  -S, --sysdir          output system directory and exit
  -W, --windir          output `Windows' directory and exit
  -F, --folder ID       output special folder with numeric ID and exit
Try `cygpath --help' for more information.
Failed to run: 'cygpath -m Z:/test-compile-win-5.1-bugteam/mysql-test/var/tmp/an
-mysqld.1.err', master
cygpath: unknown option -- y
Usage: cygpath (-d|-m|-u|-w|-t TYPE) [-f FILE] [OPTION]... NAME...

How to repeat:
run a failing test on a debug version of MySQL

Suggested fix:
don't use cygpath -y
[5 Feb 2010 12:05] MySQL Verification Team
I got different behavior on Vista X64:

miguel@tikal /cygdrive/c/build/5.1/mysql-test
$ perl mysql-test-run.pl suite/rpl/t/rpl_trigger.test
cygwin warning:
  MS-DOS style path detected: C:\ProgramData
  Preferred POSIX equivalent is: /cygdrive/c/ProgramData
  CYGWIN environment variable option "nodosfilewarning" turns off this warning.
  Consult the user's guide for more details about POSIX paths:
    http://cygwin.com/cygwin-ug-net/using.html#using-pathnames
Logging: mysql-test-run.pl  suite/rpl/t/rpl_trigger.test
100205  9:59:27 [Note] Plugin 'FEDERATED' is disabled.
MySQL Version 5.1.44
Checking supported features...
 - skipping ndbcluster, mysqld not compiled with ndbcluster
 - SSL connections supported
Collecting tests...
 - adding combinations for rpl
vardir: C:/build/5.1/mysql-test/var
Checking leftover processes...
Removing old var directory...
Creating var directory 'C:/build/5.1/mysql-test/var'...
Installing system database...
Using server port 49703

==============================================================================

TEST                                      RESULT   TIME (ms)
------------------------------------------------------------

worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 13000..13009
rpl.rpl_trigger 'row'                    [ skipped ]  Doesn't support --binlog-f
ormat='row'
rpl.rpl_trigger 'row+innodb_plugin'      [ skipped ]  Doesn't support --binlog-f
ormat='row'
rpl.rpl_trigger 'stmt'                   [ pass ]  29252
can't redirect STDERR to '//./NUL': No such file or directory at mysql-test-run.
pl line 4136
can't redirect STDERR to '//./NUL': No such file or directory at mysql-test-run.
pl line 4136
rpl.rpl_trigger 'mix'                    [ pass ]  28712
can't redirect STDERR to '//./NUL': No such file or directory at mysql-test-run.
pl line 4136
can't redirect STDERR to '//./NUL': No such file or directory at mysql-test-run.
pl line 4136
rpl.rpl_trigger 'stmt+innodb_plugin'     [ pass ]  27126
can't redirect STDERR to '//./NUL': No such file or directory at mysql-test-run.
pl line 4136
can't redirect STDERR to '//./NUL': No such file or directory at mysql-test-run.
pl line 4136
rpl.rpl_trigger 'mix+innodb_plugin'      [ pass ]  28973
can't redirect STDERR to '//./NUL': No such file or directory at mysql-test-run.
pl line 4136
can't redirect STDERR to '//./NUL': No such file or directory at mysql-test-run.
pl line 4136
------------------------------------------------------------
The servers were restarted 3 times
Spent 114.063 of 224 seconds executing testcases

All 4 tests were successful.

miguel@tikal /cygdrive/c/build/5.1/mysql-test
[15 Feb 2010 21:30] Sveta Smirnova
Thank you for the report.

I can not repeat described behavior too.

Bjorn, having your feedback probably status of this bug should be "Verified" or "Assigned" still? So we can document documentation and/or MTR will be fixed?
[26 Feb 2010 15:40] Satya B
I faced this issue today, I am able to run mtr but with  lots of warnings

can't redirect STDERR to '//./NUL': No such file or directory at mysql-test-run.
pl line 4136

cygwin version is : 1.7.1-1
[2 Mar 2010 14:50] Valeriy Kravchuk
I can not repeat this with 5.1.44 under recent Cygwin on XP. Moreover, I do not see (was unable to ind) any place in the code where cygpath is called with -y command line option.
[3 Mar 2010 9:23] Sveta Smirnova
3 members of Bugs Analysis could not repeat this problem with Cygwin 1.7, so this should be in "Can't repeat" status. I also see no reference to cygpath -y in current sources. If you are not agree with status please provide additional circumstances bug is repeatable under and reopen the report.