How to Install and Configure Magento on Ubuntu 16.04

I installed everything in this tutorial:

and i want to install Magento on my droplet which as title indicate is Ubuntu 16.04

but i got stuck on this tutorial in php settings section:

so if anyone knows how to do it … please help me

7  mysql_secure_installation
8  mysql -u root -p
9  cd /var/www/public_html/

12 wget 15 tar xzvf Magento-CE-2.2.2_sample_data-2017-12-11-09-37-31.tar.gz 18 chown -R www-data:www-data /var/www/public_html/ 22 apt-get update 25 apt-get install php7.0-dom 29 apt-get install php7.0-soap 30 /etc/init.d/apache2 reload 31 apt-get install php7.0-intl 32 apt-get install php7.0-mbstring 33 vi /etc/php/7.0/apache2/php.ini 34 apt-get install php7.0-zip 35 /etc/init.d/apache2 reload

Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Hi there Please be careful with your Droplet memory specification before installing Magento on your vps. I have blown away my server because of not enough memory. Install Magento on at leat 4 GB server. In addition to that, be carefuı with the cron jobs. You should configure those also. Don’t be such a novice like me.

I have added my writeup on github, i am now running magento 2.2 on ubuntu 16.04 LAMP stack.


For example, test directory contains two directory A and B and test.php file. So we have to exclude B directory but i need all the files from test directoryexcept B directory.

Kindly help me anyone, how to use nfs.

Hi ,

Could you please any one help me, how to exclude the var directory from magento nfs share.

Great it’s really working but I’m having some problems with downloading the Magento using wget


I’m pretty sure Ubuntu 16.04 comes with PHP 7.0, so that means you have to look for the configuration file in /etc/php/7.0/apache2/php.ini

And then change the following from php5 to:

sudo apt-get update
sudo apt-get install php7.0-curl php7.0-gd php7.0-mcrypt

That should cover everything, but if you run into problem, just write back - please include error messages or where you got stuck.