ZTree.com  | ZEN  | About...  

 Index   Back

[Help!] Windows path length - can it be extended ??   [Help!]

By: Ben Kent       
Date: Feb 04,2020 at 17:57
In Response to: [Help!] Windows path length - can it be extended ?? (Bob Selby)

> I have a NAS server on my network and I use ZTWin to backup the
> files to a removeable USB drive.
> I am running Win 7 on the laptop and the NAS is Linux based.
> I have moved files from Win7 to the NAS with ZTW OK (and vice versa)
> and am able to access the files with windows apps OK
> However, when I use ALT+M to mirror (with option Sync=OneWay) it
> complains about a "bad filename" ... trimming the directory path fixes
> the problem.
> I assume this is down to the path length supported by ZTW - Is there
> any way to extend the path ???
> Is it perhaps different for normal copying and ALT+M ???
> Best regards
> Bob

ZTree uses the Standard Win32 APIs, so is limited by MAX_PATH=260
As ZTree is Unicode there is the possibility of using the \\?\ path prefix to enable the 32,767 limit, but it looks like only a subset of the API's support the longer limit, see https://docs.microsoft.com/en-us/windows...aming-a-file#file-and-directory-names

Also you need to keep within the limits of the file system are working with. It can get complicated for example a drive letter to a share, with DFS links to non-windows hosted file systems (Linux etc), that has symlinks somewhere, ...

As already noted, sometimes shortening the path can get you working.
Map the drive with a shortname instead of the FQDN, or create a shorter alias or hostfile entry.
Create a share that points to a deeper location on the destination and map to that instead.
Use Subst

Robocopy uses the \\?\ prefix, so you can handle files with that up to what the file system(s) will handle.

Given these in BETA.TXT/HISTORY.TXT, maybe a little more ZTree work would get you working.
Fixed - Alt-Graft - Problem with source paths longer than MAX_PATH
Fixed - Ctrl-Search - Full pathnames limited to MAX_PATH
Fixed - Compare - Limited to comparing paths of MAX_PATH length


Thread locked

Messages in this Thread

95,040 Postings in 11,980 Threads, 349 registered users, 33 users online (1 registered, 32 guests)
Index | Admin contact |   Forum Time: Jul 6, 2020 - 12:28 pm EDT  |  Hits:31,975,112  (11,105 Today )
RSS Feed