Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 532
  • Last Modified:

file name too long

Dear Experts,

I have just restored a mailbox from an old backup, and some of the messages downloaded have names too long for our file system.
I have tried to rename them, but it comes back saying that that file name is not found.
(I am using ren command from DOS command prompt)
I have shortened the folder name that contains these messages to one character, there is nothing else I can shave off.
Isn't there a DOS command that forces to delete everything in the folder, such as del *.*?
(this also comes back that file name is too long.)
I think the key is to rename the files, but I have had no success.
Please advise.
0
yballan
Asked:
yballan
  • 3
  • 2
  • 2
  • +2
2 Solutions
 
duncanb7Commented:
Isn't there a DOS command that forces to delete everything in the folder, such as del *.*?

Do you try  this ?
del /F *.*

Or

del /F /S *.* (delete the directory's sub directory but take care of it )

Duncan
0
 
guswebbCommented:
what is the full path of the folder?
0
 
yballanAuthor Commented:
Dear Duncan, thank you for a quick response.  I did try those commands, but the same error message.

Dear guswebb,
The full path of the folder is c:\I and c:\DI.
0
Get your Disaster Recovery as a Service basics

Disaster Recovery as a Service is one go-to solution that revolutionizes DR planning. Implementing DRaaS could be an efficient process, easily accessible to non-DR experts. Learn about monitoring, testing, executing failovers and failbacks to ensure a "healthy" DR environment.

 
duncanb7Commented:
Could you capture or send us the error response on command shell
so that we can fully understand your question ?

Please show us every command you input on the command shell
0
 
bevhostCommented:
There is a dos command called SUBST which allows you to assign a drive letter to some folder
eg
SUBST K: C:\foo\bar\some\long\path\

Now you can access further down the tree from K:
0
 
bevhostCommented:
Renaming any long folder names to have just a single character will also help.
You have just 255 characters limit in total.
0
 
yballanAuthor Commented:
thank you, by using SUBST and del /F *.*, I was finally able to get those files removed!!
0
 
duncanb7Commented:
thanks and good to hear you solved  it

Have a nice day and a good weekend
0
 
Steve KnightIT ConsultancyCommented:
another good one for this is to use robocopy aswell,

robocopy c:\empty c:\brokendir /purge

the files in c:\brokendir are then removed as c:\empty has nothing in it.

steve
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 3
  • 2
  • 2
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now