Debian – Basic LAMP

15-Light-Bulb-iconSetup a basic LAMP, enables you to host cool web applications. LAMP is Linux, Apache, MySQL & PHP (guess Perl or Python should qualify as well). I assume you have done at least a minimal Debian installation here.


Update & upgrade

First we make sure our packages is updated and upgraded if necessary.
apt-get update && apt-get upgrade

Install Apache2

apt-get install apache2
Type in your ip in the browser to check if it is working. If the browser tell you “It is working” it is working 😉

Install MySQL

apt-get install mysql-server mysql-client
Installation will ask you to set a root password for the MySQL server. If you need root access from remote, check out this article.

Install PHP

apt-get install php5 php5-mysql

Just in case, restart the apache server by /etc/init.d/apache2 restart
Another method of restarting the apache server is: service apache2 restart (this work on Red Hat variants as well)

Your web site root folder will be located at /var/www
So if you create a file called test.php in the web root folder, and paste this: <?php phpinfo(); ?>
Then browser to (IP is just an example)
You should now see detailed information about your php setup.

There you go, you now have a basic LAMP ready to rock!

About Author

Related Posts

php8 gd

PHP8 gd Activate after installation

PHP8 GD activate after installation. GD doesn’t get activated by default. Not even a reboot after installation will activate it. So how do we do it? In…

wordpress page not found

WordPress page not found after changing permalinks

Permalinks are a critical aspect of a WordPress website’s structure, providing user-friendly URLs that enhance both SEO and user experience. However, occasionally, WordPress users encounter permalink issues…

Debian 12: linux-image-6.1.0-10amd64

Troubleshooting dependency issues in Debian 12: Resolving linux-image-6.1.0-10amd64 package dependency problems. If you installed the Debian 12 from the live image the issue is the raspi-firmware. Even…

mysql double vs float

MySQL: Double vs Float

When it comes to mysql double vs float to storing numbers with decimal places in a database, two of the most commonly used data types in MySQL…

4 Best Free Nas Software That Is Open Source

Free NAS software or operating systems that are free to use and will turn a computer into a NAS more advanced than the dedicated boxes sold. What…

Raspbian default password

Raspbian default password

Looking for the Raspbian default password? It is the most essential username and password that you will need for your raspberry. At least if you are running…

Leave a Reply