undeletable directory/files . filename too long
i cant delete this directory anymore (using explorer but also in the command shell) i have no idea how this directory was screwed up like it is now . but currently i have no idea how i can delete it the directory is not my actual user directory (it was a copy i created using the repair console with the windows vista ultimate dvd before setting up windows after the black screen phenomen) D:\Users\Wolfgang\AppData\Local>dir Volume in Laufwerk D: hat keine Bezeichnung. Volumeseriennummer: C846-B29F Verzeichnis von D:\Users\Wolfgang\AppData\Local 20.01.2008 23:36 <DIR> . 20.01.2008 23:36 <DIR> .. 20.01.2008 23:36 <DIR> Anwendungsdaten 0 Datei(en), 0 Bytes 3 Verzeichnis(se), 120.528.334.848 Bytes frei D:\Users\Wolfgang\AppData\Local>del * /S Mchten Sie "D:\Users\Wolfgang\AppData\Local\*" lschen (J/N)? J Mchten Sie "D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\*" lschen (J/N)? J Der Verzeichnisname D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\ Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwe ndungsdaten\Anwendungsdaten ist zu lang. D:\Users\Wolfgang\AppData\Local> rd Anwendungsdaten /S Anwendungsdaten\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1 \ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\Adobe\FLASHC~1\en\CONFIG~1\KEYBOA~1\FreeHand 10.wfx - Der Dateiname ist zu la ng. Anwendungsdaten\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1 \ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\Adobe\FLASHC~1\en\CONFIG~1\KEYBOA~1\Illustrator 10.wfx - Der Dateiname ist zu lang. ~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\DCBC2A~1.INI - Der Dateiname ist zu lang. etc etc Anwendungsdaten\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1 \ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\ANWEND~1\GDIPFONTCACHEV1.DAT - Der Dateiname ist z u lang. D:\Users\Wolfgang\AppData\Local> (german message for "filename is too long") chkdisk also does not show any problem Microsoft Windows [Version 6.0.6000] Copyright (c) 2006 Microsoft Corporation. Alle Rechte vorbehalten. C:\Windows\system32>chkdsk d: /F /V /R /B /X Der Typ des Dateisystems ist NTFS. CHKDSK berprft Dateien (Phase 1 von 5)... 123520 Datenstze verarbeitet. Dateiberprfung beendet. 21 groe Datenstze verarbeitet. 0 ungltige Datenstze verarbeitet. 0 E/A-Datenstze verarbeitet. 0 Analysedatenstze verarbeitet. CHKDSK berprft Indizes (Phase 2 von 5)... 387447 Indexeintrge verarbeitet. Indexberprfung beendet. 5 nicht indizierte Dateien verarbeitet. CHKDSK berprft Sicherheitsbeschreibungen (Phase 3 von 5)... 123520 Sicherheitsbeschreibungen verarbeitet. berprfung der Sicherheitsbeschreibungen beendet. 6634 Datendateien verarbeitet. CHKDSK berprft Dateidaten (Phase 4 von 5)... 123504 Dateien verarbeitet. Dateidatenberprfung beendet. CHKDSK berprft freien Speicherplatz (Phase 5 von 5)... 29426886 freie Cluster verarbeitet. Verifizierung freien Speicherplatzes ist beendet. Das Dateisystem wurde berprft. Es wurden keine Probleme festgestellt. 625135615 KB Speicherplatz auf dem Datentrger insgesamt 507190088 KB in 70235 Dateien 29196 KB in 6636 Indizes 0 KB in fehlerhaften Sektoren 208783 KB vom System benutzt 65536 KB von der Protokolldatei belegt 117707548 KB auf dem Datentrger verfgbar 4096 Bytes in jeder Zuordnungseinheit 156283903 Zuordnungseinheiten auf dem Datentrger insgesamt 29426887 Zuordnungseinheiten auf dem Datentrger verfgbar C:\Windows\system32> the directory looks a bit screwed up D:\Users\Wolfgang>dir /X /S /R /Q /D Volume in Laufwerk D: hat keine Bezeichnung. Volumeseriennummer: C846-B29F Verzeichnis von D:\Users\Wolfgang 20.01.2008 23:39 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:39 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM AppData 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM Local 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:36 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM .. 0 Datei(en), 0 Bytes Der Verzeichnisname D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\ Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwe ndungsdaten\Anwendungsdaten ist zu lang. Anzahl der angezeigten Dateien: 0 Datei(en), 0 Bytes 11 Verzeichnis(se), 120.529.383.424 Bytes frei ("ist zu lang" means "too long") any ideas of some real windows expert or more experienced users ? tnx in advance for any help regards Wolfgang regards
February 14th, 2008 2:27pm

(part 2) adding the hidden attribut option it looks even more strange D:\Users\Wolfgang>dir /X /S /R /Q /D /AH Volume in Laufwerk D: hat keine Bezeichnung. Volumeseriennummer: C846-B29F Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten 20.01.2008 23:36 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:36 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:36 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:36 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:36 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anw endungsdaten 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:36 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anw endungsdaten\Anwendungsdaten 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:36 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anw endungsdaten\Anwendungsdaten\Anwendungsdaten 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:36 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:37 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anw endungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten 20.01.2008 23:37 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:37 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:37 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anw endungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten 20.01.2008 23:37 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:37 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:37 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anw endungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten 20.01.2008 23:37 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:37 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:37 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anw endungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten 20.01.2008 23:37 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:37 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:37 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anw endungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten 20.01.2008 23:37 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:37 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:37 <DIR> ANWEND~1 NT-AUTORITT\SYSTEM Anwendungsdaten 0 Datei(en), 0 Bytes Verzeichnis von D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anw endungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendu ngsdaten 20.01.2008 23:37 <DIR> NT-AUTORITT\SYSTEM . 20.01.2008 23:37 <DIR> NT-AUTORITT\SYSTEM .. 20.01.2008 23:39 <DIR> ANWEND~1 ... Anwendungsdaten 0 Datei(en), 0 Bytes Der Verzeichnisname D:\Users\Wolfgang\AppData\Local\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\ Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwendungsdaten\Anwe ndungsdaten\Anwendungsdaten ist zu lang. Anzahl der angezeigten Dateien: 0 Datei(en), 0 Bytes 40 Verzeichnis(se), 120.529.383.424 Bytes frei D:\Users\Wolfgang>
Free Windows Admin Tool Kit Click here and download it now
February 14th, 2008 2:29pm

(part 3) somehow it looks like a kind of recursiv link i also tried some resource kit tools D:\A\B\C\D\E\F\G\H>delrp /? | more Deletes a file, including files with associated NTFS reparse points of any kind. DELRP [/?] Filename When run without arguments this program will display the help message. /? Print this help message This program will delete the named file/directory whether it has a reparse point or not. All the characters in FileName must be in the ASCII character set. Usage of arbitrary Unicode characters is not supported. Type "DELRP /? | more" if you need to see all the help text D:\A\B\C\D\E\F\G\H>delrp Anwendungsdaten The delete call failed. D:\A\B\C\D\E\F\G\H>attrib -H -R -S Anwendungsdaten D:\A\B\C\D\E\F\G\H>dir /X Volume in Laufwerk D: hat keine Bezeichnung. Volumeseriennummer: C846-B29F Verzeichnis von D:\A\B\C\D\E\F\G\H 20.01.2008 23:36 <DIR> . 20.01.2008 23:36 <DIR> .. 20.01.2008 23:36 <DIR> ANWEND~1 Anwendungsdaten 0 Datei(en), 0 Bytes 3 Verzeichnis(se), 125.419.855.872 Bytes frei D:\A\B\C\D\E\F\G\H>delrp Anwendungsdaten The delete call failed. D:\A\B\C\D\E\F\G\H>delrp ANWEND~1 The delete call failed. D:\A\B\C\D\E\F\G\H>LINKD /? | more Links an NTFS directory to a target valid object name in Windows 2000. LINKD Source [/D] Destination Source - Displays the Windows 2000 name targeted by Source Source Destination - Links source directory to Destination directory or a Windows 2000 device or any valid Windows 2000 name Source /D - Deletes Source, regardless of whether a link exists at source /? - Prints this help message LINKD grafts (links) the target name directly into the name space at Source, so that Source subsequently acts as a name space junction. The Source directory must reside on a disk formatted with NTFS in Windows 2000. The destination (the target of the link) can be any valid directory name or device name or valid object name in Windows 2000. When the target name does not resolve to a directory or a device, open calls fail. All characters in both the Source and Destination names must be in the ASCII character set. Usage of arbitrary Unicode characters is not supported. Type "LINKD /? | more" if you need to see all the help text D:\A\B\C\D\E\F\G\H>linkd ANWEND~1 /D The delete operation failed. D:\A\B\C\D\E\F\G\H>linkd Anwendungsdaten /D The delete operation failed.
February 14th, 2008 2:30pm

