Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

OS: Ubuntu 12.04.2 Updated to the latest and greatest

SO here's what I've don so far:

cd /etc/apache2/sites-available
sudo nano mysite

Inside this file I've written the following definition:

NameVirtualHost *:80
<VirtualHost *:80>
DocumentRoot /var/www/mysite

then enabled the site with the following command(as root):

a2ensite mysite


service apache2 restart

all this to no avail. any suggestions?

EDIT: If there is more information I can add or things I can change to make getting a response more probable please let me know. thanks

share|improve this question
After enabling the site: root@KAL33K0-KORE:/etc/apache2/sites-available# nano mysite root@KAL33K0-KORE:/etc/apache2/sites-available# a2ensite mysite Enabling site mysite. To activate the new configuration, you need to run: service apache2 reload root@KAL33K0-KORE:/etc/apache2/sites-available# service apache2 reload * Reloading web server config apache2 [Thu Apr 18 21:40:30 2013] [warn] NameVirtualHost *:80 has no VirtualHosts – heypaleblue Apr 19 '13 at 2:41
can someone explain? – heypaleblue Apr 19 '13 at 2:49
up vote 1 down vote accepted

Remove NameVirtualHost *:80 from your virtual host's file. This is already in /etc/apache2/ports.conf by default.

I placed NameVirtualHost *:80 in one of my virtual host's files and can confirm that I got the same error.

share|improve this answer
Just want to take a moment to sincerely thank you. It's hard to "learn by doing" when answers are scarce. So thank you. your helping me learn and move my project forward I am forever grateful to you for that! – heypaleblue Apr 20 '13 at 17:45

Your Answer


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

Not the answer you're looking for? Browse other questions tagged or ask your own question.