Cache handling is making NAS systems slow

Author Message

Tony Wood

Sunday 01 June 2003 6:01:55 am

A couple of issues really.

The '/' in content settings is ignored when you set in '[ContentSettings]'

So if you put CacheDir=/var/cache/sitename/content the system removes the first '/'.
Normally this would not be a problem, but when you main site is on an external RAID array you want all your disk intensive files to to local say in /var/cache. ln -s is a way round this problem and works, but really it should be a ini command.

Another thing that is noticable is that content is the only element addressed by CachDir, really this ini setting should affect 'ini' 'template' and 'template-block'.

I also notice that template-block is only created once and not for every server instance of eZpublish. This means that template block can only exist on a single datasource.

btw Database on muliple servers work well, its just the cache files that slows things down a bit.

Comments please

Tony

Tony Wood : twitter.com/tonywood
Vision with Technology
Experts in eZ Publish consulting & development

Power to the Editor!

Free eZ Training : http://www.VisionWT.com/training
eZ Future Podcast : http://www.VisionWT.com/eZ-Future

Bård Farstad

Monday 02 June 2003 4:11:00 am

Tony,

I agree on your comments. All these issues should be fixed. eZ publish should be able to have the var/ folder placed anywhere on the filesystem.

Cache block should automatically use the siteaccess to create cache files, so they would be unique pr siteaccess.

--bård

Documentation: http://ez.no/doc

Tony Wood

Monday 02 June 2003 4:21:07 am

Thanks,

Will these make it into 3.1? I hope so :) as NFS is around 100 times slower than direct access and GFS is too pricey.

tia

tony

Tony Wood : twitter.com/tonywood
Vision with Technology
Experts in eZ Publish consulting & development

Power to the Editor!

Free eZ Training : http://www.VisionWT.com/training
eZ Future Podcast : http://www.VisionWT.com/eZ-Future

Bård Farstad

Tuesday 03 June 2003 2:58:41 am

I've just commited a fix which enables CacheDir to be set absolute. All cache directories are then created in the desired folder, except ini cache. There is a problem with circular dependencies if we want to read from the ini file where the ini cache is beeing saved.

--bård

Documentation: http://ez.no/doc

Tony Wood

Tuesday 03 June 2003 3:40:13 am

Thanks :)

Does this mean that template-block will also be created in the CacheDir? Will this mean that if two machines are connected to a central data store on NAS the cache files will be created on both machine in /var/cache. (or the like). Meaning that template, template-block etc are created locally on both machines.

Tony Wood : twitter.com/tonywood
Vision with Technology
Experts in eZ Publish consulting & development

Power to the Editor!

Free eZ Training : http://www.VisionWT.com/training
eZ Future Podcast : http://www.VisionWT.com/eZ-Future

Bård Farstad

Tuesday 03 June 2003 5:01:47 am

Yes, template cache files are created locally ( if that's your setup ). This means a bit more overhead in cache creation, but the speed improvements in cached views is worth it.

We use a rsynct script at ez.no which syncs the files between the machines ( uploaded files etc.. ). With this setup you don't need to use NFS and friends. Mabye that's a solution for your NFS speed issues?

--bård

Documentation: http://ez.no/doc

Tony Wood

Tuesday 03 June 2003 5:24:46 am

Thanks,

Let me have a go with the new code and see where it gets me, I have moved NFS from 100 to a 1000 network card so is running a little faster. I'll take a look at rsync too, I need something pretty generic so it can work easily on all sites.

I'll report back.

Thanks again

tony

Tony Wood : twitter.com/tonywood
Vision with Technology
Experts in eZ Publish consulting & development

Power to the Editor!

Free eZ Training : http://www.VisionWT.com/training
eZ Future Podcast : http://www.VisionWT.com/eZ-Future

Gabriel Ambuehl

Tuesday 03 June 2003 10:15:10 am

Just how is GFS pricey if there's even a GPL edition of it, OpenGFS?

Visit http://triligon.org

Tony Wood

Tuesday 03 June 2003 11:12:32 am

Its more than i can justify, here an article on it http://www.hoise.com/primeur/02/articles/monthly/AE-PR-12-02-39.html

Tony Wood : twitter.com/tonywood
Vision with Technology
Experts in eZ Publish consulting & development

Power to the Editor!

Free eZ Training : http://www.VisionWT.com/training
eZ Future Podcast : http://www.VisionWT.com/eZ-Future

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 16:17:07
Script start
Timing: Jan 18 2025 16:17:07
Module start 'layout'
Timing: Jan 18 2025 16:17:07
Module start 'content'
Timing: Jan 18 2025 16:17:08
Module end 'content'
Timing: Jan 18 2025 16:17:08
Script end

Main resources:

Total runtime0.6924 sec
Peak memory usage4,096.0000 KB
Database Queries77

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0049 589.1641152.6406
Module start 'layout' 0.00490.0025 741.804739.4766
Module start 'content' 0.00740.6839 781.2813649.6406
Module end 'content' 0.69140.0011 1,430.921924.1250
Script end 0.6924  1,455.0469 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00310.4523160.0002
Check MTime0.00130.1927160.0001
Mysql Total
Database connection0.00070.103510.0007
Mysqli_queries0.621889.8030770.0081
Looping result0.00070.0953750.0000
Template Total0.663295.820.3316
Template load0.00220.323420.0011
Template processing0.661095.452520.3305
Template load and register function0.00010.011010.0001
states
state_id_array0.00110.155410.0011
state_identifier_array0.00070.104720.0004
Override
Cache load0.00200.2881500.0000
Sytem overhead
Fetch class attribute can translate value0.00060.082930.0002
Fetch class attribute name0.00210.3090110.0002
XML
Image XML parsing0.00090.124430.0003
class_abstraction
Instantiating content class attribute0.00010.0079170.0000
General
dbfile0.00080.1204230.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
8content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
9content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
10content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 30
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs