How to setup Magento 2 on Mac OsX 10.11

In this blog, I will explain you how to setup Magento 2 on Mac Osx 10.11 by the following steps:

Step 1: Required system

Step 2: Download and install PHP

Step 3: Download composer

 Step 4: Download Magento 2 Packages

Step 5: Install Magento 2

Required system

  • Apache 2.2 or better
  • PHP 5.5.x or 5.6.x
  • MySQL 5.6.x

Download and install PHP

You can utilize the following link to install PHP new version on Max OsX 10.11: https://coolestguidesontheplanet.com/get-apache-mysql-php-and-phpmyadmin-working-on-osx-10-11-el-capitan/

Then setup mcrypt lib: https://coolestguidesontheplanet.com/install-mcrypt-for-php-on-mac-osx-10-10-yosemite-for-a-development-server/

Download composer

You can download it and verify the Composer installation lessons here https://getcomposer.org/

Download Magento 2 Packages

Releases page: https://github.com/magento/magento2/releases.

Install Magento 2

Initially, you contain to unzip magento 2 packages to the directory of the Apache web server. Then follow below mentioned steps:

  1. Install Magento via composer
  • Release the terminal and use the following commands:

composer config repositories.magento composer http://packages.magento.com

composer require magento/sample-data:1.0.0-beta

composer update

  • Download sample data

composer config repositories.magento composer http://packages.magento.com

composer require magento/sample-data:1.0.0-beta

  • Install sample data

<folder_path>/magento setup:upgrade

<folder_path>/magento sampledata:install <your Magento administrator user name>

  1. Install Magento via web interface

Unwrap the Magento 2 URL configured in your web server. Example: http://local-mgt2.com

Select the Agree and Setup button on the welcome page.

 

 

Next page : tap “start readiness check”, the system will verify  your PHP version, permission …

 

When its done, you want to type database access data on the next step

In the Next Page: Set up web setting: administration setting, set HTTPS connection, Apache rewrites and encryption key..

On the next step, you need to manage time zone, currency and language. Don’t fail to remember to decide the “Use Sample Data” choice.

Then type administrator account data configuration

Click next button then wait the installation process until successful

The ending step: open the Magento administration then disable all caches

Analyze magento 2 frontend home page

Tips: Some issues when installing magento 2:

– Cannot install composer:

OpenSSL is old:

You can download home brew to fix this issue: http://brew.sh/

Or download and install manual: http://mac-dev-env.patrickbougie.com/openssl

Missing intl library:

Install PECL, PEAR. Then Enabling CUL: http://budiirawan.com/install-php-intl-extension-os-x/

– Can not choose database when install magento 2:

$HTTP_RAW_POST_DATA is deprecated from PHP 5.6 onwards and will be removed in PHP 7.0

Contain a new line on php.ini file: always_populate_raw_post_data = -1

Or use this line on magento .htaccess file:

php_value always_populate_raw_post_data -1

below:

php_value memory_limit 768M

php_value max_execution_time 18000

I hope the following steps assist you to install PHP and magento 2 on Mac OsX10.11.

Last Update: October 30, 2019  

March 21, 2018   1844   Nandini Ramachandran    Operations    
Total 0 Votes:
0

Tell us how can we improve this post?

+ = Verify Human or Spambot ?

Leave a Reply

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

Facebook
Twitter
INSTAGRAM
LinkedIn