How To Setup a LAMP Server on Debian Linux 8 (Jessie)

A LAMP server is a web server that uses the Linux operating system, Apache web server software, MySQL database management system, and PHP scripting language.

To set up a LAMP server on Debian Linux 8 (Jessie), follow these steps:

  1. Install Apache web server:
sudo apt-get install apache2
  1. Install MySQL database:
sudo apt-get install mysql-server
  1. Install PHP:
sudo apt-get install php5 libapache2-mod-php5
  1. Restart Apache to enable PHP:
sudo service apache2 restart
  1. Test the LAMP server by creating a test PHP file at /var/www/html/info.php:
sudo nano /var/www/html/info.php

Add the following content to the file:

<?php
phpinfo();
?>
  1. Access the test file from a web browser:
http://server-ip-address/info.php

If the LAMP server is set up correctly, you will see the PHP information page displayed in your browser.

Note: You may need to configure the firewall and Apache settings to allow external access to the server, and secure the MySQL installation by setting a root password and removing default user accounts.

Leave a Comment