AnsweredAssumed Answered

Connection to Alfresco Share unavailable with proxy

Question asked by dbas2000 on Nov 7, 2012
Hello,


When the Java Option Dhttp.proxyHost is set in the <CATALINA_HOME>/scripts/ctl.sh, the login connection to Alfresco Share failed, because it uses this proxy settings to access the local Alfresco !

The URL http://mydomain.ch:8180/share/page/type/login?error=true receive this error :

The remote server is unavailable or your credentials were not recognized

So I added the Dhttp.noProxyHosts , but it does not takes effect, share continues to use the proxy.

Below is the Share.log illustrating that the proxy is used to access the localhost URL and receive an HTTP 503 error  :


17:03:50,926 DEBUG [org.apache.commons.httpclient.HttpConnection] Open connection to 10.x.xx.xxxx:nnnn (IP and proxy port)
17:03:50,930 DEBUG [httpclient.wire.header] >> "GET http://localhost:8180/alfresco/s/api/admin/restrictions?guest=true HTTP/1.1[\r][\n]"
17:03:50,930 DEBUG [org.apache.commons.httpclient.HttpMethodBase] Adding Host request header
17:03:50,938 DEBUG [httpclient.wire.header] >> "User-Agent: Jakarta Commons-HttpClient/3.1[\r][\n]"
17:03:50,938 DEBUG [httpclient.wire.header] >> "Host: localhost:8180[\r][\n]"
17:03:50,938 DEBUG [httpclient.wire.header] >> "Proxy-Connection: Keep-Alive[\r][\n]"
17:03:50,938 DEBUG [httpclient.wire.header] >> "[\r][\n]"
17:03:51,139 DEBUG [httpclient.wire.header] << "HTTP/1.0 503 Service Unavailable[\r][\n]"
17:03:51,139 DEBUG [httpclient.wire.header] << "HTTP/1.0 503 Service Unavailable[\r][\n]"
17:03:51,141 DEBUG [httpclient.wire.header] << "Server: squid/2.5.STABLE9[\r][\n]"


Here is the <CATALINA_HOME>/scripts/ctl.sh

export JAVA_OPTS="-XX:MaxPermSize=256m -Xms512m -Xmx512m -XX:-DisableExplicitGC \
                  -Djava.awt.headless=true -Dalfresco.home=/soi/app/xx/xx \
                  -Duser.dir=${CATALINA_HOME}/user.dir \
                        -Duser.home=${CATALINA_HOME}/user.home \
                  -Dhttp.proxyHost=10.x.x.x -Dhttp.proxyPort=3128 \
                  -Dhttp.noProxyHosts=localhost \

Does somebody knows why the Dhttp.noProxyHosts=localhost does not take effect or how to configure Alfresco to use a proxy with no impact with Share ?

Thank's in advance
               
Pierre-André from Switzerland


Alfresco Community 4.2.b in Linux Centos 6.2
Java version: 1.7.0_07
Database PostgreSQL

Outcomes