This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Problem with ssh in non-interactive mode and mapped drives


Hello,

I have a mapped drive pointing to a Windows network share. In this
share I have several files for which I'm checking the MD5 with this
command:
if [ `/bin/cat /cygdrive/z/builds/latest/PROJECT.MD5 | grep PROJECT_TM
| cut -f 1 -d " "` ==
`md5sum.exe /cygdrive/z/builds/latest/PROJECT_TM.zip | cut -f 1 -d "
"` ]; then echo "PROJECT_TM package MD5 matched expected MD5."; else
echo "PROJECT_TM package MD5 did not match expected MD5: `/bin/cat
/cygdrive/z/builds/latest/PROJECT.MD5 | grep PROJECT_TM | cut -f 1 -d
" "`"; exit -2; fi

PROJECT_TM package MD5 matched expected MD5.


When running the command interactively, everything is ok:
PROJECT_TM package MD5 matched expected MD5.

When running the command non-interactively, with this: ssh
PROJECTctier@LOCATIONsd-vm-admin.PROJECT.COMPANY.com 'COMMAND', I get
this:
No such file: /cygdrive/z/builds/latest/PROJECT_TM.zip
bash: line 0: [: c3e3cb8bb6b7b07915755ba8d242fa56: unary operator expected
PROJECT_TM package MD5 did not match expected MD5:
c3e3cb8bb6b7b07915755ba8d242fa56
Connection to LOCATIONsd-vm-admin.PROJECT.COMPANY.com closed.

I tried ssh -t, ssh -tt, same thing happens.

Got any idea why the file is not found in non-interactive mode?
Further information:
uname -srv
CYGWIN_NT-6.0-WOW64 1.7.9(0.237/5/3) 2011-03-29 10:10

mount
Z: on /cygdrive/z type netapp (binary,posix=0,user,noumount,auto)

ls -lah /cygdrive/z/builds/latest/PROJECT_TM.zip
-rwxrwx--- 1 Administrators Domain Users 25M Nov 29 00:26
/cygdrive/z/builds/latest/PROJECT_TM.zip


I'm kinda stumped (still digging though) :(
_____________
Costin Caraivan

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]