Link to home
Start Free TrialLog in
Avatar of terry4sap
terry4sap

asked on

Cannot delete xxx.zip.vir.vir.vir.vir..... file.

I'm trying to remove a file that is stalling a robocopy. The message I get is "Cannot delete file: Filename is invalid or too long."

I have tried renaming it but I keep getting the same message.

Any ideas?
Terry
Avatar of ghana
ghana
Flag of Germany image

What's the name of the file?

One possibility is that this file has a reserved filename. On NTFS you can not delete or access those files with the normal syntax. Try the following command, to delete a file called 'prn.txt' in the root of drive C:

DEL \\.\c:\prn.txt

Common usage: DEL \\.\drive letter:\path\file name


In the Microsoft Knowledgebase there is an article that describes, how to delete files with reserved names in Windows:
http://support.microsoft.com/default.aspx?scid=KB;en-us;q120716 

Hope this helps.
Avatar of terry4sap
terry4sap

ASKER

YER Oct 1999.zip.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir
YER Oct 1999.zip.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir
When I run via a command prompt I get "Cannot find the path specified."
When I run per the instructions in the KB article via a command prompt I get "Cannot find the path specified."
ASKER CERTIFIED SOLUTION
Avatar of ghana
ghana
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
My guess is this file is located in your IE cache?  Try opening IE and clearing the cache.  Note down path and using a boot disk, go into DOS and try to delete there.

I'd virus check this PC too.
try putting the path in quotes
del "c:\where ever\1999.zip.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir.vir"
One thing you can do is open the windows folder and find wininit.bak and rename it to wininit.ini and open the file. Then erase what is in there and put try to rename the file or delete using the following syntax.

[Rename]
c:\currentfilename.txt=c:\newfilename.txt

or

[Delete]
c:\filename.txt

I haven't tried this on Windows NT environments but it does work on Win95/98
What kind of Anti Virus program are you using.  I've found that you need to disable the AV software before you can delete *.vir files.
Delete using dos.

Open notepad.
Type: del xxx.zip*
Save the file as: Delete.bat
Double click the file.

Point me.
Aenox
terry4sap,

have you already tried to shorten the path as I recommended in my last posting?
ghana,
That did the trick. 89 characters in the pathname preceding the file. Nice call.

tituba2,
the machine is a server and is not used for internet browsing. It's running NAVCE. The file was not accessed since 1999. Since then we have switched from Mcafee to Symantec. I think the file was in limbo since the OS could not track the 257 character file path.

stevenlewis,
I tried that before posting.

Joeisanerd,
I can't simply reboot this system since it is a production group file server (but that is something I would try at home).

Orion3799,
NAVCE. Which AV software requires this?

Aenox,
That would work except in this case. DOS will not accept pathnames beyond 256 characters whether enclosed in quotes or not.

All,
Thanks for your responses. I look forward to helping all of you as well.

Points to ghana.

Terry


It is the simple things that are easiest overlooked.
Grade A because of excellent follow-up.
Terry
Thanks Terry. Glad that we could help you.