Forum Discussion

kbk491's avatar
kbk491
Icon for Altostratus rankAltostratus
Oct 07, 2022

query regarding connection issues to a particular node in a pool

Note: i will use the word server/node a lot but they mean basically the same.

So i just recently created 4 virtual servers and each one of the servers is using 1 pool each where each pool has the exact same member (so same ips) but with different ports as they have different use cases.

So its a simple setup basically with http and https service ports being used on these virtual servers (2 http and 2 https so 4 in total as explained in the first para).

Now 1 of the members in each of these pools is not yet ready so it cannot load the webpage yet (This member is the same in all the pools so has the same ip for all). Traffic is being round robbined for all so what ive observed is when it hits the working member the webpage loads but when it hits the non working member the webpage keeps spinning and finally throws an error (as expected as this server is not yet ready). 

So my question is if a request goes to such a node in a pool and it takes too long to load a webpage/ webpage throws error after a long time what should i do so that it just forwards all the connections only to the working node (the node or nodes that loads the webpage fast) until this slow/non working node comes up?

Is there an irule for this or do i need to tinker with the profiles section such as tcp or something?

Thank You.

  • Hello,

    From what you have said in the below underline part, is that "if the member is not ready yet", you don't want F5 to forward requests to that member until the member is completely ready.

    Your post:

    "Traffic is being round robbined for all so what ive observed is when it hits the working member the webpage loads but when it hits the non working member the webpage keeps spinning and finally throws an error (as expected as this server is not yet ready)."

    You can accomplish this by using a custom HTTP/HTTPs monitor, you can specify the URL and the expected receive string when the service on that node is working fine, here is an example:

    Navigate to LTM > Monitor > create > HTTP/HTTPs.

    For example, in the send string, for the below red URL, you can add the specific URL for the service, and for the Host, you can add the exact FQDN of the service:

    GET /autodiscover/healthcheck.html HTTP/1.1\r\nHost: www.abc.com\r\nConnection: Close\r\n\r\n

    Receive string:

    200 OK

    (it depends on your service, you can check it by using the developer tool or ask the service owner about the correct send and receive strings)

    If the F5 device didn't receive a response (because the nod is not ready for example) on the above send string for the configured timeout in the custom monitor which has a default value of 16 seconds, the F5 will consider this pool member (node or server) as offline and will not forward any more requests to this node until the node respond successfully to the F5.

  • Hello,

    Let's take the below screenshot as an example:

    the red part that was mentioned in my last reply, is the below based on the screenshot:

    /search.php

    (the part after the "/" and before the "?")

    Then the FQDN is: www.auction.com   (without https:// part)

    so the send string will be as follow for example:

    GET /search.php HTTP/1.1\r\nHost: www.auction.com\r\nConnection: Close\r\n\r\n

    and the receive string is:

    200 OK

     

    I hope I clarified the procedure.

    BR,

    Mohamed Salah

  • Hello,

    From what you have said in the below underline part, is that "if the member is not ready yet", you don't want F5 to forward requests to that member until the member is completely ready.

    Your post:

    "Traffic is being round robbined for all so what ive observed is when it hits the working member the webpage loads but when it hits the non working member the webpage keeps spinning and finally throws an error (as expected as this server is not yet ready)."

    You can accomplish this by using a custom HTTP/HTTPs monitor, you can specify the URL and the expected receive string when the service on that node is working fine, here is an example:

    Navigate to LTM > Monitor > create > HTTP/HTTPs.

    For example, in the send string, for the below red URL, you can add the specific URL for the service, and for the Host, you can add the exact FQDN of the service:

    GET /autodiscover/healthcheck.html HTTP/1.1\r\nHost: www.abc.com\r\nConnection: Close\r\n\r\n

    Receive string:

    200 OK

    (it depends on your service, you can check it by using the developer tool or ask the service owner about the correct send and receive strings)

    If the F5 device didn't receive a response (because the nod is not ready for example) on the above send string for the configured timeout in the custom monitor which has a default value of 16 seconds, the F5 will consider this pool member (node or server) as offline and will not forward any more requests to this node until the node respond successfully to the F5.

    • CA_Valli's avatar
      CA_Valli
      Icon for MVP rankMVP

      +1 on this, I would agree that you can easily deploy a monitor to determine which pool members are or aren't eligible for traffic forwarding. 

    • kbk491's avatar
      kbk491
      Icon for Altostratus rankAltostratus

      thank you will try that this week and post a reply here

    • kbk491's avatar
      kbk491
      Icon for Altostratus rankAltostratus

      So i dont understand that monitor that you show:

      GET /autodiscover/healthcheck.html HTTP/1.1\r\nHost: www.abc.com\r\nConnection: Close\r\n\r\n

      What is that part in red exactly?

      Also for the blue part if i have to include the fqdn it has to also include "htttp://...." as well right? For example:

      http://fortigate.com/faces/text

      So obviously thats not the same url that we use but it is in the same format.

      Because i tried the http monitor first in this format and it doesnt work (so i guess https monitor will fail too).

      This is what i tried exactly for the http monitor:

      GET /autodiscover/healthcheck.html HTTP/1.1\r\nHost: http://fortigate.com/faces/text?_afrLoop=2864177731496691&_afrWindowMode=0&Adf-Window-Id=w184a5ctyf&_afrPage=2&_afrFS=16&_afrMT=screen&_afrMFW=957&_afrMFH=801&_afrMFDW=1512&_afrMFDH=944&_afrMFC=8&_afrMFCI=0&_afrMFM=0&_afrMFR=96&_afrMFG=0&_afrMFS=0&_afrMFO=0: Close\r\n\r\n

      If you want to know where i got the long fqdn from i got that from developer options:

      Tried without "http://" and it also didnt work.

      I left the red part as the same since i didnt know what to change it to.

      Receive string i left it as:

      200 OK

      Thank you

      • Hello,

        Let's take the below screenshot as an example:

        the red part that was mentioned in my last reply, is the below based on the screenshot:

        /search.php

        (the part after the "/" and before the "?")

        Then the FQDN is: www.auction.com   (without https:// part)

        so the send string will be as follow for example:

        GET /search.php HTTP/1.1\r\nHost: www.auction.com\r\nConnection: Close\r\n\r\n

        and the receive string is:

        200 OK

         

        I hope I clarified the procedure.

        BR,

        Mohamed Salah