Cixert Posted December 13, 2022 Posted December 13, 2022 (edited) This is a problem that I have had without a solution for a long time, I use FAT32. When I copy multiple folders if any file has a name that exceeds the Windows file length limit then XP copies it without giving any error and changing the long name to a short one with 8 characters and "~" symbol. For example, if the file has the name: "program to read documents PDF.exe" Windows XP renames it without giving any error to: "program~.exe" Apparently the file keeps its real name somewhere, since a shortcut still finds it with the short name, but it prevents me from knowing the true name of the file. I would like to know how: 1-Be able to see the long file name again. 2-What Windows XP gives an error message when I am copying a file with a long name that exceeds the limit, instead of automatically changing the name. I don't have this problem in Windows 2000, so when I go to copy and paste a lot of files I have to restart and use w2K, which gives me an error that it can't copy long names instead of renaming them. Edited December 13, 2022 by Cixert
jaclaz Posted December 13, 2022 Posted December 13, 2022 Check this, though it is improbable: https://learn.microsoft.com/en-us/archive/blogs/astebner/registry-key-to-force-windows-to-use-short-filenames Quote Key name: HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\FileSystem Value name: Win31FileSystem Data type: REG_DWORD Setting this value to 0 will allow Windows to use long filenames. Setting this value to 1 will force Windows to use short filenames. Maybe it is *something else* that *somehow* prevents the proper setting of the secondary entry, you could check the actual file/folder entry on the filesystem: https://www.ntfs.com/fat-filenames.htm AFAIK the long and short filenames are two separate entries (the short filename one is automatically generated at file creation), which explains why you have your long file name shortcuts still working, so it could be *something* that only shows the short filename. Does this happen with *any* copy utility/method or just with a given one? As well, do you see the short file name with *any* tool (dir from command line, explorer, other file manager, etc.) or just in a given one? Are you sure that the issue is with filenames (and not with long PATH)? jaclaz
Cixert Posted December 25, 2022 Author Posted December 25, 2022 On 12/13/2022 at 10:42 AM, jaclaz said: Check this, though it is improbable: https://learn.microsoft.com/en-us/archive/blogs/astebner/registry-key-to-force-windows-to-use-short-filenames Maybe it is *something else* that *somehow* prevents the proper setting of the secondary entry, you could check the actual file/folder entry on the filesystem: https://www.ntfs.com/fat-filenames.htm AFAIK the long and short filenames are two separate entries (the short filename one is automatically generated at file creation), which explains why you have your long file name shortcuts still working, so it could be *something* that only shows the short filename. Does this happen with *any* copy utility/method or just with a given one? As well, do you see the short file name with *any* tool (dir from command line, explorer, other file manager, etc.) or just in a given one? Are you sure that the issue is with filenames (and not with long PATH)? jaclaz ok, I thought that the double name was only in NTFS, I read that in FAT too. The problem is that when I copy and paste a file into a long path, that it exceeds the character limit. Windows XP automatically renames a file with a long name to a file with 8 characters. If XP does not achieve 8 characters it gives an error, but if it can it automatic renames. This does not happen to me in windows 2000, it always gives a long path error. Does it only happen to me on XP? This has been happening to me since 2001. is it possible to recover in the File Allocation Table the original long file name? Both in the console and in Total Commander it shows the short name of the renamed file. The registry entries you comment are fine
Cixert Posted March 13, 2023 Author Posted March 13, 2023 (edited) I have found a way to disable duplicate creation of 8.3 short names on FAT32 plus NTFS but this does not apply when it exceeds the 260 character path, in which case XP automatically renames long files to 8.3, when the folders are copied. This issue does not happen on Windows 2000. To disable: fsutil behavior query disable8dot3 1 To enable: fsutil behavior query disable8dot3 0 To check status: fsutil behavior query disable8dot3 https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/fsutil-behavior On the other hand, I have read here that it is convenient to disable the function of creating duplicate names.I don't know if this can cause problems, for example with tools to recover the system that work from CD-ROM or floppy disk. https://ttcshelbyville.wordpress.com/2018/12/02/should-you-disable-8dot3-for-performance-and-security/ BEWARE the commands of the last link do not apply in XP. (not to be confused with the NT 6 fsutil 8dot3name command) I have found the following tools to detect long paths: -Long Path Tool (also copies long paths) (demo) -TLPD (Too Long Paths Detector) -Path Scanner (trial 13 uses) -Robocopy, command to copy folders from Windows Server 2003 Resource Kit Tools Edited March 13, 2023 by Cixert
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now