Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Truncate command internal behavior
"joel garry" <joel-garry_at_home.com> wrote in message
news:1161118225.385114.111270_at_m7g2000cwm.googlegroups.com...
>
> I also would like to know exactly what oracle does in a truncate.
> Seems like RAC complicates the issue, even for non-RAC environments.
> There was a time when a truncate could simply set the highwatermark and
> free lists to 0, but that time seems gone.
>
Truncate always had to do a segment checkpoint (write dirty blocks from the segment), and buffer cache clear (free up any buffers in the cache that held clean blocks for the segment).
As people started to introduce larger and larger buffer caches, the search of the buffer cache became expensive and Oracle has been fiddling with the strategy for clearing blocks at the segment level for quite some time to try and handle it safely.
-- Regards Jonathan Lewis http://www.oracle.com/technology/community/oracle_ace/ace1.html#lewis The Co-operative Oracle Users' FAQ http://www.jlcomp.demon.co.uk/faq/ind_faq.html Cost Based Oracle: Fundamentals http://www.jlcomp.demon.co.uk/cbo_book/ind_book.htmlReceived on Tue Oct 17 2006 - 16:13:42 CDT