Hi Wolfgang, I noticed the folder path of the problematic directory has 271 characters, which is beyond the MAX_PATH limitation (255 characters). To delete this directory, please try the following steps: ================= 1. Delete the directory via explorer.exe (GUI). 2. If it does not work, we can copy the directory to another location (the path is shorter than the MAX_PATH) using the command robocopy. For example:robocopy D:\Users\Wolfgang\AppData\Local\Anwendungsdaten D:\ /S /MOVEand then delete the directory. Note: Here is the explanation of the parameter /MOVE in the above command:/MOVE :: MOVE files AND dirs (delete from source after copying). Hope it helps. Sincerely, Joson Zhou Microsoft Online Community Support
Free Windows Admin Tool Kit Click here and download it now
February 19th, 2008 3:49am

Hi Thank you, but it is very strange and hard to understand what happens here 1. as already described above delete also did not work using explorer 2. how can a directory like that be created but not deleted (longer than 255) . i guess its from robocopy 3. the robocopy /MOVE did its work somehow and the "old" directory could now be deleted, but the new directory now has the same problem i then tried to move this dir to another disc again it worked and i could delete the rest of the directory then again the robocopied directory (on the other device) had the too long filename problem finaly i moved all data to external disk and formated the external disk afterwards thanks for your help Wolfgang p.s.: i guess this inconsistency which seems to be created by robocopy and cant be deleted by other methods of windows has to be fixed
February 19th, 2008 2:15pm

I seem to be out of resource here or im just too tired at the moment to look for answers on other sites. I have this problem, one folder was created courtesy of a bug in the IDE im using. It created multiple level of subfolders using the same name. Now my problem is i cant delete the whole folder. the folder name is 6 characters long but has been nested to it around 60 folders of the same name. Can anyone suggest how I could get rid of the folder and avoid the message prompt that the file name is too long?
Free Windows Admin Tool Kit Click here and download it now
July 29th, 2008 3:27pm

to delete a folder with long file names, first move it to another part on the disk so the total length of path no longer exeeds the max NTFS-lenght. e.g. move d:\folder\folder2\...\folder9999\ to e.g. d:\ Then you can delete folder9999.When encountering this limit, I suggest you re-think your folder structure.
October 14th, 2008 6:19am

My method is to create an empty folder on the root (i.e. C:\Empty) and then use robocopy with the PURGE switch.<o:p></o:p> ROBOCOPY "C:\Empty" "C:\Path to folder\to delete" /PURGE<o:p></o:p> Don't forget to run the command prompt as an administrator. Newbee
Free Windows Admin Tool Kit Click here and download it now
June 20th, 2012 4:50pm

Prepending \\?\ to filenames turns off checking that filenames adhere to Windows' naming standards. E.G. del "\\?\c:\path to folder\path to filename" -- .. -- "LaserMan" wrote in message news:8d873b55-6b97-498c-beeb-4c25b5e2b815... > My method is to create an empty folder on the root (i.e. C:\Empty) and > then use robocopy with the PURGE switch.<o:p></o:p> > > ROBOCOPY "C:\Empty" "C:\Path to folder\to delete" /PURGE<o:p></o:p> > > Don't forget to run the command prompt as an administrator. > > > -------------------------------------------------------------------------------- > > Newbee >
June 20th, 2012 5:54pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics