Skip to content
Tcl Source Code View Ticket
Login

View Ticket

2003-04-11
23:33 • Closed ticket [697862ffff]: File access on mounted NTFS file systems does not wo... artifact: 39296bc728 user: vincentdarley
2003-03-31
23:58 • Ticket [697862ffff]: 4 changes artifact: 3dda49e0e9 user: weltrich
23:00 • Ticket [697862ffff]: 4 changes artifact: 77e7c8c263 user: vincentdarley
2003-03-18
17:19 • Ticket [697862ffff]: 5 changes artifact: 91f7f6cafe user: vincentdarley
14:31 • Ticket [697862ffff]: 4 changes artifact: b9d928296b user: weltrich
2003-03-17
22:39 • Ticket [697862ffff]: 4 changes artifact: 0f01a36a0b user: vincentdarley
2003-03-06
16:52 • Ticket [697862ffff]: 4 changes artifact: e31e4496e7 user: nobody
00:44 • Ticket [697862ffff]: 4 changes artifact: 2b65774a18 user: hobbs
2003-03-05
09:07 • New ticket [697862ffff]. artifact: 7a967dac4d user: weltrich

File access on mounted NTFS file systems does not work

Closed / Fixed697862ffffffffffffffffffffffffffffffffffCreated 24 years agoUpdated 24 years ago
Descriptionplain2003-03-05 09:07:12
If a disk partition is mounted in a NTFS directory instead 
of using a drive letter, Tcl 8.4.x can not access files in 
this directory tree (e.g. "file attr <filename>" 
returns "could not read <filename>: no such file or 
directory").
This error does not occur in Tcl 8.3!
hobbsplain2003-03-06 00:44:42
Logged In: YES 
user_id=72656

I can't see how to reproduce this.  Can you be more specific 
about exactly how you get this error? Are 
these //computer/drive paths, or ???
nobodyplain2003-03-06 16:52:55
Logged In: NO 

I mount the disk partition in the following way:
1. Creation of an empty directory in another directory, 
e.g. "mkdir c:\tmp\partition2"
The problem does not occur if the mount directory is 
subdirectory of the root directory!
2. Assign the path c:\tmp\partition2 to a disk partition (via 
right mouse click on the disk partition in the computer 
administration window)

Now it is not possible to access files in the c:\tmp\partition2 
directory (which are files on the corresponding disk partition).
The Tcl command "file attr c:/tmp/partition2/xyz" returns: 
could not read "xyz": no such file or directory
vincentdarleyplain2003-03-17 22:39:13
Logged In: YES 
user_id=32170

Can you give the actual sequence of actions with what 
programs (what is the "computer administration 
window") to create this problem?

thanks.
weltrichplain2003-03-18 14:31:13
Logged In: YES 
user_id=122896

Hello Vincent,
I am sorry, I have a german version of Windows XP, therefore 
I don't know exactly the english name of the menu to open 
the computer administration. It should be something like 
start/program files/administration/computer administration.
The windows allows administration functions for system, 
storage and services. Within the "storage" subfunction, the 
drives and the disk partitions are shown. If you point with the 
mouse on a partition you get on right mouse click a context 
menu with a menu entry which should have a name 
like "change drive letter or -path" (this is the word by word 
translation of my german name of the menu entry). If you call 
this entry you can assign the name of an empty directory to 
this partition. After that you can access the files on this 
partition with the relative path names on the partition prefixed 
with the path of the directory assigned to this partition.
From TCL you cannot access the files on the partition via the 
path name including the mount-directory, if the mount-
directory is not a direct subdirectory of the root-directory.
That means, if for example c:/xyz is used as mount directory, 
TCL can access files with names c:/xyz/abc. If you use for 
example c:/tmp/xyz as mount directory TCL 8.4.x cannot 
access files with names c:/tmp/xyz/abc. TCL 8.3 can access 
these files!
vincentdarleyplain2003-03-18 17:19:40
Logged In: YES 
user_id=32170

Thanks for the detailed description -- I have a fix to 
this now.  The problem is that NTFS doesn't seem to 
distinguish between a 'symlink' type reparse point and a 
mounted-drive type reparse point.  The former points to 
a valid directory, whereas the latter doesn't --- hence 
Tcl can't find the file.  The solution is for Tcl to ignore 
the latter kind of reparse point.  Unfortunately win32 
doesn't seem to provide us with quite the right sort of 
info.  I've managed to put in a check for something 
which works for me, but I really cannot be sure it'll work 
in all cases.  I'll check this in soon.
vincentdarleyplain2003-03-31 23:00:48
Logged In: YES 
user_id=32170

When you mount the partition into this directory, does 
the partition also appear as a new volume (under 'My 
Computer') as well?  That's what happens for me, and if 
this is always true, the mount should appear just like a 
symlink.

...I'm trying to work out how best to fix this.
weltrichplain2003-03-31 23:58:00
Logged In: YES 
user_id=122896

The partition appears only as drive under my computer if a 
drive letter is assigned. My intention was to have no drive and 
no drive letter to access the partition in a Unix like matter as 
part of the file tree. In the moment I have assigned a drive 
letter to the partition as workaround to access the partition 
from tcl applications via drive letter.
vincentdarleyplain2003-04-11 23:33:07
Logged In: YES 
user_id=32170

A good fix is now in cvs head.  it works well for me.  
Thanks for the helpful instructions and pointers.
Log in (anonymous is fine) to add a comment.