Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

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 installed Jenkins on a remote server running Debian 6.0.6 with a ready-to-use Apache 2 instance by using the following instructions:

wget -q -O - | apt-key add -
sh -c 'echo deb binary/ > /etc/apt/sources.list.d/jenkins.list'
apt-get update
apt-get install jenkins

Then I did some configuration:

a2enmod proxy
a2enmod proxy_http
a2enmod vhost_alias 

I created the file /etc/apache2/sites-available/jenkins:

<VirtualHost *:80>
    <Proxy *>
        Order deny,allow
        Allow from all
    ProxyPreserveHost on
    ProxyPass /jenkins

And finally restarted Apache with /etc/init.d/apache2 restart.

Now I cannot reach it via Webbrowser. Neither of the following lines works:

Using the first address triggers the following error message in /var/log/apache2/error.log:

File does not exist: /var/www/main/jenkins

EDIT: I just found out that starting the browser on the remote server I can access Jenkins by visiting http://localhost:8080. So Jenkins works, only the redirection is still erroneous.

share|improve this question
I don't think you can use ServerName maybe set it up as with the proper DNS entry.. – NickW May 10 '13 at 10:04
Well I used a guide for hudson like another guy in this forum did. – Bastian May 10 '13 at 10:31
You didn't read it very well, nowhere in that hudson guide does it say to put a ServerName directive like you have used. Get rid of the /jenkins at the end, just type it in yourself in the browser. – NickW May 10 '13 at 10:36
Thank you, you were right! Actually I used serveral guides which is why the configuration got mixed up a bit. Do you know where to start if I want to use – Bastian May 10 '13 at 12:00
Well, first set up a DNS entry, an A record under, then use the proxypass directive like this ProxyPass / or something similar. – NickW May 10 '13 at 13:06
up vote 2 down vote accepted

ServerName Directive

Description: Hostname and port that the server uses to identify itself
Syntax: ServerName [scheme://]fully-qualified-domain-name[:port]
Context: server config, virtual host Status: Core Module: core

You do not need, in fact cannot use, a directory as part of a FQDN.

From Wikipedia:

A fully qualified domain name (FQDN), sometimes also referred as an absolute domain name,[1] is a domain name that specifies its exact location in the tree hierarchy of the Domain Name System (DNS). It specifies all domain levels, including the top-level domain and the root zone.[2]

share|improve this answer

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.