Install Magento 2 in Ubuntu

Muhammad Ali
5 min readMar 13, 2019

--

Magento! A CMS build using PHP at backend. Why this is so popular? Cause it an eCommerce what you find in all top 5 CMS eCommerce list. It is really good for user & seller but this is not good for developer to develop (personal opinion). I had lots of issues to install it and developing its module. Today I am going to share how anyone can install Magento in Ubuntu.

Pre-Installing Steps

  1. Search “magento” in google
Google Search Result

2. From Result go to “Tech Resource” and click download

Tech Resource Page Of Magento Official Site

3. There are two types of magento, with sample data & without sample data. Download whatever you like.

WithSample Data & Without Sample Data

4. Select the format you want to download, in my case I downloaded zip.

Downloaded The zip Version

5. Need login to download. If you don’t have account, create one

Download Need Login

6. After downloading, exact the folder in computer / var / www / html / <project name>

Project Directory

Installing steps

Now in browser type localhost to access the folder

Accessing Magento Tutorial Folder

Click in the <project name>

Project Front Page

There are 6 steps to complete the install. They are —

Step 1

Click Start Readiness Check

1st Step Readiness Check

If all are complete then click next.

Step 2

A database is needed for this

Create a mysql database name of your desire

Creating mysql Database For Magento

Give the details of server host, server username, server password, database name & table prefix (only optional)

Setup The Details In Magento

If all done, then click next to continue

Step 3

Setup your store address or what you wanna be the index page. Setup Magento Admin address for browsing admin

Web Configuration Of Magento

If all done, then click next to continue

Step 4

Set a time zone first, Set a currency & Finally set default language for the shop

Customize Store Details

If all done, then click next to see what’s next

Step 5

Need to create a admin account to access admin dashboard

Creating Admin Account

If all done, then click next & please write down the admin password somewhere because you need to use alphanumeric for creating password.

Step 6

Now wait to complete, sometimes it’s gonna take a long time. For me it takes around 5 mins.

Process Of Install

Success

You will see a success page if all are okay.

Finally The Most Waited Success Page

Admin Panel

Now you can access admin panel using localhost / <project_name> / <admin_url>

Admin Login Page

After login you will see a message about indexers. Don’t warry. I’ve a solution for it. You just need to run “sudo php bin/magento indexer:reindex

Indexer problem? What is that ?
Oh! Easy Solution for Indexer problem

Now refresh. You’ll find another error msg, Magento is asking for cache management problem. Click on the cache management and Select all cache.

Another Problem ?? Oh! Got Solution also. (Cache Management)

Select Refresh in dropdown and Click submit to refresh the cache.

Now another step left to run . We need to Flush Magento Cache. Just click Flush Magento Cache it will flush all cache for us.

Flush Magento Cache

Home Page

Now we can go to see the homepage using “localhost/<project_name>

Home Page Of Magento

Commands

Indexer

sudo php bin/magento indexer:reindex

Cache Management Cache Clean

sudo php bin/magento c:c

Cache Flush

sudo php bin/magento c:f

Some Screenshots

Some Screenshot Of Magento

This is how you can install a magento in your ubuntu machine. I’ve downloaded magento 2.1 for this tutorial. Magento Documentation is good but it is not that easy to pick. Magento is a bit slow if you don’t know how to code properly. If any problem, comment out anytime I’ll try to help.

--

--

Muhammad Ali
Muhammad Ali

Written by Muhammad Ali

An otaku who loves computer. Love to write and help others through my work. Have a look on my Instagram https://www.instagram.com/nerd_jfpb/

No responses yet