Jump to content

Impossible to delete file - possible corruption?


Recommended Posts

Posted

Hi all

 

Bit of a newbie here so please bear with me... :)

 

We have a folder on our server (Server 2012 R2) that simply will not be deleted. The file is on a network share and is called 'We are photographers'. The file is empty. When I tried previously to delete it I got the error that the directory could not be found. However, it was right there in front of me.

 

I used cmd to navigate to the directory and used the dir /x command to list all files. It appeared as listed there too.

 

I then tried the rmdir /q /s command to delete the folder as follows:

 

rmdir /q /s We are photographers

 

rmdir /q /s "We are photographers"

 

Which both returned the error: "The system cannot find the file specified".

 

I tried looking for the short name which I guess would be something like "Wearep~1". However, on the server no short names are listed when I type dir /x, only the long file names.

 

I also tried renaming the file but didn't have much luck there either.

 

Now when I try to delete the file (logged on as admin) I get no error - only 'Are you sure you want to delete this file?' and then nothing happens and the file stays there.

 

I'm actually worried that we have some corruption as there are roughly 10-15 folders that windows is unable to find, however the files inside them are intact.

 

Any ideas? Thanks much for all your help.

 

Mark

Posted (edited)

Hi Michael. Thanks for getting back to me so quickly.

 

We also have a folder called 'Evidence Video' that appears to be corrupt. It is in the following location: D:\Shares\Teachers-Shared\Planning Archive\Computing\Evidence Video

 

I tried renaming it manually but got the following error: "Could not find this item. This item is no longer located in D:\Shares\Teachers-Shared\Planning Archive\Computing\. Verify the items location and try again".

 

I have also tried renaming the file using cmd but the syntax is wrong:

 

Capture.JPG

I'm not that great with cmd... :)

Edited by Sparky28
Posted

Hi Jawloms

 

Thanks for replying. Sorry, I don't quite follow...

 

The computing folder is already shared, however, there is no drive mapped directly to it. Not sure quite how to proceed as I don't want to delete the folder. If I map it to a drive - how will I delete it?

 

Thanks, sorry for being dense...

 

Mark

Posted
You said the path is "D:\Shares\Teachers-Shared\Planning Archive\Computing\Evidence Video". If you can map a network drive to the "Computing" folder then the path will only be "X:" giving you a shorter path and possible the ability to delete what you need.
Posted (edited)

Hi Sparky28

 

Try the renaming like this

 

ren "D:\Shares\Teachers-Shared\Planning Archive\Computing\Evidence Video" ev

 

Because you have a space at 'Evidence Video', you need quotes around the path.

Edited by ollyyllo
Posted

Hi Jawloms,

 

Sorry, I get you now. Needed another coffee! I tried mapping it to Y:

 

Y:\Evidence Video

 

Still no joy...

 

"The system cannot find the file specified"

 

or

 

"Could not find this item. This item is no longer located in Y:\ Verify the item's location and try again."

 

Mark

Posted
Is it possible an application or a service of some kind is using the directory, hence why it cannot be renamed, moved or deleted as it's in use?
Posted

Hi Michael

 

I don't think anything is. Other folders in the computing folder can be renamed and deleted okay. Just specific ones that can't.

 

I there anyway I can check to know for sure nothing is using that specific folder?

 

Thanks for you help.

 

mark

Posted (edited)

One thing, I am using the back up software - Duplicati to copy across all photos and videos to our back up server on our network and it appears to be some of these files that are affected.

 

It's free software and can be a bit flaky. In fact it was the errors in the Duplicati log that made me investigate the folders in question...

 

I wonder whether that has got something to do with the problem?

 

Mark

Edited by Sparky28
Posted

Nothing unusual relating to the folders in Computer Management.

 

Michael, by logs do you mean Event Viewer? I there an easy way do upload them?

 

Mark

Posted
Just curious what the logs are saying from your backup application. It may be useful, but it may be not. Especially error codes. Usually yes, it should log events in Event Viewer.
Posted

try this for me

 

d:

cd D:\Shares\Teachers-Shared\Planning Archive\Computing\

dir enter

(screenshot output)

cd (type v and then hit tab) - does it shows "video evidence"

Posted

Have you rebooted the server lately?

 

iirc I had some folders/files that would not delete/rename, even using the 7zip trick.

 

When I rebooted they were actually gone, for some reason the server was just unwilling to let them go....

Posted

Hi Andy

 

Here's a screenshot:

 

Capturegfhfgh.JPG

 

Don't follow you on the second part "cd (type v and then hit tab)", sorry.

 

Thanks again everyone for all your help...

Posted

Hi Michael

 

Here is the error from the back up application:

 

 

  • Error reported while accessing file: D:\Shares\Teachers-Shared\Planning Archive\Computing\Evidence Video \
    System.IO.FileNotFoundException: Could not find file 'D:\Shares\Teachers-Shared\Planning Archive\Computing\Evidence Video\'.File name: 'D:\Shares\Teachers-Shared\Planning Archive\Computing\Evidence Video\' at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) at System.IO.File.GetAttributes(String path) at Duplicati.Library.Snapshots.SystemIOWindows.GetFileAttributes(String path) at Duplicati.Library.Utility.Utility.d__23.MoveNext()
     
    Mark

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...