Magento is an increasingly popular e-commerce platform due to its sheer flexibility, wide range of features and the facility to customise it relatively easily. In this post we will examine how to get Magento Enterprise set up and running. We assume a debian-based LAMP stack but these instructions could be adapted for any other platform as required.

Installing ionCube

Magento uses ionCube to encode some of the files for the Enterprise edition since version 1.8, so an ionCube ‘loader’ plugin is required for some elements of the Enterprise version to load. The plugin required depends on the server system you are using, and the version of PHP you have available; visit and find the appropriate package to download. Use “Copy link location” so that you may use the resulting address directly on the command line with wget rather than downloading the file to your own machine and uploading again.

The next step is to extract the plugin and make it available for PHP, for this example the correct package is ioncube_loaders_lin_x86.tar.gz:

Enable the correct plugin for your version of PHP, so for example if you are using PHP version 5.2.x then use the following code, then restart apache.

You can check that the IonCube loader plugin is working by running php -v; you should get output that looks something like this:

Installing Magento

You need to obtain a Magento tarball and copy it to the server. The Magento Enterprise edition is not freely available, and so you must obtain a copy as per your Magento licence. The first step is to extract the Magento tarball and move the files into the directory where you will be running Magento. This varies from set-up to set-up, but we will use /var/www as an example.

This will untar Magento into a folder named after the version you are using, so for example if you are using it will be extracted to These files need to be moved to where the webserver will pick them up:

The ownership and permissions need to be changed according to your webserver group set-up and Magento’s requirements. In the following, exchange www-data for the group your Apache server runs under. You can find this by executing ‘grep APACHE_RUN_GROUP /etc/apache2/envvars’ from the command prompt and observing the output.

All other files should be owned by a non-apache user, and permissions should be set according to the file purpose (755 for directories and executable files, and 644 for non-executable files).

Set up Database Schema

The next step is to set up a database schema for Magento to create its tables under, so we first create the database and create a specific user which Magento will use for accessing the database:

The database name, username and password you set up are up to you. However, for the most secure set-up you should restrict the host to the server you will be running Magento from; for a situation where the database and web server are on the same machine, you can simply give the host as ‘localhost';

Apache Config

Next we need to point the webserver at the installation. Create a virtual host for this site in /etc/apache2/sites-available and add the following code, setting the domain name and web root appropriately:

Now enable the site:

And finally reload Apache:

You should now be able to go to your domain address and be presented with the Magento installation screen. This will ask you to input the Magento database details you set up previously, as well as choose an administration username and password – and you are ready to go!

Although there are a few steps needed to set up this application, in particular the ionCube loader, I hope that this shows an easy way to make sure you have all you need to use the application.