Link to home
Start Free TrialLog in
Avatar of dbaser
dbaser

asked on

Copying locked files???

Hi,

Is it possible to copy a file which another process as taken out a lock on? For example, MS Access locks all .mdb files when databases are open.

Strange question, I know... that's what locks are there for!! However, I'm writing a backup program and would very much like to backup these files, even when they are open. I only need read access to them.

Any ideas?
Kieran
ASKER CERTIFIED SOLUTION
Avatar of jkr
jkr
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
Avatar of jhance
jhance

Whether you can read a locked file or not depends on how the "owner" of the lock has designed it.  If it's EXCLUSIVE then there is no way to do it since Windows prevents any other access.  Most backup SW that I've seen/used just reports those files that are locked since they cannot be backed up.
>>Most backup SW
>>that I've seen/used just reports those files that are
>>locked since they cannot be backed up.

That's why my backups are scheduled to run when I'm guaranteed not to be there and have files locked ;o)
Avatar of dbaser

ASKER

Spanx All,

Yep... that's what I figured alright.

Just wondering if anyone knew any sly ways around it!! :)

Thanks anyway,
Kieran
What platform are you use?
Avatar of dbaser

ASKER

I'm using Windows 2000.

I've since seen a program advertised on the web called "Open File Manager". The blurb say that is "software that enables most backup software, including Windows 2000/NT backup, to capture open files during the backup/copy process - even if the files are changing."

http://www.gateway-websites.com/cgi-bin/ePages4.storefront/3b826642007d8382271dc0a80b6506f8/Export/products/112300-2D1001973

Anyone got any ideas how this works????
Dear dbaser

I think you forgot this question. I will ask Community Support to close it unless you finalize it within 7 days. You can always request to keep this question open. But remember, experts can only help you if you provide feedback to their questions.
Unless there is objection or further activity,  I will suggest to

     "refund the points and PAQ at zero points"

since nobody had a satisfying answer for you.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
======
Werner
I suggest you force accept jkr here.  His comment is both first and accurate.

I'll just point out again that SOMETIMES the correct answer is NO, IT CANNOT BE DONE.  Not liking the answer doesn't make it any less correct.
Thanks for the feedback. I completely agree with your "NO" statement (jkr was my initial suggestion). What made me change my mind was the last question about "Open File Manager". But since there is proof that it really works, I guess you are right with jkr.

======
Werner
Force accepted

** Mindphaser - Community Support Moderator **