When I activate a proxy by entering the address in /etc/environment, the website I host on my webserver becomes inaccessible with the following error message (snippet):

<div id="content">
<p>The following error was encountered while trying to retrieve the URL: <a href="http://www.correct.url.com/">http://www.correct.url.com/</a></p>

<blockquote id="error">
<p><b>Unable to determine IP address from host name <q>http://www.correct.url.com</q></b></p>

<p>The DNS server returned:</p>
<blockquote id="data">
<pre>Name Error: The domain name does not exist.</pre>

<p>This means that the cache was not able to resolve the hostname presented in the URL. Check if the address is correct.</p>

The website loads correctly when the proxy is not present. I can access sites like google and youtube when the proxy is active. Nslookup for the given domain name also works when the proxy is active, so the DNS server appears to be fine. Apache's run user can also successfully do an nslookup of the domain. I have deactivated my firewall.

The config file of the website currently looks like this:

<VirtualHost *:80>
        # The ServerName directive sets the request scheme, hostname and port that
        # the server uses to identify itself. This is used when creating
        # redirection URLs. In the context of virtual hosts, the ServerName
        # specifies what hostname must appear in the request's Host: header to
        # match this virtual host. For the default virtual host (this file) this
        # value is not decisive as it is used as a last resort host regardless.
        # However, you must set it for any further virtual host explicitly.
        #ServerName www.example.com

        ServerName www.correct.url.com
        ServerAdmin webmaster@localhost
        DocumentRoot /var/www/html

        # I tried these earlier but it doesn't work 
        #ProxyPass / http://proxy.com:8080/
        #ProxyPassReverse / http://proxy.com:8080/

        #ProxyPass / http://www.correct.url.com/
        #ProxyPassReverse / http://www.correct.url.com/

        #<Proxy *>
        #    Order deny,allow
        #    Allow from all

  • It's not clear what you want to do. Should Apache be reverse proxy? Why do you need a proxy defined?
    – vidarlo
    Nov 20 at 22:44
  • where is the URL being referenced? That is an invalid DNS host name on my system. Nov 20 at 23:57
  • @vidarlo Well, this machine has to use a proxy (that isn't up to me) for internet access and I am supposed to set up a webserver. But when the proxy is defined the webserver doesn't work.
    – sysad noob
    Nov 21 at 14:01
  • @JohnHanley to be honest, I just forgot to anonymize that url. It's meant to be equivalent to www.correct_url.com
    – sysad noob
    Nov 21 at 14:02
  • Is the web server supposed to be a reverse proxy?
    – vidarlo
    Nov 21 at 14:03


You must log in to answer this question.

Browse other questions tagged .