Link to home
Create AccountLog in
Avatar of sbornstein2
sbornstein2

asked on

Windows OS - Need a batch file or a script to close all locks on open files? Possible?

I have a windows server 2008 R2 and a root folder such as D:\DataFiles that I want to force close all open files somehow in that root and all the subfolders beneath it.   Is this possible with a batch file?
Avatar of Skyler Kincaid
Skyler Kincaid
Flag of United States of America image

I don't think so. You could restart the server service which would end any open connections to files but also cuts off other shares and prints.
ASKER CERTIFIED SOLUTION
Avatar of Qlemo
Qlemo
Flag of Germany image

Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
See answer
Avatar of sbornstein2
sbornstein2

ASKER

tx