Categories
LAMP

Install LAMP Server Easily using command line

Hello Linux Lovers! The acronym LAMP is derived from first letters of Linux, Apache HTTP Server, Database MySQL, and Language PHP, Perl or Python. We already have shown you how to install LAMP on many platforms. So we can say that LAMP is a combination of operating system and open-source software stack. Lets start the LAMP setup procedure:

1. To install LAMP run the below command:

sudo apt-get install lamp-server^

2. Run the following commands to setup user for your apache server, add permission & enable some modules:

sudo usermod -a -G www-data YOUR_USER_NAME

sudo chgrp -R www-data /var/www

sudo chmod -R g+w /var/www

sudo apt-get install php5-curl

sudo a2enmod rewrite

3. Restart the apache server:

sudo /etc/init.d/apache2 restart

4. We will open the /etc/apache2/apache2.conf file in text editor to enable rewrite options. Run the below command:

sudo gedit /etc/apache2/apache2.conf

and modify the below snap of script.

Share with: