Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: 'drop tablespace' produces a file/table lock??

Re: 'drop tablespace' produces a file/table lock??

From: Billy Verreynne <vslabs_at_onwe.co.za>
Date: 28 Jul 2003 22:44:41 -0700
Message-ID: <1a75df45.0307282144.dc54849@posting.google.com>


Brian Peasland <dba_at_remove_spam.peasland.com> wrote

> But the big question is why does
> Windows force these DLL's to be locked? You don't see the same thing
> with shared library files in Unix.

Why assume Unix does it right? (all the the other o/s's I've worked with thru the years do not allow locked files to be deleted)

Fact. You _CAN_ delete a "locked DLL" (or any other locked file) on Windows. IF the programmer used the appropriate share lock flag to allow it to happen.

> The whole thing boils down to MS
> deciding that they know more than I do and they are trying to protect me
> from doing bad things. They leave out the fact that I may know what I am
> doing and that I may know more about what I am doing than they do...

They allow the choice to the programmer to decide if the user knows what he is doing. In this particular case.

Brian, what I'm seeing in this topic is a typical Microsoft-sucks-and-is-bad kneejerk.

It is much safer _not_ being able to delete files in use. It is much better to allow the developer to decide just how safe it is to have a locked file deleted, and whether or not that should be allowed.

The ability to delete locked files on Unix without any safety meassures to prevent that is just plain bloody stupid. Made worse by the fact that the physical file (ionodes) is not deleted, causing even more confusion on user side.

As for the OP's actually problem - the user not being able to delete a file after dropping the tablespace. An Oracle datafile is not just locked once. Many other processes can have locks on the file, including the DB writers, SMON, Log writer and so on. Dropping a tablespace does not mean that these process will immediately and automagically close their file handles.

IMO, the fundemental problem here is
- dislike of Windows clouding logic
- basic lank of understanding of how file locking works

--
Billy
Received on Tue Jul 29 2003 - 00:44:41 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US