0

Here under my Apache configuration:

<IfDefine TOMCAT>
    <IfModule mod_ssl.c>
       <IfModule mod_proxy_http.c>
          ProxyTimeout      300
          SetEnv force-proxy-request-1.0 1
          SetEnv proxy-nokeepalive 1
          ProxyPass        /unproxied/ !
          ProxyPass        /error/ !
          ProxyPass        /   http://127.0.0.1:8080/ retry=0 ttl=600
          ProxyPassReverse /   http://127.0.0.1:8080/
       </IfModule>
    </IfModule> </IfDefine>

Here my JBoss connector configuration:

    <Connector
        address              = "${jboss.bind.address}"
        port                 = "8080"
        maxThreads           = "200"
        acceptCount          = "100"
        scheme               = "https"
        secure               = "true"
        proxyName            = "mydomain.net"
        proxyPort            = "443"
        xpoweredBy           = "true"
        connectionTimeout    = "600000"
        compression          = "on"
        enableLookups        = "false"
        maxKeepAliveRequests = "-1"
        maxHttpHeaderSize    = "50000"
        />

In my Apache error.log:

[Tue Jul 16 09:54:54 2013] [error] ap_proxy_connect_backend disabling worker for (127.0.0.1)
[Tue Jul 16 09:57:35 2013] [error] (111)Connection refused: proxy: HTTP: attempt to connect to 127.0.0.1:8080 (127.0.0.1) failed

[EDIT] These errors appear around 1000 times per day but my web application seems to work as expected.

What could be the problem ?

Thanks,

Bob !

1 Answer 1

0

Is SELinux enabled and enforcing?

If so, you'll need to setsebool httpd_can_network_connect 1 to allow Apache to make connections to JBoss.

18
  • I've forgotten an important thing. My web application works as expected, but some times, every 10 minutes perhaps, I've these errors in my log file. Jul 16, 2013 at 17:57
  • @BobSauvage Ah, ok. Do you know if the errors coincide with failures of user requests? (they'll get a 503 response, look for those in the logs) What kind of load is the application under? Jul 16, 2013 at 18:00
  • Indeed, several proxy errors coincide with a 503 response... The load is difficult to measure but it is quite high. Just to have an idea: netstat -aln | grep 8080 | wc -l => 810 Jul 16, 2013 at 18:07
  • @BobSauvage Might be bumping into the JBoss thread limit, then, causing rejected connection attempts -- check what the maxThreads setting is for your port 8080 connector in the server.xml file? Jul 16, 2013 at 18:17
  • maxThreads = "200" How can I check the number of threads ? Jul 16, 2013 at 18:28

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .