Share » Learn » eZ Publish » eZ Publish: Performance Best Practices

eZ Publish: Performance Best Practices

Friday 28 April 2006 1:10:00 am

  • Currently 3 out of 5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Performance is influenced both by the software and development stack and the hardware architecture. Weaknesses in any of these components will impact performance, no matter how well the other components perform.

Your ability to manage the software stack and the hardware architecture will, of course, depend on your site hosting arrangements. The following section describes platform considerations that should be discussed with your system administrator or hosting partner. By having complete information about the environment where your site will be running, you will be able to anticipate and resolve problems before going live.

Hosting architecture

To determine the environment in which you'll be working, you should ask your system administrator or hosting partner the following questions:

  • Do you have a dedicated or shared web hosting platform?
  • What access method do you have: SSH, FTP, SFTP?
  • What access rights will you be given: end user, root?

If your project requires load balancing, infrastructure is "critical path." Various load balancing configurations can be created depending on the project requirements. Consult an experienced systems engineer for assistance. Articles about load balancing are available in the community section of the ez.no site. For additional assistance, eZ systems' experts have extensive experience with setting up high-availability platforms for eZ Publish.

Software versions and availability

The versions and interrelationships between software in the stack are critical to performance.

Apache version

If you're running Apache version 2, note that some PHP extensions are not fully threadsafe. If at all possible, you should run Apache 1.x. If you must run Apache 2, be sure to run it under pre-fork mode, which prevents Apache 2 from using threads.

PHP version

eZ Publish requires PHP 4.3.x for the 3.6 branch, PHP 4.4.x for the 3.7+ branch, and does not run at all on PHP 5.x. Regarding web server integration, SAPI is supported but CGI won't work correctly due to information required by eZ Publish that is not transmitted by CGI. ( FastCGI will be implemented in eZ Publish 4.x as a replacement for CGI.)

PHP configuration

Check the following PHP settings: Max execution time and memory limit should be set high enough (more than 64 MB is recommended for memory limit). Safe mode should always be disabled, as it is too restrictive for eZ Publish. If possible, memory limit should be disabled as it has a small performance impact.

opcode cache

An opcode cache is strongly recommended when working with eZ Publish. opcode cache stores the result of the PHP interpreter in shared memory, thus avoiding the task of parsing the scripts again the next time the same files are requested. opcode is recommended for most PHP applications. Since some eZ Publish scripts are quite large, opcode caching has a tremendous effect on performance. APC and eAccelerator are the recommended opcode implementations; they should be allocated sufficient shared memory to be effective.

Software architecture tips and tricks

The command-line version of PHP is required in order to run cronjobs and maintenance scripts. Since this is often not installed on production servers, make sure that this component is compiled and has the same parameters as the PHP version used by the web server.

If you need advanced multilingual support, you must be using MySQL version 4.1.x or greater to benefit from Unicode storage.

Depending on the eZ Publish installation location, you may have to alter DNS configuration to access the site via the desired URLs. Even if DNS modification is not required, mod_rewrite must be enabled on the server, and ideally configured in the website's virtual host.

An image conversion package must be available on the server. eZ Publish can use ImageMagick or GD (ImageMagick is recommended). If the image conversion tool is configured differently on the production server, you must change the image conversion settings.

36 542 Users on board!

Tutorial menu

Printable

Printer Friendly version of the full article on one page with plain styles

Author(s)