I need to delete a large 400GB .BAK file that was a database backup on WIndows 2012r2 but get error 0x80070570

Thor2923
Thor2923 used Ask the Experts™
on
A database admin came to me today trying to delete one of her .bak files. She cannot can continues to get error 0x80070570 the file or directory is corrupted or unreadable. I have googled around and this happens on desktops a lot and the fix it to run a check disk and probably reboot. This is an active SQL server and I do not have the luxury of just rebooting. Does anyone know of another way out of this? I do not think it is related but I did notice the .BAK files are set up use Notepad as their default application which I know is not the default. I do not see a simple way to change that back to what I think is no app at all. Any insight on that would help too. We are running Windows 2012r2...thanks
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
AlanConsultant

Commented:
Hi,

Have you tried deleting it from DOS (or PowerShell) ?

If you read the attributes from a shell, what do you get?


Alan.
JohnBusiness Consultant (Owner)
Most Valuable Expert 2012
Expert of the Year 2018

Commented:
Try deleting it with Unlocker 1.9.2.  Google for Unlocker and pick a good source. You may get some ads so watch for that.

Try this link:   http://m.majorgeeks.com/files/details/unlocker.html
AlanConsultant

Commented:
Just going to note that I would not use third party software on a SQL Server (or Exchange Server for that matter) unless I had no other choice - a last resort if you like, and that would be after booting into a Live Linux DVD, and trying to delete it from there.

I have nothing against Unlocker - this is a general prejudice of mine :-)

Probably a simple reboot would do it anyway, but obviously that is not easy given the setup you describe.


Alan.
Ensure you’re charging the right price for your IT

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden using our free interactive tool and use it to determine the right price for your IT services. Start calculating Now!

JohnBusiness Consultant (Owner)
Most Valuable Expert 2012
Expert of the Year 2018

Commented:
Unlocker works fine and will not require a reboot, so that is why I suggested it.

Commented:
Try to move the files into to an empty folder. Then delete the folder. See if that works.
Raja Jegan RSQL Server DBA & Architect, EE Solution Guide
Awarded 2009
Distinguished Expert 2018

Commented:
Try to see whether anyone else have already tried to open up that *.bak file using Notepad and left it open or not.
Also try to see whether any process is utilizing that file preventing it to get deleted, you can try using sysinternals process explorer to see whether any user process or antivirus or any process is placing locks on that file or not.
https://docs.microsoft.com/en-us/sysinternals/downloads/process-explorer
Oracle dba
Top Expert 2009
Commented:
after process explorer ...

for deleting locked files, there is also the option to mark it to delete at reboot.
either enter the file name in  HKLM\System\CurrentControlSet\Control\Session Manager\PendingFileRenameOperations

or use the move file utility of SysInternals for that
https://docs.microsoft.com/en-us/sysinternals/downloads/movefile

you might not win back the space until reboot
Raja Jegan RSQL Server DBA & Architect, EE Solution Guide
Awarded 2009
Distinguished Expert 2018

Commented:
Hi Thor2923,

It would be better if you can explain what you have did to resolve the issue after we have all provided our comments..

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial