Skip to main content
Inspiring
December 23, 2021
Answered

Error Coldfusion 2021

  • December 23, 2021
  • 1 reply
  • 32930 views

Hello ,:)

 

I have a problem with my configuration of coldfusion.

 

I have this same error :

 

Thu Dec 23 15:34:05 2021] [6687:140487759288064] [error] ajp_service::jk_ajp_common.c (3021): (cfusion) connecting to tomcat failed (rc=-3, errors=161, client_errors=0).
[Thu Dec 23 15:34:05 2021] [6688:140487964980992] [info] jk_open_socket::jk_connect.c (816): connect to 127.0.0.1:8020 failed (errno=13)
[Thu Dec 23 15:34:05 2021] [6688:140487964980992] [info] ajp_connect_to_endpoint::jk_ajp_common.c (1158): (cfusion) Failed opening socket to (127.0.0.1:8020) (errno=13)
[Thu Dec 23 15:34:05 2021] [6688:140487964980992] [error] ajp_send_request::jk_ajp_common.c (1829): (cfusion) connecting to backend failed. Tomcat is probably not started or is listening on the wrong port (errno=13)
[Thu Dec 23 15:34:05 2021] [6688:140487964980992] [info] ajp_service::jk_ajp_common.c (3000): (cfusion) sending request to tomcat failed (recoverable), because of error during request sending (attempt=2)
[Thu Dec 23 15:34:05 2021] [6688:140487964980992] [error] ajp_service::jk_ajp_common.c (3021): (cfusion) connecting to tomcat failed (rc=-3, errors=162, client_errors=0).

 

my server.xml:

 

<!-- Define a SSL/TLS HTTP/1.1 Connector on port 8443
This connector uses the NIO implementation that requires the JSSE
style configuration. When using the APR/native implementation, the
OpenSSL style configuration is required as described in the APR/native
documentation-->
<!-- <Connector port="8443" protocol="org.apache.coyote.http11.Http11NioProtocol"
maxThreads="150" SSLEnabled="true" scheme="https" secure="true"
clientAuth="false" sslProtocol="TLS" />-->
<!-- Define an AJP 1.3 Connector on port 8009-->
<!-- begin connector-->
<Connector protocol="AJP/1.3" port="8020" redirectPort="8453" secret="9661aacd-ac6f-42ad-8dd8-c371c36.." maxThreads="500" connectionTimeout="200000" tomcatAuthentication="false" address="127.0.0.1"/>
<!-- end connector-->
<!-- An Engine represents the entry point (within Catalina) that processes

 

 

 

 

 

 

My workers.proprietes:

 

heartbeat_interval=30
heartbeat_limit=90

#Start of workers.properties associated with 'cfusion'
worker.list=cfusion

worker.cfusion.type=ajp13
worker.cfusion.host=127.0.0.1
worker.cfusion.port=8020
worker.cfusion.heartbeat_servlet_path=/__cf_connector_heartbeat__
worker.cfusion.connection_pool_timeout=60
worker.cfusion.monitoringsecret=49162e5a-c1dc-4d25-a560-d8056d02016d
worker.cfusion.secret=9661aacd-ac6f-42ad-8dd8-c371c366c...
#End of workers.properties associated with 'cfusion

 

Please for you Help i don't know what i can do

 

THANKS 

 

 

 

    This topic has been closed for replies.
    Correct answer imad22375965ncv4
     

    it's ok!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! for the resolution of  the error tomcat !!!!! 

     


    By @imad22375965ncv4

     

    This means your original question has been answered. 🙂

    What suggestion led to the resolution? Please mark it as the correct answer. Alternatively, you could describe the steps that resolved the problem, then mark your description as the correct answer.

     

    That is important for the forum. In so doing you will promote the sharing of knowledge. Your response will also help a fellow developer who comes here looking for solutions. That will surely happen, because connector problems occur frequently.


    Hello ,

     

    Sorry for the delay.

    Yes for me it's ok with you all help.

     

    To resolve my problem, here the step

     

    1. Enable the listen of ipv4 in the jvm

    2. match the server.xml with workers.proprietes
    3.disable the selinux

    if the result of your netstat doesn't show  that your connector  use anyport tcp v4 in your server, is in my case the main problem.

     

     

    After this change my coldfusio n work good

     

    Once again thank you, without your helps i will never resolve my problem

     

    I wish you a good year , many good things for your family and you.....

     

     

    Imad
    3.

    1 reply

    BKBK
    Community Expert
    December 23, 2021

    Suggestion:

    1. Make sure the connection settings in server.xml match those in workers.properties:
          connectionTimeout / connection_pool_timeout
          maxThreads / connection_pool_size / max_reuse_connections
          secret (the secret must contain 36 characters and no dots; its structure
          must be in the form xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)
    2.  Comment out the heartbeat_servlet_path setting.
    3.  Experiment by switching the host value from 127.0.0.1 to localhost.

      Your  workers.properties should then look like:
      heartbeat_interval=30
      heartbeat_limit=90
      
      #Start of workers.properties associated with 'cfusion'
      
      worker.list=cfusion
      
      worker.cfusion.type=ajp13
      worker.cfusion.host=localhost
      worker.cfusion.port=8020
      # worker.cfusion.heartbeat_servlet_path=/__cf_connector_heartbeat__
      worker.cfusion.connection_pool_timeout=200
      worker.cfusion.connection_pool_size=500
      worker.cfusion.max_reuse_connections=500
      worker.cfusion.monitoringsecret=49162e5a-c1dc-4d25-a560-d8056d02016d
      worker.cfusion.secret=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
      
      # End of workers.properties associated with 'cfusion​
    Charlie Arehart
    Community Expert
    December 24, 2021

    Regardless of whether the rest of this suggestion may pan out, I would note that it's inappropriate to make your recommendation 2, "Comment out the heartbeat_servlet_path setting", without more context.

     

    First, I don't see at all that the OP's problem will have anything to do with that.

     

    Second and most important, I realize that you may have in mind past reports of people who had SOME problems that were ultimately solved by removing that, it's still inappropriate to simply recommend that people remove it without clarification of what the implications are.

     

    To be clear, folks, that line refers to a URL that the CF web server connector (the .dll file loaded as an ISAPI filter into IIS or the .so file loaded as a module into Apache) will then use to call into CF, passing in various metrics about the state of the connector from the web server's perspective. And that info is then used primarily by the CF PMT (Performance Monitoring Toolset, which was new in CF2018). In particular, besides showing the MONITORING of that, it also uses that info for the auto-tuning of the connector offered by the PMT.

     

    So sure, if someone wanted to say "you can remove that if you don't use the PMT", that may be so. (It's not clear if Adobe may use the "heartbeat" any other way.) But even then one should be cautioned that in doing that, it means that if they may LATER implement the PMT, then this connector monitoring and tuning would not work.

     

    I often end up having to help people understand "why x doesn't work", and that very often starts with suggestions like this, which are offered tersely and without context. All this is why I made my first assertion. BKBK, I know you often chafe at my attempts to offer such clarifications. It often feels like we're in a battle, between our sometimes contrasting solutions to folks problems.

     

    You may even feel you're "doing the people's work" by "keeping it simple". I'm just saying that if you may ever in the future offer that suggestion in point 2, you could help a whole lot by simply adding a parenthetical "(assuming you're not and won't use the CF PMT)". At least then it can clue folks in to being cautions about making that change too casually. 🙂

     

    But back to Imad's original issue, I do hope somehow the rest of what you offer may help. If it does not, let us know, Imad. There may be still more we can offer. I'll hold off for now, in case you may have solved things.

    /Charlie (troubleshooter, carehart. org)
    Charlie Arehart
    Community Expert
    December 25, 2021

     

     

    First, I don't see at all that the OP's problem will have anything to do with that.


    By @Charlie Arehart

     

    Which is in fact the reason why I suggested commenting out the setting: 

     

    # worker.cfusion.heartbeat_servlet_path=/__cf_connector_heartbeat__

     

     This, incidentally, is a new property in ColdFusion. By the look of it (double underscore in name), it is still work in progress.

     

    Anyway, I consider the rest of your remarks - about PMT, you helping 'people understand "why x doesn't work"', and the rest of it - irrelevant. If anything. the remarks only show that you and I think differently about software development.

     

    Yes, I suggest commenting out the setting for a path used by PMT. So what? PMT is an optional module which you can connect to or disconnect from ColdFusion at will. No big deal. At least, not as big a deal as you have magnified. PMT is the least of our worries here. 

     

    The ship is adrift in mid-ocean. The engines have stalled. What I am suggesting is: start by finding the minimum set of things to do to get the engines running. The rest of the problems can then be tackled from there.

     

    In software development terms, the agile way:

     

    1. Find the minimum set of things you can do to get the application working. Do them.
    2. Expect failure and errors. When you fail, fail fast.
    3. Learn from failure and errors. Recover from them by looping back to 1.

     

     

     

     

     

     

     


    Well, unlike your point 3, your point 2 here wasn't indicated as an "experiment" but simply as something to "do", as if anyone would agree. It simply lacked some needed context. 

     

    As for the underscores those are NOT a reflection of the setting being "a work in progress". Instead, it's just a reflection of evolution in that connector heartbeat setting, whose value changed from just "connector" in cf2018. Adobe is trying to avoid conflict with a directory of that name which a user might have. To be clear, that url is called by the connector into cf whether you use the pmt or not. 

     

    Back to your proposing removing it, and to stretch your boat analogy, this seems like a passenger on a boat--that's run aground on a reef in a storm. He sees the crew throwing deadweight overboard, and wanting to help he comes across a sail rolled up which he figures is clearly not in use, so he tosses it over. Only he doesn't realize it would indeed be vital if its need did arise.

     

    And worse, when that need did arise and the sail's found missing, the crew might very well blame the captain for not having ensured it was brought along in the first place. In this case, the captain is Adobe, who would have gotten blamed if someone seeing your suggestion (without any caveat) followed it and later DID enable the PMT, and tried to leverage its feature that relied on this.

     

    Sure, these folks may never use it. Again, my point was mainly to offer the needed context before removing it. I get that people will try about anything when faced with a seemingly desperate situation.

     

    As we do in all our help in the forums here, we each offer from our experience. No, it won't always be the same. Folks can consider our opinions and try to make the best decision for themselves. I was just trying to add to the knowledge base about this situation, on a couple of aspects.

     

    Let's hope Imad does get the ship going again, with minimal impact on future use. And after a long couple of (log4j) weeks, let's hope we can all enjoy both the weekend and the holidays. 

    /Charlie (troubleshooter, carehart. org)