Learn How To Setup Magento on CentOS 6

March 9, 2020

Table of Contents

https://www.itweb.services/tutorials/linux-guides/installing-magento-2-on-ubuntu”>Ubuntu are in a separate article. Magento uses a large amount of memory, you will need at least a 1GB IT Web Services instance.

Step 1: Installing your web server

https://www.itweb.services/tutorials/linux-guides/how-to-install-apache-mysql-and-php-on-centos-6″>this article.

Step 2: Configuring the web server

Assuming you have Apache installed properly, you should be able to open up your text editor to /etc/httpd/conf.d/magento.conf.

Do this by using your favorite text editor (in this case, nano).

nano /etc/httpd/conf.d/magento.conf

Paste the following into the file:

NameVirtualHost *:80 
<VirtualHost *:80>
    ServerName yourmagentowebsite.com
    DocumentRoot /var/www/yourmagentowebsite.com

Save and close the file.
Create the directory:

mkdir /var/www/yourmagentowebsite.com

Now, we need to install some core PHP packages for Magento.

yum install php-mcrypt php-curl php-gd curl-devel php-intl php-xsl

Finally, restart Apache:

service httpd restart

Step 3: Installing Magento

We need the Magento files, so we will get them from https://www.magentocommerce.com/download.

Pick the “tar.gz” archive, and complete the necessary steps to download it.

Using a free SFTP client, such as FileZilla, open a connection to your server and upload the Magento tar.gz archive to your /var/www/yourmagentowebsite.com directory.

Go back to your SSH prompt and enter the following:

cd /var/www/yourmagentowebsite.com
tar -xvf Magento-CE-xxxxx.tar.gz

Now that we have the files we need in place, let’s setup MySQL. Execute the following to create a database:

mysql -uroot -pyourpasswordgoeshere
create database magento;

Good job. Now, head over to your web browser and type in your server’s IP address. With your database details, fill in the configuration page to complete the installation.

Your Magento server is ready for use. You may create products, manage payment gateways, and so forth.

Need help?

Do you need help setting up this on your own service?
Please contact us and we’ll provide you the best possible quote!