What is Apache?

Apache is a freely available Web Server that is distributed under an "open source" license. The current version of Apache is 2.2. More details can found at Apache Website. Now, we will move to next part to know how to install this service on Ubuntu Linux.

How to install Apache on Ubuntu Linux

Step 1: Open a terminal (Applications > Accessories > Terminal)

Step2: Run the following line of code in your terminal

sudo apt-get install apache2
Step 3: Check Apache installation to ensure that it's working well. Open any browser and enter the following line into the Address bar
http://localhost
You should see a folder entitled apache2-default/. Then, you click on that link, you will see a message saying "It works!". That means you have installed Apache 2.2 successfully. If it is not the case, you should go to Step 4 to start up Apache service.

Step 4: Start up Apache by executing the following line of code in your terminal
sudo /etc/init.d/apache2 start
After that, you can do Step 3 again to make sure if your Apache is running!

2 comments

  1. Vadim // 12/8/07, 10:08 PM  

    Thanks a bunch!

    Could you do a mysql and a php tutorial too? Those are often necessary too.

  2. Reema // 7/25/09, 9:30 PM  

    very useful ! thanx