Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

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

I have ubuntu 11.04 and my apache was running on localhost but I tried to install varnish and have a ride on varnish . So I followed this tutorial and made changes. But after install I saw apache is not running on localhost. When I gave localhost:8008 it was okay. Now I removed varnish and made changes to the port 8008 to 80, but still apache is running on 8008 port.My default sites configuration is like this

<VirtualHost *:80>
    ServerAdmin webmaster@localhost

    DocumentRoot /var/www
    <Directory />
        Options FollowSymLinks
        AllowOverride all
    <Directory /var/www/>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride all
        Order allow,deny
        allow from all

    ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
    <Directory "/usr/lib/cgi-bin">
        AllowOverride None
        Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
        Order allow,deny
        Allow from all

    ErrorLog ${APACHE_LOG_DIR}/error.log

    # Possible values include: debug, info, notice, warn, error, crit,
    # alert, emerg.
    LogLevel warn

    CustomLog ${APACHE_LOG_DIR}/access.log combined

    Alias /doc/ "/usr/share/doc/"
    <Directory "/usr/share/doc/">
        Options Indexes MultiViews FollowSymLinks
        AllowOverride None
        Order deny,allow
        Deny from all
        Allow from ::1/128


I just want to run apache in default port. When I made the apche restart it showed an error like this

[warn] NameVirtualHost *:8008 has no VirtualHosts
httpd (pid 12174) already running
share|improve this question

migrated from Jan 27 '12 at 9:23

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

More of the httpd.conf would help, somewhere along the lines should be a directive setting the port to 8008. Might very well be in an Include file. – Oldskool Jan 26 '12 at 10:00
up vote 3 down vote accepted

Ihis is the file you are looking for:

$ sudo vi /etc/apache2/ports.conf

In this file, change LISTEN 80

share|improve this answer
Thanks Ravi..Finally it worked for me. – newuser Jan 26 '12 at 9:59

Somewhere in your Apache config is the line:

Listen 8008

That specifies the port Apache listens on.

share|improve this answer
I searched it but there was nothing like that – newuser Jan 26 '12 at 9:50

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.