Warning: Use of undefined constant HTTP_USER_AGENT - assumed 'HTTP_USER_AGENT' (this will throw an Error in a future version of PHP) in /var/www/html/linuxbyimraan.co.za/wp-content/themes/voice-blog/header.php on line 1
Magento explained plus commands for an easy install on Ubuntu 16.04 – LinuxByImraan

Magento explained plus commands for an easy install on Ubuntu 16.04

What is Magento and why do companies install it:

Magento is an ecommerce platform built on open source technology which provides online merchants with a flexible shopping cart system, as well as control over the look, content and functionality of their online store. Magento offers powerful marketing, search engine optimization, and catalog-management tools. We believe that Magento is one of the best ecommerce platforms available today, with editions ranging from community open source, to massive, large-scale enterprise SaaS based systems.

Magento is designed to be utilized as an application by someone who isn’t a developer. The Magento community is extremely large and very helpful. However, at some point the average person is going to hit a wall.

There are a number of reasons why developers are called upon to adjust a Magento website. It is a very robust system even at its most basic, more so even than a Drupal site (and Drupal is no lightweight). Once you begin to integrate with other systems, or introduce tens of thousands of products, businesses often need the assistance of experienced developers. As an example, we’ve had clients need additional options for how they view their dashboard. Typically you might be able to select viewing products in groups of 5, 25, and/or 50. We have a client who wants to view 2000. The functionality can be changed only up to a point; beyond that, it needs to be customized by an expert who really understands Magento, and follows best practices.

Benefits of using Magento:

-Easy to install and add additional layouts and plug-ins
-Open source technology that offers flexible, scalable ecommerce solutions
-Effective and cost sensitive program
-Allows for various discounts and promotions during check-out
-Provides more than 50 payment gateways

Commands to install Magento2 on Ubuntu 16.04:

$ sudo su (Best to be root)

$ apt-get update

$ apt-get install apache2 php libapache2-mod-php mysql-server php-mysql php-dom php-simplexml php-curl php-intl php-xsl php-mbstring php-zip php-xml composer
apt-get install php7.0-gd

$ apt-get install php7.0-mcrypt

$ sudo a2enmod rewrite

$ service apache2 restart

$ cd /etc/apache2/

Edit the Apache2.conf file:

$ vi apache2.conf
Here you will need to change allowOverride from none to all:

Options Indexes FollowSymLinks
AllowOverride all
Require all granted

$ systemctl restart apache2.service

$ cd /var/www/html/

$ git clone https://github.com/magento/magento2.git

Navigate to Magento2:

$ cd magento2/

$ composer install

## If you are requested to install later versions of php, extensions, you can use the following command followed by the extension name:
sudo apt install php7.2-(extension)

Lastly, apply the correct permissions for the Magento2 folders:

$chmod -R 755 /var/www/html/magento2/
$chmod -R 777 /var/www/html/magento2/var/
$chmod -R 777 /var/www/html/magento2/pub/
$chmod -R 777 /var/www/html/magento2/app/etc/
$chmod -R 777 /var/www/html/magento2/generated/

Once you have set the above permissions, copy and paste the ip of your server into a browser followed by the following /mangento2/setup/:

and that’s it.

Simple and easy to install….

No token or token has expired.


Hansie Slim
24th Oct 2018 at 7:20 am

Really good guide, easy to follow – keep up the good work

Leave a Reply

Your email address will not be published. Required fields are marked *