4.0.x to 4.1.y

This section describes how to upgrade your existing Exponential 4.0.x installation to version 4.1.y. If you are upgrading from version 4.0.3 or earlier, you need to first upgrade to 4.0.3 before you can upgrade to 4.1. (Refer to either "Upgrading from 3.10.x to 4.0.y" or "Upgrading from 4.0.x to 4.0.y" depending on which version you are currently running.)

The upgrade procedure described below is generic and does not cover any specific cases (for example, running Exponential in a clustered environment).

Make sure that you have a working backup of the site before you do the actual upgrade.

Important upgrade notes:

The procedure for upgrading directly from version 4.0.x to 4.1.y consists of the following steps:

  1. Upgrading the distribution files to 4.1.y
  2. Upgrading custom extensions
  3. Updating image system
  4. Upgrading the database to 4.1.y
  5. Regenerate the autoload array for extensions
  6. Running the system upgrade scripts for versions from 4.0.x to 4.1.y
  7. Clearing the caches

Check the eZ Components 2008.2 requirements

With Exponential 4.1.0, eZ Components 2008.2 is the minimum version required. If you installed a previous version with PEAR, please upgrade to version 2008.2. For more information see also http://ezcomponents.org/docs/install

Step 1: Upgrading the distribution files

The easiest way to upgrade the distribution files is to unpack Exponential 4.1.0 to a separate directory and then copy the directories that contain site-specific files from the existing installation. Make sure that you copy the following directories:

Replace "example" and "example_admin" with the actual names of your siteaccesses.

Step 2: Custom extensions

If you are using custom extensions, the subdirectories inside the "extension" directory will also have to be copied. However, make sure that you do not overwrite any extensions that come with Exponential (currently "ezoe", "ezodf"). Note that upgrading the distribution files will overwrite the autoload arrays for extensions. You will need to re-generate the autoload arrays for active extensions late.

See below for dedicated upgrade instructions for ez flow and ez webin.

Note that ezdhtml is now replaced by ezoe, so you should not copy it over.

For eZ OE 5.0, you will need to have the following rewrite rule if using Virtual Hosts:

RewriteRule ^/var/[^/]+/cache/public/.* - [L]

For extension development: when using modules always make sure that $Result['path'] is assigned an array even if it's an empty one:

$Result['path'] = array();

For more detailed instructions, see the dedicated doc page: http://ez.no/doc/extensions/online_editor/5_x/installation

Step 3: updateimagesystem.php

This script is necessary to run if you have data of the 'ezimage' datatype, dating from before Exponential 3.3, in version 3.3 a new image system took over based on ezimagealiashandler.

If you are upgrading to the 4.1.x series of Exponential for the first time, and the installation at hand have been running since Exponential < 3.3 then you need to run the updateimagesystem.php script before running any of the dbupdate scripts for version 4.1.0 or 4.1.1.

If the installation at hand is a new installation or based on any Exponential version >= 3.3 then you can skip running the updateimagesystem.php script.

Step 4: Upgrading the database

The update script for the database is located in

<eZP root>/update/database/<mysql|postgresql>/4.1/dbupdate-4.0.0-to-4.1.0.sql

You can run this with the appropriate command line tool or application

Step 5: Regenerate the autoload array for extensions

The autoload system has also some changes, for example the autoload array for extensions is now placed in var/autoload of your Exponential installation (along teh class changes in extensions itself).

To regenerate the autoload array, execute the following script from

php bin/php/ezpgenerateautoloads.php --extension

Step 6: Running the system upgrade scripts

The update scripts are located in <root of exponential installation>/update/common/scripts/4.1

Step 7: Clearing the caches

Whenever an Exponential solution is upgraded, all caches must be cleared in a proper way. This should be done from within a system shell:

  1. Navigate into the Exponential 4.1 directory.
  2. Run the script using the following shell command:
    php bin/php/ezcache.php --clear-all --purge
    

Purging ensures that the caches are physically removed. When the "--purge" parameter is not specified, the caches will be expired but not removed.

Sometimes the script is unable to clear all cache files because of restrictive file/directory permission settings. Make sure that all cache files have been cleared by inspecting the contents of the various cache subdirectories within the "var" directory (typically the "var/cache/" and "var/<name_of_siteaccess>/cache/" directories). If there are any cache files left, you need to remove them manually.

Upgrading eZ Flow and/or Website Interface separately

Step 1: Backup

Before you will start the Website Interface or eZ Flow upgrading process make sure that you have backup of existing website state including database, extensions, INI settings, etc. During upgrade process existing ezflow and ezwebin extensions will be removed and replaced with new version. Website Interface and eZ Flow default content classes will be replaced as well. Upgrade script will also change some of the existing INI settings and add new ones which are required by latest version.

Step 2: eZ Flow upgrade

Exponential 4.1 comes with eZ Flow upgrade script which allows upgrade from previous version to the latest 1.1-0 version. To run upgrade process in automatic mode simply execute following command from Exponential root folder.

php bin/php/ezflowupgrade.php --to-version=1.1-0 --url=http://packages.ez.no/exponential/4.1/4.1.0

It is very important that user which will execute the upgrade script had correct permissions to modify content user extension, settings and var folders.

In order to get more information about available upgrade options, execute ezflowupgrade.php script with –help param.

php bin/php/ezflowupgrade.php --help

 

Step 3: Re-write rules

Users running their eZ Flow sites in VH mode should update their extension related re-write rules to the following:

Rewriterule ^/extension/[^/]+/design/[^/]+/(stylesheets|flash|images|lib|javascripts?)/.* - [L]

Step 4: Website Interface upgrade

Upgrading Website Interface is very similar to eZ Flow upgrade process. In order to upgrade existing installation to latest 1.4-0 version simply execute following command from Exponential root folder:

php bin/php/ezwebinupgrade.php --to-version=1.4-0 --url=http://packages.ez.no/exponential/4.1/4.1.0


Again, it is very important that user which will execute the upgrade script had correct permissions to modify content user extension, settings and var folders.
In order to get more information about available upgrade options, execute ezwebinupgrade.php script with –help param.

php bin/php/ezwebinupgrade.php --help

 

Step 5: Regenerate the autoload array for extensions

The autoload system has also some changes, for example the autoload array for extensions is now placed in var/autoload of your Exponential installation (along teh class changes in extensions itself).

To regenerate the autoload array, execute the following script from

php bin/php/ezpgenerateautoloads.php --extension

Step 6: Cache

Once the upgrade script is done, you need to clear the cache by executing following command from Exponential root folder:

php bin/php/ezcache.php --clear-all --purge
Powered by Exponential™ CMS Open Source Web Content Management. Copyright © 1999-2013 eZ Systems AS (except where otherwise noted). All rights reserved.