App Connect

App Connect

Join this online user group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
Expand all | Collapse all

Detect DNS IP change without restart

  • 1.  Detect DNS IP change without restart

    Posted Tue March 17, 2020 09:57 AM
    Hi All,

    Please let me know your thoughts on this.

    Scenario - The 3rd Party endpoint(DNS entry NOT IP) has been saved in user-defined Policy.
    The Flow retrieves the Endpoint and calls it.

    Problem: The 3rd Party changed it's IP address overnight which still points to the same DNS entry. This leads to below errors on ACE.

    Mar 15 17:10:29 ACE[18667]: IBM App Connect Enterprise v11006 (xxxxxxx) [Thread 21620] (Msg 6/7) BIP3152S: Socket error detected whilst invoking Web service located at host XXXXXXXXXXXXXXXX.COM, port 443, path /xxx/os/xxxxxxxxx.
    Mar 15 17:10:29 ACE[18667]: IBM App Connect Enterprise v11006 (xxxxxxx) [Thread 21620] (Msg 7/7) BIP3165S: An error occurred whilst performing an SSL socket operation. Operation: connect. Error Text: java.net.NoRouteToHostException: No route to host (Host unreachable).


    Solution: To resolve this, I had to recycle the Integration Server where Policy and Flow were deployed.

    Question: 1. Is there any config setting where ACE would detect this change and use the new IP to call the 3rd party?


    Thanks.

    ------------------------------
    Anil Kumar
    Integration Consultant
    Prolifics
    LONDON
    ------------------------------


  • 2.  RE: Detect DNS IP change without restart

    Posted Tue March 17, 2020 10:27 AM
    ACE usages the default DNS Cache provided by JVM, in your case JVM is caching the IP and server is trying to reuse the same for next requests.  in order to overcome this you need to disable the DNS cache in JVM.

    ------------------------------
    Satendra Negi
    ------------------------------



  • 3.  RE: Detect DNS IP change without restart

    Posted Tue March 17, 2020 10:43 AM
    Thanks @Satendra Negi. Would it have any performance impact? Would it fetch the DNS for every request?

    Thanks.​

    ------------------------------
    Anil Kumar
    Integration Consultant
    Prolifics
    LONDON
    ------------------------------



  • 4.  RE: Detect DNS IP change without restart

    Posted Wed March 18, 2020 09:36 AM
    Edited by Anil Kumar Wed March 18, 2020 09:56 AM
    I tried to execute the below command but received the below error. 
    mqsichangeproperties <BrokerName> -e <IntegrationServer> -o ComIbmJVMManager -n jvmSystemProperty -v "-Dsun.net.inetaddr.ttl=0"

    BIP8384E: This command, with the flag or combination of flags 'e', is not yet enabled for use with an integration node. 
    Although commands can be used with integration nodes, some flags or combinations of flags will not be enabled until a later fix pack.
    Users of the product in its current form can use this command with other flags or combination of flags, and can perform some actions in the Enterprise Toolkit.


    Below are the version details:

    C:\Program Files\IBM\ACE\11.0.0.6>mqsiservice -v
    BIPmsgs  en_US
      Console OEM CP=437, ICU CCSID=5348
      Default codepage=ibm-5348_P100-1997, in ascii=ibm-5348_P100-1997
      JAVA console codepage name=cp437
    
    BIP8996I: Version:    11006
    BIP8997I: Product:    IBM App Connect Enterprise
    BIP8998I: Code Level: S000-L191002.16138
    BIP8999I: Build Type: Production, 64 bit, amd64_nt_4
    
    BIP8974I: Component: DFDL-C, Build ID: 20190218-2331, Version: 1.1.2.0 (1.1.2.0), Platform: windows_x86 64-bit, Type: production
    
    BIP8071I: Successful command completion.

    Is it fixed in 11.x.x.7 fix pack or planned to be fixed in later fix-packs? @Ben Thompson

    Thanks,

    ------------------------------
    Anil Kumar
    Integration Consultant
    Prolifics
    LONDON
    ------------------------------



  • 5.  RE: Detect DNS IP change without restart
    Best Answer

    Posted Wed March 18, 2020 11:19 AM
    In ACEv11.0.0.6 and ACEv11.0.0.7 you can use your mqsichangeproperties command in offline mode (-f parameter added to your example command) against a stopped integration node. When you restart your integration node, the property should take effect (and you can query this through the REST API by issuing an HTTP GET against http://machinename:port/apiv2/servers/default/resource-managers/jvm-manager

    In ACEv11.0.0.8 ... not quite out but due for release very soon this should improve further ... we expect you to be able to use mqsichangeproperties without the -f flag and you will see something like this ...

    mqsichangeproperties BENQUICKFP8 -e default -o ComIbmJVMManager -n jvmSystemProperty -v "-Dsun.net.inetaddr.ttl=0"
    BIP8491W: The changes have been accepted and persisted by the integration server 'default'. An integation server restart is required for the changes to become active.

    BIP8071I: Successful command completion.

    As suggested by the response the changed setting can be applied just by restarting the server rather than the whole integration node.

    ------------------------------
    Ben Thompson
    IBM UK
    ------------------------------



  • 6.  RE: Detect DNS IP change without restart

    Posted Tue May 12, 2020 09:43 AM
    @Ben Thompson

    We are facing a similar issue where the call to third party using SOAPRequest node suddenly stop working and started to give below error response and the request gets timed out. 

    A timeout error occurred whilst performing an SSL socket operation' ['connect', 120001, 'java.net.SocketTimeoutException: connect timed out'] WebServices/WSLibrary/ImbSocket.cpp:1274
    THROWN BIP3152S RecoverableException ImbWSRequest::makeWSRequest 'A Web Service request has detected a SOCKET error whilst invoking a web service located at host &1, on port &2, on path &3.' ['******************.com', 443, '/']

    All subsequent SOAP calls also failed with similar error. However the problem is resolved if we restart the integration server or the integration node. Is this also a issue with the DNS caching?

    Also can you please suggest what is the performance impact if we use -Dsun.net.inetaddr.ttl=0

    Below is the ACE version information that we are using:

    BIP8996I: Version: 11006
    BIP8997I: Product: IBM App Connect Enterprise
    BIP8998I: Code Level: S000-L191002.16138
    BIP8999I: Build Type: Production, 64 bit, amd64_linux_2

    BIP8974I: Component: DFDL-C, Build ID: 20190218-2330, Version: 1.1.2.0 (1.1.2.0), Platform: linux_x86 64-bit, Type: production


    Regards,
    Saha
    IBM India





    ------------------------------
    Prosanta Saha
    ------------------------------



  • 7.  RE: Detect DNS IP change without restart

    Posted Tue July 21, 2020 08:09 AM
    Edited by Anil Kumar Tue July 21, 2020 08:14 AM
    Hi Prosanta​, In our case, 3rd party IP was dynamic to the DNS entry we have been given to configure in ACE. So to disable cache in ACE, we applied the above solution, and yes after that we didn't face a similar issue.

    We used -Dsun.net.inetaddr.ttl=060

    ------------------------------
    Anil Kumar
    Senior Consultant
    Prolifics
    LONDON
    ------------------------------



  • 8.  RE: Detect DNS IP change without restart

    Posted Tue July 21, 2020 08:20 AM
    Hi Anil,

    Thank you for your input.

    One more thing what was the ACE fix pack version you had?

    Also have you noticed any performance impact after enabling Dsun.net.inetaddr.ttl=0?

    Regards,
    Saha

    ------------------------------
    Prosanta Saha
    ------------------------------



  • 9.  RE: Detect DNS IP change without restart

    Posted Tue July 21, 2020 08:27 AM
    The Version is 11006 and no, we didn't notice any performance impact.

    ------------------------------
    Anil Kumar
    Integration Consultant
    Prolifics
    LONDON
    ------------------------------



  • 10.  RE: Detect DNS IP change without restart

    Posted Tue July 21, 2020 10:10 AM
      |   view attached
    Hi Anil,

    Good to hear that it didn't cause any performance impact.

    One last thing, as per the below URL it's asking to modify the java.security file along with setting -Dsun.net.inetaddr.ttl=0 using  mqsichangeproperties.

    https://www.ibm.com/support/knowledgecenter/en/SSMKHH_9.0.0/com.ibm.etools.mft.doc/au16534_.htm#au16534_3

    Have you set both options or just set -Dsun.net.inetaddr.ttl=0 using mqsichangeproperties?

    Attached screenshot is for your reference.

    Regards,
    Saha




    ------------------------------
    Prosanta Saha
    ------------------------------



  • 11.  RE: Detect DNS IP change without restart

    Posted Fri October 02, 2020 01:24 PM
    Edited by Francisco A Buccafusca Fri October 02, 2020 01:26 PM
    Is it necessary to issue the mqsichangeproperties command or is it better to edit the jvmSystemProperty property in JVM section in the server.conf.yaml file?

    Thanks.

    ------------------------------
    Francisco A Buccafusca
    Argentina
    ------------------------------



  • 12.  RE: Detect DNS IP change without restart

    Posted Fri October 02, 2020 03:01 PM

    Hi,

    Both options should work.

    When you run the mqsichangeproperties command to disable the cache it's indirectly updating the server.conf.yaml file and this can be found at

    /var/mqsi/components/IntegrationNodeName/servers/IntegrationServerName/overrides/server.conf.yaml.

    We have updated the jvmSystemProperty directly in the server.conf.yaml file (without mqsichangeproperties) in Production two weeks back and after that we didn't observed any issue related to IP caching.

    Regards,
    Saha



    ------------------------------
    Prosanta Saha
    ------------------------------



  • 13.  RE: Detect DNS IP change without restart

    Posted Tue December 29, 2020 12:49 PM

    Hi,

    Scenario:

    A client ( IP = 10.0.81.52) calls to ACE'services (10.0.81.54:7800).

    There is no entry in both DNS Server and /etc/hosts. To avoid IP lookup in DNS Server, my idea is "caching forever" for both "successful IP" and "unsuccessful IP".

    • ACE version 11.0.0.9, OS is AIX.
    • I modified file java.security as:

              networkaddress.cache.ttl=-1

              networkaddress.cache.negative.ttl=-1 

    • I used mqsichangeproperties to configure -Dsun.net.inetaddr.negative.ttl=-1, results in overrided server.conf.yaml file:

            ---
            ResourceManagers:
              JVM:
                  jvmSystemProperty: '-Dsun.net.inetaddr.negative.ttl=-1'

    • I restarted Integration Server ( named MainServer).

    Problem: ACE still tries to loopup IP in DNS Server. This is log which is captured by tcpdump:

    Question:

    1. Please, explain me why ACE always tries to lookup client's IP ? ( What is the purpose of this action ? Why is it necessary ?)
    2. How to disable the action lookup IP of ACE ?
    3. Finally, "cache forever" is the way that I'm trying to do which is the alternative solution for disabling lookup IP. But it seems not to work. Is there any configuration that I lacked ?

    Thank you very much.



    ------------------------------
    Le Hung
    ------------------------------