In this tutorial, we will quickly show you how to install Magento on a Centos server.

 

Magento is a widely used CMS (content management system) mainly used in setting up eCommerce or business websites. It is basically an eCommerce software and platform.

 

Magento is highly customizable and there are a wide variety of themes and extensions supported by Magento which can be used to enhance the performance of the websites. Magento supports multiple levels of caching with which the websites can be made to load faster.

 

Magento is coded with PHP and it uses MySQL database management system or its replacements like Percona. It also uses the Zend framework as the Service Manager component. Magento website is highly responsive (supports mobile devices), powerful, supports third-party integrations, highly customizable and versatile.

 

Setting Up Magento On A Linux CentOS LAMP Server

 

Magento requires a Linux server or Linux VPS with LAMP stack for it to work. Since Magento has a lot of in-built utilities and extensions, it requires high memory for full functionality. It is recommended to have at least 2GB RAM for a normal Magento website.

 

This article is based on the assumption that these prerequisites are satisfied.

 

Since Magento requires high PHP memory limit, we’ll increase it in the php.ini (PHP configuration) file. To find the location of php.ini file, do:

php -i | grep php.ini

 

This will give an output similar to:

Configuration File (php.ini) Path => /etc
Loaded Configuration File => /etc/php.ini

 

In this case, /etc/php.ini is the loaded configuration file and we need to make the changes there.

 

Open the said file and edit;

memory_limit = 512M

 

Magento also requires PHP mcrypt package, so you need to install it as well.

 

We need to enable REMI and EPEL repos to install php-mcrypt.

 

Download the repo rpms. and install it to configure the repos.

wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
sudo rpm -Uvh remi-release-6*.rpm epel-release-6*.rpm

 

After configuring the REMI and EPEL repos, update yum repos

yum update

 

Then install PHP mcrypt package.

yum install php-mcrypt*

 

Now, restart Apache. and the new value should be in place.

/etc/init.d/httpd restart

 

Now, we can proceed with the installation of Magento.

 

First, we need to download the Magento package in the Document Root of the website/domain. The domain in this tutorial is ‘domain.com’ and the Document Root is ‘/home/test/public_html’.

 

So we need to change the working directory to the Document Root.

cd /home/test/public_html

 

Now, download the Magento package.

wget http://www.magentocommerce.com/downloads/assets/1.9.0.1/magento-1.9.0.1.zip

 

The downloaded package is a zip archive. We need to unzip it into the Document root of the domain.

unzip magento*.zip

cp -rf magento/* /home/test/public_html

 

Now the Magento contents are copied in the Document Root.

 

Magento website needs a database to hold the data. So we need to create a MySQL database and a MySQL user who has the privilege to access that data.

 

Enter into MySQL prompt

mysql

 

We are now in the MySQL prompt. Create a database named ‘magento’.

mysql> CREATE DATABASE magento;

 

Create a MySQL ‘mageuser ‘ user who can access the database ‘magento’

mysql> CREATE USER mageuser@localhost;

 

Grant permissions for the MySQL user to access the database ‘magento’

mysql> GRANT ALL ON magento.* TO mageuser@localhost IDENTIFIED BY ‘your_password’;

 

You can configure your Magento website and admin panel from the frontend. Here is how to do this.

 

1. Load your website (http://domain.com) in a web browser. It will load the Magento Installation Wizard.

 

2. Accept the License agreement and continue. This will lead us to the Localization page.

 

3. Specify the Locale settings, Time Zone and Default Currency, COntinue to next page. Then comes the database configuration page.

 

4. This is what we created the MySQL database and the privileged MySQL user. Just enter those credentials and continue to Admin account creation page.

 

5. In this page, we need to provide Personal Information, Login Infomation and Encryption key. Then, continue to the next page.

 

6. Magento setup is almost complete. We just have to enter a few questions regarding the business type and then YOU ARE SET!

 

7. This will take you to the Frontend (Website) or Backend (Dashboard) as you choose.

 

8. You can start building your website and the Magento Admin URL by default is http://domain.com/index.php/admin.

Răspunsul a fost util? 0 utilizatori au considerat informația utilă (0 Voturi)