Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I want to install Apache on Ubuntu 10.10.

I've tried running:

sudo apt-get install apache2

but it gives the following error:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package apache2

Any ideas where I can find the apache2 package?

share|improve this question

migrated from stackoverflow.com Mar 12 '11 at 16:26

This question came from our site for professional and enthusiast programmers.

    
You are missing some repositories in /etc/apt/sources.list. Also do an apt-get update –  mario Mar 12 '11 at 16:20

2 Answers 2

The apache2 metapackage is available from security.ubuntu.com, make sure you have the following entries in your /etc/apt/sources.list file:

deb http://security.ubuntu.com/ubuntu maverick-security main restricted
deb-src http://security.ubuntu.com/ubuntu maverick-security main restricted
deb http://security.ubuntu.com/ubuntu maverick-security universe
deb-src http://security.ubuntu.com/ubuntu maverick-security universe
deb http://security.ubuntu.com/ubuntu maverick-security multiverse
deb-src http://security.ubuntu.com/ubuntu maverick-security multiverse

Also, keep in mind that apt-get does not automatically download the repository contents every time you run it (unlike yum). You have to do that manually with sudo apt-get update.

share|improve this answer

Check out this post! It'll show you step by step LAMP Ubuntu 10.10

It starts with works very well for my Ubuntu Box:

sudo apt-get install tasksel
share|improve this answer
1  
Instead of going through the tasksel interface you can just sudo tasksel install lamp-server –  ithcy Mar 12 '11 at 16:19

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.