Re: To estimate maximum active sessions on my oracle database is reasonable to the approach?
Date: Sun, 7 Nov 2021 18:28:19 +0800
Message-ID: <CABpiuuQurosXZXzm4TaDqK8SpO2yLpVvarTfqu4Qu084ZnLFeA_at_mail.gmail.com>
Thanks for your reply, Jonathan π.
Yes, AAS can be equivalent to *sessions* from v$parameter. At this moment I
think the value of AAS is probably equal to *CPU_COUNT* from v$parameter
because sessions are the affordable value for oracle database currently. In
your case I guess that AAS is *8* (CPUs) and background processes are *3*
according to your description because your query count(*) is *11*.
In other words I should go to estimate maximum concurrent connections
(processes from v$parameter), here I assume that my oracle database server
is *DEDICATED* server thus one session represents one foreground process.
Another kind of thought if I am able to estimate one CPU is allowed to run the maximum processes then I'll know all cores of CPUs' maximum processes (maximum concurrent connections on my oracle database server).
Best Regards
Quanwen Zhao
Jonathan Lewis <jlewisoracle_at_gmail.com> δΊ2021εΉ΄11ζ6ζ₯ε¨ε δΈε5:48ειοΌ
>
> AAS can be as large as the sessions parameter (minus some value for the
> background processes). Here's a query and result from an instance running
> on a machine with 8 CPUs.
>
> SQL> select sample_time, count(*) from V$active_session_history where
> sample_time > sysdate - 10/(24*60*60) group by sample_time order by 1;
>
> SAMPLE_TIME COUNT(*)
> -------------------------------- ----------
> 06-NOV-21 09.42.23.785 AM 11
> 06-NOV-21 09.42.24.809 AM 11
> 06-NOV-21 09.42.25.814 AM 11
> 06-NOV-21 09.42.26.817 AM 11
> 06-NOV-21 09.42.27.819 AM 11
> 06-NOV-21 09.42.28.827 AM 11
> 06-NOV-21 09.42.29.830 AM 11
> 06-NOV-21 09.42.30.847 AM 11
> 06-NOV-21 09.42.31.860 AM 11
> 06-NOV-21 09.42.32.869 AM 11
>
> 10 rows selected.
>
>
> A session doesn't have to be "doing" anything to be active, it only has to
> be in the middle of a database call. In this case all the sessions are
> waiting on an attempt to "lock table X in exclusive mode" when the table is
> already locked.
>
> Regards
> Jonathan Lewis.
>
>
> P.S. In case no-one answered: "IMHO" means "in my humble opinion".
>
>
>
>
> On Mon, 1 Nov 2021 at 01:30, Quanwen Zhao <quanwenzhao_at_gmail.com> wrote:
>
>> Concurrent is not matter ACTIVE?
>>
>> The logic cpus is 192 on my oracle database server, so AAS is allowed to
>> increase to 192 because an AAS of 1 is equivalent to 100% of a CPU core.
>> Since AAS has a maximum value I am also able to estimate the maximum
>> concurrent connections using the current concurrent connections by the
>> proportion with current AAS and logic cpus.
>>
>> By the way what's IMHO?
>>
>> Best Regards
>> Quanwen Zhao
>>
>>
>>
-- http://www.freelists.org/webpage/oracle-lReceived on Sun Nov 07 2021 - 11:28:19 CET