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: Is it better to set the freelist to a prime number ?

Re: Is it better to set the freelist to a prime number ?

From: Jonathan Lewis <jonathan_at_jlcomp.demon.co.uk>
Date: Wed, 24 Jul 2002 17:15:47 +0100
Message-ID: <1027527266.26626.0.nnrp-01.9e984b29@news.demon.co.uk>

Now there's an interesting point.

Unless I missed something, I was thinking that the PID referenced was v$process.pid (the Oracle process id) whereas you seem to be suggesting that it is v$process.spid (the operating system process id). Do you want to do the test, or shall I ? I have a free slot some time next March ;)

(Note too, that your argument would only require an ODD number of freelists, not
a prime number).

I agree with your comment about pattern
avoidance, though.

--
Jonathan Lewis
http://www.jlcomp.demon.co.uk

Next Seminars
 UK  Sept
 Australia August
 Malaysia September
 USA x 2  November

http://www.jlcomp.demon.co.uk/seminar.html

Andrew Mobbs wrote in message ...

>Jonathan Lewis <jonathan_at_jlcomp.demon.co.uk> wrote:
>>
>>Thanks for the reference, which I've followed up.
>>Suddenly it's all clear.
>>
>>It makes no difference whether the value is prime
>>or not. The significance appears I think when you
>>use multiple free lists AND multiple freelist groups
>>in a single instance.
>>
>>In this case, the number of freelists and the number
>>of freelist groups must be relatively prime (co-prime ?)
>>or you don't make use of all the freelists in all the
>>freelist blocks.
>
>Not quite, it still can make a difference in some cases. For example,
>if there's some characteristic of your environment that makes the PID
>non-random.
>
>Say I start up a batch job that runs as 64 parallel processes on the same
>system as the database server is running. Each batch job has an Oracle
>shadow process. It's quite likely (on some OSes) to have the application
>and shadow processes interleaved, i.e. all the application processes to
>end up with an odd PID, and all the Oracle shadow processes to end up
>with an even PID (or vice-versa). There's an example of something very
>similar on my other terminal about two feet away :-)
>
>If you had a even number of freelists, you'd only end up using half
>the freelists.
>
>PIDs have no guarantees about their numerical properties, so may well
>fall into a pattern (possibly one more complex than just all being
>even). Primes have the greatest resistance to matching a pattern.
>
>--
>Andrew Mobbs - http://www.chiark.greenend.org.uk/~andrewm/
Received on Wed Jul 24 2002 - 11:15:47 CDT

Original text of this message

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