Share » Learn » eZ Publish » The eZ publish Web Server Environment

The eZ publish Web Server Environment

Friday 04 August 2006 1:41:00 pm

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

This article describes the optimal eZ publish operating environment. It provides instructions for installing and configuring Apache, PHP and APC (Alternative PHP Cache). The article assumes that you are running Linux in both your development and production environments, as Linux provides the best performance and stability for an eZ publish installation.

The web server environment

The web server environment includes the operating system and third-party applications that eZ publish requires in order to run. In addition to an operating system (preferably Linux), eZ publish requires the following components:

  • Apache web server
  • PHP
  • Alternative PHP Cache (APC)
  • ImageMagick or GD

One or more of these components may already be installed on your Linux server. Before building and installing the components as described below, check for previously installed versions.

Request model on the server side

This diagram shows the process by which URL requests are handled by an eZ publish server:

Database

eZ publish content objects are stored in a database. While eZ publish can use MySQL, PostgreSQL or Oracle, MySQL is the preferred database for optimal performance. MySQL can either be installed on the same server as eZ publish or on another server. When running eZ publish in a clustered environment (that is, load balanced over multiple web servers) we recommend that you run a Squid reverse proxy cache in front of eZ publish.

Installing and configuring MySQL will be the topic of an upcoming article. For general instructions, refer to the documentation.

Intel ICC compiler

The Intel ICC Compiler automatically optimizes and parallelizes code to take best advantage of Intel processors. You can get better performance results with Apache, PHP and APC if they are compiled for Intel processors with ICC.

The Intel ICC Compiler for Linux is proprietary software and requires a valid license . For more information and for trial versions, refer to http://www.intel.com/software/products/compilers/clin/. Refer to the INSTALL file included with the distribution for installation instructions.

To compile Apache, PHP and APC with ICC (as described in the following sections), you must export the CC environment variable:

shell> export CC=/opt/intel/cc/9.0/bin/icc

Before you run the configure script, make sure that the CC variable is exported correctly. Be sure that you remove any config.cache files before running configure, and run make clean after configuring before compiling.

ICC results

We compared the results of compiling Apache, PHP and APC with the ICC compiler versus compiling with the GNU C Compiler (GCC). All tests were done with 50 000 articles in the database. The test case was listing a folder with 5 000 articles sorted by publishing time, displaying ten articles at a time. MySQL was configured with a read cache in this configuration, and was only taking 1.5% of the processing time. Therefore, most of the time was used for PHP processing on the web server.

The tests were done with three configurations

  1. Template compilation and view cache disabled
  2. Template compilation enabled and view cache disabled
  3. Template compilation enabled and view cache enabled
  Case 1 Case 2 Case 3
GCC template total 0.9589 seconds 0.5147 seconds 0.0480 seconds
ICC template total 0.7713 seconds 0.4184 seconds 0.0396 seconds
Template difference 19.57% 18.72% 17.39%
GCC pageviews 2.760 4.79 33.24
ICC pageviews 3.15 5.33 35.33
Page difference 12.73% 11.32% 6.28%

We see that the performance gain in the template processing is quite good, up to almost 20%. The performance increase in the pageview is almost 13% faster; this indicates that the more processing the page requires, the bigger the performance improvement gained by using the ICC compiler. The total increase in performance measured with actual pageviews, including transfer from server to client is faster regardless of the page size, but it is especially noticeable when cache is disabled (which requires more serverside processing).

36 542 Users on board!

Tutorial menu

Printable

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

Author(s)