eZ and Oracle RAC

Author Message

Christophe MAILLARD

Tuesday 07 June 2011 6:40:50 am

Hello,
We use eZ Publish with an oracle RAC cluster.
By load testing, we found that for every page loaded a session was opened by Oracle.
Thus, if 10,000 different pages are accessed, we have 10000 open sessions on Oracle.
This configuration does not seem optimal, as soon as our test load exceeds 10000 pages or 15000, we have a timeout.
Do you have any recommendations?

Thanks

Christophe

Robin Muilwijk

Saturday 18 June 2011 12:36:00 pm

Hi Christophe,

I'll ping someone that I think has experience with using eZ on Oracle. In the mean time, could you post here which eZ version you are using, maybe some basic information on the setup in general (infrastructure in short) and also the Oracle version? That might help help in answering your question.

Thanks and regards, Robin

Board member, eZ Publish Community Project Board - Member of the share.ez.no team - Key values: Openness and Innovation.

LinkedIn: http://nl.linkedin.com/in/robinmuilwijk // Twitter: http://twitter.com/i_robin // Skype: robin.muilwijk

Gaetano Giunta

Sunday 19 June 2011 3:24:54 pm

Hi

By default, eZ opens a database connection per page. As soon as the page is done, the connection is closed (ie: connections are not persistent).

You can change the configuration to have eZ use persistent databaseconnections. This way the same connection can be reused by page B after page A has finished.

Please note that in general using persistent connections has a bit of the opposite effect of what you want to achieve here (reduce the number of connections opened to the db at the same time), as if you have 1000 concurrent apache processes serving a page at the same time, what you get is 1000 db connections that will persist, ie. stay open for a while. At least in non-persistent mode they will be closed very quickly.

Do note also that this is not by design of eZ Publish: this is the way that php works (ie. there is not a real db connection pool that can be managed in explicit ways).

To limit the number of db connections, it is recommended to lower the number of Apache processes that can be active at any given time (MaxClients in httpd.conf). There are good chances that with 10000 running Apache processes your webserver is swapping heavily anyway ( since eZP uses 10MB of ram per page in the best case scenario, 10000 pages being served means 100GB ram installed on the server plus space for OS and buffers/cache). And the swapping can be the real cause for slowness, rather than problems with the db.

Last but not least, two things you can do to tune oracle for a massive number of connections:

- use the MTS server config (old school trick)

- use the DRCP config (only if you have an oracle 11db)

both of those are done in oracle configuration (server-side or client-side), they do not involve changes in eZP

Principal Consultant International Business
Member of the Community Project Board

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 02:10:09
Script start
Timing: Jan 18 2025 02:10:09
Module start 'layout'
Timing: Jan 18 2025 02:10:09
Module start 'content'
Timing: Jan 18 2025 02:10:10
Module end 'content'
Timing: Jan 18 2025 02:10:10
Script end

Main resources:

Total runtime0.7850 sec
Peak memory usage4,096.0000 KB
Database Queries59

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0066 587.8203152.6094
Module start 'layout' 0.00660.0027 740.429739.4219
Module start 'content' 0.00930.7744 779.8516586.0625
Module end 'content' 0.78370.0013 1,365.914112.1875
Script end 0.7850  1,378.1016 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00320.4027160.0002
Check MTime0.00130.1665160.0001
Mysql Total
Database connection0.00140.172210.0014
Mysqli_queries0.731393.1537590.0124
Looping result0.00050.0667570.0000
Template Total0.755796.320.3779
Template load0.00250.322120.0013
Template processing0.753295.947320.3766
Template load and register function0.00020.021010.0002
states
state_id_array0.00070.083810.0007
state_identifier_array0.00110.144320.0006
Override
Cache load0.00210.2640280.0001
Sytem overhead
Fetch class attribute can translate value0.00050.060030.0002
Fetch class attribute name0.00100.129350.0002
XML
Image XML parsing0.00130.171030.0004
class_abstraction
Instantiating content class attribute0.00000.001250.0000
General
dbfile0.00100.1271240.0000
String conversion0.00000.001040.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
3content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
3content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 11
 Number of unique templates used: 6

Time used to render debug report: 0.0002 secs