Mail Archives: cygwin/2007/04/22/00:27:37
I have a non-administrative installation of Cygwin on Windows Server 2003 that I connect to from a laptop running Windows XP by using Remote Desktop.
The laptop's local C drive is shared over the connection by using the Remote Desktop / Windows Terminal Server (tsclient) functionality :
e.g. in a .bat startup script on the Windows server, I do this to mount a directory from the laptop
net use z: \\tsclient\c\zfolder
In Windows on the server, I can see and read/write the files with Windows applications in the mounted folder and in a Cygwin Ksh shell an automatic mount of z: has been done:
t838014 AT BCSDITS3:/home/t838014> mount
H:\cygwin\bin on /usr/bin type user (binmode)
H:\cygwin\lib on /usr/lib type user (binmode)
H:\cygwin on / type user (binmode)
c: on /cygdrive/c type user (binmode,noumount)
e: on /cygdrive/e type user (binmode,noumount)
h: on /cygdrive/h type user (binmode,noumount)
z: on /cygdrive/z type user (binmode,noumount)
However, in Cygwin when I try to access (stat) any of the directories in or under /cygdrive/z, I get permission denied:
t838014 AT BCSDITS3:/home/t838014> ls -las /cygdrive/z
ls: reading directory /cygdrive/z: Permission denied
total 0
0 drwxr-xr-x 0 t838014 Administrators 0 Dec 31 1969 .
0 dr-xr-xr-x 1 0 root 0 Dec 31 1969 ..
But, if I know where a file is located within this directory (or a sub-directory), I can use it in Cygwin:
t838014 AT BCSDITS3:/home/t838014> echo "this works" > /cygdrive/z/foo
t838014 AT BCSDITS3:/home/t838014> ls -asl /cygdrive/z/foo
1 -rw-r--r-- 1 t838014 Administrators 11 Apr 21 21:11 /cygdrive/z/foo
t838014 AT BCSDITS3:/home/t838014> cat /cygdrive/z/foo
this works
Note that I've set the CYGWIN env. variable to "binmode ntsec" and I've tried setting smbntsec on as well.
So, why can I see the files with Windows Explorer, but yet not with an "ls" in Cygwin? Is there a fix of some kind for this odd behaviour?
Ross Lavender
Sr. Technology Specialist
TELUS ITI, NIVR/CTI Operations
t 604.432.5930
c 778.828.4802
p 604.320.1020
www.telus.com
TELUS(r)
The future is friendly(r)
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
- Raw text -